]>
Commit | Line | Data |
---|---|---|
1 | #!/bin/sh | |
2 | # Copyright: CC0 | |
3 | test_string="Test hash of this string" | |
4 | ||
5 | expected_result=$(echo -n "$test_string" | md5sum | awk '{print $1}') | |
6 | my_result=$(./test_md5_hash "$test_string") | |
7 | ||
8 | if [ "$my_result" = "$expected_result" ]; then | |
9 | # Success | |
10 | exit 0 | |
11 | else | |
12 | exit 1 | |
13 | fi |