mirror of
https://github.com/nim-lang/Nim.git
synced 2026-04-18 21:40:32 +00:00
Tests: Times: JS: Add test for yearday attribute.
This commit is contained in:
13
tests/js/ttimes.nim
Normal file
13
tests/js/ttimes.nim
Normal file
@@ -0,0 +1,13 @@
|
||||
# test times module with js
|
||||
discard """
|
||||
action: run
|
||||
"""
|
||||
|
||||
import times
|
||||
|
||||
# $ date --date='@2147483647'
|
||||
# Tue 19 Jan 03:14:07 GMT 2038
|
||||
|
||||
block yeardayTest:
|
||||
# check if yearday attribute is properly set on TimeInfo creation
|
||||
doAssert fromSeconds(2147483647).getGMTime().yearday == 0
|
||||
Reference in New Issue
Block a user