mirror of
https://github.com/tiffany352/rink-rs
synced 2024-11-10 13:44:15 +00:00
Fix tests failing on Windows
This commit is contained in:
parent
657c545085
commit
fff99d6a2a
2 changed files with 16 additions and 0 deletions
1
.gitignore
vendored
1
.gitignore
vendored
|
@ -1,2 +1,3 @@
|
|||
/target/
|
||||
/web/rink-web.toml
|
||||
.idea
|
||||
|
|
|
@ -531,16 +531,31 @@ fn test_missing_base() {
|
|||
}
|
||||
|
||||
#[test]
|
||||
#[cfg(not(windows))]
|
||||
fn test_date_difference() {
|
||||
test_starts_with("now - (now - 3days)", "2 day, 23 hour, 59 minute, 59.99");
|
||||
}
|
||||
|
||||
#[test]
|
||||
#[cfg(windows)]
|
||||
fn test_date_difference() {
|
||||
test_starts_with("now - (now - 3days)", "3 day, 0 second (time)");
|
||||
}
|
||||
|
||||
#[test]
|
||||
#[cfg(not(windows))]
|
||||
fn test_date_time_formats() {
|
||||
test_starts_with("#1970-01-01 10:30 GMT#", "1970-01-01 10:30:00 GMT");
|
||||
test_starts_with("(now-#10:30#) - (now-#11:30#)", "59 minute, 59.99");
|
||||
}
|
||||
|
||||
#[test]
|
||||
#[cfg(windows)]
|
||||
fn test_date_time_formats() {
|
||||
test_starts_with("#1970-01-01 10:30 GMT#", "1970-01-01 10:30:00 GMT");
|
||||
test_starts_with("(now-#10:30#) - (now-#11:30#)", "1 hour, 0 second (time)");
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_no_calls_on_rhs() {
|
||||
test(
|
||||
|
|
Loading…
Reference in a new issue