diff options
author | Matthias Beyer <mail@beyermatthias.de> | 2017-02-03 12:37:26 +0100 |
---|---|---|
committer | Matthias Beyer <mail@beyermatthias.de> | 2017-02-03 15:10:33 +0100 |
commit | d20c0e6b3c680ecd23ed502b5d851e92773991af (patch) | |
tree | d7c76d2258e90d6d52c50da287f3eb264069b701 | |
parent | eded6b356fcd4442978e6b9882594fc9d82421fa (diff) |
Minify test assertions
We don't need two assertions, as the unwrap() will panic anyways, so no
need to check on Result::is_ok().
-rw-r--r-- | src/import.rs | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/src/import.rs b/src/import.rs index 117be36..20c1405 100644 --- a/src/import.rs +++ b/src/import.rs @@ -126,10 +126,7 @@ fn test_two() { "#; - let imported = import(s.as_bytes()); - assert!(imported.is_ok()); - let imported = imported.unwrap(); - assert!(imported.len() == 3); + assert!(import(s.as_bytes()).unwrap().len() == 3); } #[test] |