File tree Expand file tree Collapse file tree 1 file changed +1
-3
lines changed Expand file tree Collapse file tree 1 file changed +1
-3
lines changed Original file line number Diff line number Diff line change @@ -2,7 +2,7 @@ use core::time::Duration;
22
33#[ test]
44fn creation ( ) {
5- assert ! ( Duration :: from_secs( 1 ) != Duration :: from_secs( 0 ) ) ;
5+ assert_ne ! ( Duration :: from_secs( 1 ) , Duration :: from_secs( 0 ) ) ;
66 assert_eq ! ( Duration :: from_secs( 1 ) + Duration :: from_secs( 2 ) ,
77 Duration :: from_secs( 3 ) ) ;
88 assert_eq ! ( Duration :: from_millis( 10 ) + Duration :: from_secs( 4 ) ,
@@ -107,14 +107,12 @@ fn checked_sub() {
107107
108108#[ test]
109109#[ should_panic]
110- #[ cfg( not( miri) ) ] // Miri does not support panics
111110fn sub_bad1 ( ) {
112111 let _ = Duration :: new ( 0 , 0 ) - Duration :: new ( 0 , 1 ) ;
113112}
114113
115114#[ test]
116115#[ should_panic]
117- #[ cfg( not( miri) ) ] // Miri does not support panics
118116fn sub_bad2 ( ) {
119117 let _ = Duration :: new ( 0 , 0 ) - Duration :: new ( 1 , 0 ) ;
120118}
You can’t perform that action at this time.
0 commit comments