diff options
author | Robin Krahl <robin.krahl@ireas.org> | 2018-12-30 12:46:20 +0100 |
---|---|---|
committer | Robin Krahl <robin.krahl@ireas.org> | 2018-12-30 12:46:20 +0100 |
commit | 27f2bb834da85aba3935e14c6069a07f03ac6a45 (patch) | |
tree | a6607cbd227eeca5310203d16ae310b91ace1601 /tests | |
parent | 4c443110f8e10de905a48b0af1ef15fcd5a10b75 (diff) | |
download | nitrokey-rs-27f2bb834da85aba3935e14c6069a07f03ac6a45.tar.gz nitrokey-rs-27f2bb834da85aba3935e14c6069a07f03ac6a45.tar.bz2 |
Fix Storage volume detection for test cases
It seems that with newer firmeware, the model string in the lsblk output
is Nitrokey_Storage instead of Nitrokey Storage. Therefore this patch
replaces underscores with spaces to account for both versions.
Diffstat (limited to 'tests')
-rw-r--r-- | tests/device.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/tests/device.rs b/tests/device.rs index a6098b7..26afa62 100644 --- a/tests/device.rs +++ b/tests/device.rs @@ -19,7 +19,7 @@ fn count_nitrokey_block_devices() -> usize { .expect("Could not list block devices"); String::from_utf8_lossy(&output.stdout) .split("\n") - .filter(|&s| s == "Nitrokey Storage") + .filter(|&s| s.replace("_", " ") == "Nitrokey Storage") .count() } |