Commit 7d8ee9c
committed
Keep the Date spy and only scope the colon check to the filename
The earlier switch to jest fake timers froze time for the rest of the
suite and broke the test on every platform. The Date constructor spy
already pins the timestamp correctly, as the original Windows failure
showed the right pinned value. The only real problem was that the colon
check looked at the full path, which on Windows starts with a drive
letter like D: that legitimately contains a colon. Restore the spy and
keep the assertion scoped to the basename.1 parent 8c2c912 commit 7d8ee9c
1 file changed
Lines changed: 6 additions & 5 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
20 | 20 | | |
21 | 21 | | |
22 | 22 | | |
23 | | - | |
24 | | - | |
25 | | - | |
26 | | - | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
27 | 28 | | |
28 | 29 | | |
29 | 30 | | |
| |||
46 | 47 | | |
47 | 48 | | |
48 | 49 | | |
49 | | - | |
| 50 | + | |
50 | 51 | | |
51 | 52 | | |
52 | 53 | | |
| |||
0 commit comments