diff options
Diffstat (limited to 'src/libstd/path')
| -rw-r--r-- | src/libstd/path/posix.rs | 2 | ||||
| -rw-r--r-- | src/libstd/path/windows.rs | 4 |
2 files changed, 3 insertions, 3 deletions
diff --git a/src/libstd/path/posix.rs b/src/libstd/path/posix.rs index d98cfb7d8ee..5c6e140bd29 100644 --- a/src/libstd/path/posix.rs +++ b/src/libstd/path/posix.rs @@ -545,7 +545,7 @@ mod tests { ($path:expr, $disp:ident, $exp:expr) => ( { let path = Path::new($path); - assert!(path.$disp().to_str().as_slice() == $exp); + assert!(path.$disp().to_string().as_slice() == $exp); } ) ) diff --git a/src/libstd/path/windows.rs b/src/libstd/path/windows.rs index 113b0410875..206f75739e8 100644 --- a/src/libstd/path/windows.rs +++ b/src/libstd/path/windows.rs @@ -1314,9 +1314,9 @@ mod tests { #[test] fn test_display_str() { let path = Path::new("foo"); - assert_eq!(path.display().to_str(), "foo".to_string()); + assert_eq!(path.display().to_string(), "foo".to_string()); let path = Path::new(b"\\"); - assert_eq!(path.filename_display().to_str(), "".to_string()); + assert_eq!(path.filename_display().to_string(), "".to_string()); let path = Path::new("foo"); let mo = path.display().as_maybe_owned(); |
