Viktor Szépe
77d50b1fc1
Fix typos
2024-10-20 07:46:13 +00:00
Dirkjan Ochtman
e6f5d515cc
Apply clippy suggestions from Rust 1.79
2024-07-08 10:11:53 +02:00
Paul Dicker
9511dd29e6
Rename LocalResult
to MappedLocalTime
, add alias
2024-03-12 13:27:43 +01:00
avoidalone
920e73b033
chore: fix some typos
...
Signed-off-by: avoidalone <wuguangdong@outlook.com>
2024-03-11 14:05:23 +01:00
Paul Dicker
f93508ffd9
Tests: replace TimeDelta::minutes
with try_minutes
2024-03-06 14:04:55 +01:00
Paul Dicker
9f23c08e10
Tests: replace TimeDelta::days
with try_days
2024-03-06 14:04:55 +01:00
Paul Dicker
51a1aa27bd
Tests: use Days
type when it is more appropriate than TimeDelta
2024-03-06 14:04:55 +01:00
Paul Dicker
6da68c8d04
Rename remaining uses of Duration
to TimeDelta
2024-02-05 12:31:46 +01:00
Paul Dicker
3e6fa4c0df
Don't use deprecated method in wasm test
2024-01-30 20:47:54 +01:00
jtmoon79
e116f5c101
tests with date command set env LC_ALL
...
For tests calling `date` Unix tool, also set
environment variable `LC_ALL=c` to make more sure to
avoid locality problems.
2023-09-26 12:06:06 +02:00
Paul Dicker
30b6294ba1
Switch to windows-bindgen
2023-08-29 15:25:30 +02:00
Paul Dicker
bd23f5b437
Require clock
feature for wasm
tests
2023-07-01 16:33:22 +02:00
Paul Dicker
7cc0ca8c8b
Require clock
and std
feature for dateutils
tests
2023-07-01 16:33:22 +02:00
Paul Dicker
0d09acfdad
Parallelize try_verify_against_date_command
2023-06-30 22:04:35 +02:00
Paul Dicker
2c7a24067c
Fix clippy warnings in tests
2023-06-08 15:19:09 +02:00
Paul Dicker
4dceb645e9
Fixes to wasm test
2023-06-07 13:39:36 +02:00
Paul Dicker
5c3f40cc67
Fix dead code error when running dateutils test on Windows
2023-06-05 07:40:19 +02:00
jtmoon79
e41451dedc
try_verify_against_date_command NFC print progress messages
...
Print progress messages for human users watching this long-running
test `try_verify_against_date_command`.
2023-05-30 10:00:47 +02:00
jtmoon79
b1729f3a9b
try_verify_against_date sanity check date command
...
Sanity check `date` command used in tests `try_verify_against_date_command`
and `try_verify_against_date_command_format`. Make sure it's the kind of
`data` command expected (accepts `--version`).
Also, it's just good to print this for debugging purposes.
2023-05-30 10:00:47 +02:00
jtmoon79
05c9408f43
consolidate path to date
2023-05-30 10:00:47 +02:00
scarf
c01e3a7238
test: explicitly set LANG
in gnu date
2023-05-28 11:39:42 +02:00
Qiu Chaofan
8df1ba108f
Fix tests on AIX
...
- Add AIX timezone database path to search list.
- Use date program from freeware to do the testing.
2023-05-11 13:56:12 +02:00
Paul Dicker
895d3b867f
Fix warnings when running tests on Windows
2023-04-25 17:18:16 +02:00
raphaelroosz
a9b1ec412a
fix ordinal week calculation
...
* math is 0 based while ordinal is 1 based => fix as 1 based logic
* add extensive testing against the "date" command format
* format: test sample instead of every day
* 2007 starts with saturday
* Last day of the year is thus the 52 on Monday weekly calendar, 53 on Sunday weekly calendar.
* update %U expected value in test
* Was the goal was to have a different value than with %W at next line ? another date to pick ?
* update cfg("unix") into cfg(target_os = "linux")
* format tests/dateutils.rs
2023-03-04 12:18:21 +01:00
Dirkjan Ochtman
22b4d32498
Avoid use of deprecated API
2022-11-09 13:37:17 +01:00
Dirkjan Ochtman
7cd5e03ee4
Fix up internal calls to newly deprecated methods
2022-10-09 14:15:02 +02:00
Dirkjan Ochtman
71b5881824
Extract date value to avoid multi-line match scrutinee
2022-10-09 14:15:02 +02:00
Dirkjan Ochtman
a9b250764f
Deprecate methods that have an _opt() alternative
2022-10-09 14:15:02 +02:00
Eric Sheppard
cb073a0db7
move test against date command to integration tests
2022-09-26 12:47:29 +02:00
Eric Sheppard
fe4bd220d2
allow optional wasmbindgen
...
use wasmbind feature
2022-08-12 13:49:11 +02:00
Dirkjan Ochtman
9620c8bf99
Use precise feature guards for WASM tests
2022-03-21 20:01:48 -07:00
Sydney Acksman
741b30adab
Simplify JS Date <-> DateTime<Utc> conversion
2020-12-21 13:18:06 -06:00
Brandon W Maister
cf771cb5be
Give an error message when the wasm test fails ( #482 )
2020-09-26 11:03:14 -04:00
ShadoySV
dfa6935b82
Test fix Local::from_local_datetime for wasm
2020-08-05 13:01:25 +03:00
Brandon W Maister
073d86a3b1
Simplify math, add a js_sys test for correctness
2020-07-05 16:50:58 -04:00
Brandon W Maister
b6d7bac99a
Fix wasm testing
...
wasm-bindgen-test and wasm-bindgen need to be different versions (0.3 and 0.2,
respectively), otherwise no tests are found([1], [2]);
This also fixes the test to and ci runner to just test in the current env/tz,
thereby requiring that js_sys returns the same timezone as the host system
thinks it is, but not otherwise trying to set the TZ.
[1]: https://users.rust-lang.org/t/wasm-bindgen-test-and-no-tests-to-run/43444
[2]: https://github.com/rustwasm/wasm-bindgen/pull/2123
2020-07-05 16:50:58 -04:00
Brandon W Maister
c2fe38cd84
clean up github workflows ui
...
This puts different kinds of tests in different job names, instead of
shoehorning them into the matrix.
2020-06-27 15:25:17 -04:00
coolreader18
c5973277e7
Don't do wasmbind on wasi
2019-11-26 23:57:51 -06:00
Brandon W Maister
4617e2e5ba
Make the wasm-pack tests actually run
2019-09-03 22:30:39 -04:00
Brandon W Maister
2839d8d7db
Put wasm-bindgen and js-sys behind a wasm-bindgen feature gate
...
Fixes #334
2019-09-03 09:05:15 -04:00
eV
f21b1fbf21
Fix emscripten and guard against cargo test + wasm32-unknown-unknown
2019-08-16 22:46:10 +00:00
eV
c284d7364b
add conditionals so wasm tests build / run in the right places
2019-08-16 17:11:30 +00:00
eV
5d38faeb40
fix local timezone, add tests
2019-08-16 09:35:56 +00:00