1
Fork 0
mirror of https://github.com/RGBCube/uutils-coreutils synced 2025-07-28 11:37:44 +00:00

cksum: added tests for --raw with each algorithm, not working for crc, sysv, bsd

This commit is contained in:
D9nni 2024-01-09 23:12:40 +02:00
parent 28b5224725
commit 96271ffa3c
13 changed files with 33 additions and 12 deletions

View file

@ -289,14 +289,16 @@ fn test_length_is_zero() {
#[test]
fn test_raw_single_file() {
new_ucmd!()
.arg("--raw")
.arg("lorem_ipsum.txt")
.succeeds()
.no_stderr()
.stdout_is_fixture_bytes("raw_single_file.expected");
for algo in ALGOS {
new_ucmd!()
.arg("--raw")
.arg("lorem_ipsum.txt")
.arg(format!("--algorithm={algo}"))
.succeeds()
.no_stderr()
.stdout_is_fixture_bytes(format!("raw/{algo}_single_file.expected"));
}
}
#[test]
fn test_raw_multiple_files() {
new_ucmd!()