mirror of
https://github.com/casey/just.git
synced 2024-11-28 22:00:18 +03:00
32 lines
563 B
Rust
32 lines
563 B
Rust
use super::*;
|
|
|
|
#[test]
|
|
fn print_timestamps() {
|
|
Test::new()
|
|
.justfile(
|
|
"
|
|
recipe:
|
|
echo 'one'
|
|
",
|
|
)
|
|
.arg("--timestamp")
|
|
.stderr_regex(concat!(r"\[\d\d:\d\d:\d\d\] echo 'one'", "\n"))
|
|
.stdout("one\n")
|
|
.run();
|
|
}
|
|
|
|
#[test]
|
|
fn print_timestamps_with_format_string() {
|
|
Test::new()
|
|
.justfile(
|
|
"
|
|
recipe:
|
|
echo 'one'
|
|
",
|
|
)
|
|
.args(["--timestamp", "--timestamp-format", "%H:%M:%S.%3f"])
|
|
.stderr_regex(concat!(r"\[\d\d:\d\d:\d\d\.\d\d\d] echo 'one'", "\n"))
|
|
.stdout("one\n")
|
|
.run();
|
|
}
|