blob: 26d89319e3cb9069df8cec2f58dc1511704ccb3d [file] [log] [blame]
Check stepUp() and stepDown() bahevior for type=time.
On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
Invalid value
PASS stepUp("", null, null) threw exception InvalidStateError: The object is in an invalid state..
PASS stepDown("", null, null) threw exception InvalidStateError: The object is in an invalid state..
Non-number arguments
PASS stepUp("20:13", null, null, "0") is "20:13"
PASS stepDown("20:13", null, null, "0") is "20:13"
PASS stepUp("20:13", null, null, "foo") is "20:13"
PASS stepDown("20:13", null, null, "foo") is "20:13"
PASS stepUp("20:13", null, null, null) is "20:13"
PASS stepDown("20:13", null, null, null) is "20:13"
Normal cases
PASS stepUp("20:13", null, null) is "20:14"
PASS stepDown("20:13", null, null) is "20:12"
PASS stepUp("20:13", null, null, 10) is "20:23"
PASS stepDown("20:13", null, null, 11) is "20:02"
PASS stepUp("20:13", "4", null, 2) is "20:13:08"
PASS stepDown("20:13", "4", null, 3) is "20:12:48"
Step=any
PASS stepUp("20:13", "any", null) threw exception InvalidStateError: The object is in an invalid state..
PASS stepDown("20:13", "any", null) threw exception InvalidStateError: The object is in an invalid state..
Overflow/underflow
PASS stepUp("20:13", "3.40282346e+38", null) threw exception InvalidStateError: The object is in an invalid state..
PASS stepDown("20:13", "3.40282346e+38", null) threw exception InvalidStateError: The object is in an invalid state..
PASS stepUp("20:13", "1", "20:13") threw exception InvalidStateError: The object is in an invalid state..
PASS stepDown("20:13", "1", "20:13") threw exception InvalidStateError: The object is in an invalid state..
PASS stepUp("23:59", null, null) threw exception InvalidStateError: The object is in an invalid state..
PASS stepDown("00:00", null, null) threw exception InvalidStateError: The object is in an invalid state..
PASS successfullyParsed is true
TEST COMPLETE