mirror of
https://github.com/rust-lang/rustlings.git
synced 2024-12-27 00:00:03 +03:00
Merge b1200de75e
into 8d0aa11a35
This commit is contained in:
commit
beca06bcb9
|
@ -50,6 +50,11 @@ enum RunMode {
|
||||||
// Compile and run the resulting test harness of the given Exercise
|
// Compile and run the resulting test harness of the given Exercise
|
||||||
pub fn test(exercise: &Exercise, verbose: bool) -> Result<(), ()> {
|
pub fn test(exercise: &Exercise, verbose: bool) -> Result<(), ()> {
|
||||||
compile_and_test(exercise, RunMode::NonInteractive, verbose, false)?;
|
compile_and_test(exercise, RunMode::NonInteractive, verbose, false)?;
|
||||||
|
println!(
|
||||||
|
"Exercise {} is done. Remove {} line to go to the next exercise.",
|
||||||
|
style(exercise).bold(),
|
||||||
|
style("`I AM NOT DONE`").bold()
|
||||||
|
);
|
||||||
Ok(())
|
Ok(())
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -189,7 +189,7 @@ fn run_test_exercise_does_not_prompt() {
|
||||||
.current_dir("tests/fixture/state")
|
.current_dir("tests/fixture/state")
|
||||||
.assert()
|
.assert()
|
||||||
.code(0)
|
.code(0)
|
||||||
.stdout(predicates::str::contains("I AM NOT DONE").not());
|
.stdout(predicates::str::contains("Exercise pending_test_exercise.rs is done. Remove `I AM NOT DONE` line to go to the next exercise."));
|
||||||
}
|
}
|
||||||
|
|
||||||
#[test]
|
#[test]
|
||||||
|
|
Loading…
Reference in a new issue