mirror of
https://github.com/rust-lang/rustlings.git
synced 2025-12-28 06:49:19 +00:00
Test properties updated
This commit is contained in:
parent
e916628d84
commit
3314022480
@ -1206,6 +1206,7 @@ Add `AsRef<str>` or `AsMut<u32>` as a trait bound to the functions."""
|
||||
[[exercises]]
|
||||
name = "file_io1"
|
||||
dir = "24_file_io"
|
||||
test = false
|
||||
hint = """
|
||||
Basic File Reading
|
||||
"""
|
||||
@ -1213,6 +1214,7 @@ Basic File Reading
|
||||
[[exercises]]
|
||||
name = "file_io2"
|
||||
dir = "24_file_io"
|
||||
test = false
|
||||
hint = """
|
||||
Buffered Reading & Writing
|
||||
"""
|
||||
@ -1220,6 +1222,7 @@ Buffered Reading & Writing
|
||||
[[exercises]]
|
||||
name = "file_io3"
|
||||
dir = "24_file_io"
|
||||
test = false
|
||||
hint = """
|
||||
Path Manipulation & Metadata
|
||||
"""
|
||||
|
||||
@ -14,3 +14,22 @@ fn main() {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#[cfg(test)]
|
||||
mod tests {
|
||||
use super::*;
|
||||
|
||||
#[test]
|
||||
fn test_working_directory() {
|
||||
let working_directory_result = std::path::Path::new(".").canonicalize();
|
||||
|
||||
match working_directory_result {
|
||||
Ok(working_directory) => {
|
||||
println!("The working directory is {:?}", working_directory);
|
||||
}
|
||||
Err(error) => {
|
||||
println!("Error: {:?}", error);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
Loading…
x
Reference in New Issue
Block a user