File tree Expand file tree Collapse file tree 1 file changed +0
-29
lines changed Expand file tree Collapse file tree 1 file changed +0
-29
lines changed Original file line number Diff line number Diff line change @@ -507,21 +507,6 @@ mod tests {
507
507
!= CString :: <4 >:: from_bytes_with_nul( b"abc\0 " ) . unwrap( )
508
508
) ;
509
509
}
510
-
511
- #[ test]
512
- fn c_str ( ) {
513
- // Empty strings
514
- assert ! ( CString :: <1 >:: new( ) == c"" ) ;
515
- assert ! ( c"" == CString :: <1 >:: new( ) ) ;
516
-
517
- // Single character
518
- assert ! ( CString :: <2 >:: from_bytes_with_nul( b"a\0 " ) . unwrap( ) == c"a" ) ;
519
- assert ! ( c"a" == CString :: <2 >:: from_bytes_with_nul( b"a\0 " ) . unwrap( ) ) ;
520
-
521
- // Multiple characters
522
- assert ! ( CString :: <4 >:: from_bytes_with_nul( b"abc\0 " ) . unwrap( ) == c"abc" ) ;
523
- assert ! ( c"abc" == CString :: <4 >:: from_bytes_with_nul( b"abc\0 " ) . unwrap( ) ) ;
524
- }
525
510
}
526
511
527
512
mod ordering {
@@ -549,20 +534,6 @@ mod tests {
549
534
550
535
#[ test]
551
536
fn c_str ( ) {
552
- assert_eq ! ( CString :: <1 >:: new( ) . partial_cmp( & c"" ) , Some ( Ordering :: Equal ) ) ;
553
- assert_eq ! (
554
- CString :: <2 >:: from_bytes_with_nul( b"a\0 " )
555
- . unwrap( )
556
- . partial_cmp( & c"b" ) ,
557
- Some ( Ordering :: Less )
558
- ) ;
559
- assert_eq ! (
560
- CString :: <2 >:: from_bytes_with_nul( b"b\0 " )
561
- . unwrap( )
562
- . partial_cmp( & c"a" ) ,
563
- Some ( Ordering :: Greater )
564
- ) ;
565
-
566
537
assert_eq ! ( c"" . partial_cmp( & CString :: <1 >:: new( ) ) , Some ( Ordering :: Equal ) ) ;
567
538
assert_eq ! (
568
539
c"a" . partial_cmp( & CString :: <2 >:: from_bytes_with_nul( b"b\0 " ) . unwrap( ) ) ,
You can’t perform that action at this time.
0 commit comments