Skip to content

Commit 3c5415e

Browse files
authored
Updating tests for gigasecond (#2586)
1 parent e61ab87 commit 3c5415e

File tree

3 files changed

+16
-5
lines changed

3 files changed

+16
-5
lines changed

exercises/practice/gigasecond/.meta/config.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
"contributors": [
66
"ankorGH",
77
"draalger",
8+
"jagdish-15",
89
"kytrinyx",
910
"matthewmorgan",
1011
"paparomeo",

exercises/practice/gigasecond/.meta/tests.toml

Lines changed: 13 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,13 @@
1-
# This is an auto-generated file. Regular comments will be removed when this
2-
# file is regenerated. Regenerating will not touch any manually added keys,
3-
# so comments can be added in a "comment" key.
1+
# This is an auto-generated file.
2+
#
3+
# Regenerating this file via `configlet sync` will:
4+
# - Recreate every `description` key/value pair
5+
# - Recreate every `reimplements` key/value pair, where they exist in problem-specifications
6+
# - Remove any `include = true` key/value pair (an omitted `include` key implies inclusion)
7+
# - Preserve any other key/value pair
8+
#
9+
# As user-added comments (using the # character) will be removed when this file
10+
# is regenerated, comments can be added via a `comment` key.
411

512
[92fbe71c-ea52-4fac-bd77-be38023cacf7]
613
description = "date only specification of time"
@@ -16,3 +23,6 @@ description = "full time specified"
1623

1724
[09d4e30e-728a-4b52-9005-be44a58d9eba]
1825
description = "full time with day roll-over"
26+
27+
[fcec307c-7529-49ab-b0fe-20309197618a]
28+
description = "does not mutate the input"

exercises/practice/gigasecond/gigasecond.spec.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,8 +38,8 @@ describe('Gigasecond', () => {
3838
});
3939

4040
xtest('does not mutate the input', () => {
41-
const input = new Date(Date.UTC(2020, 0, 4, 20, 28, 30));
41+
const input = new Date(Date.UTC(2015, 1, 24, 23, 59, 59));
4242
gigasecond(input);
43-
expect(input).toEqual(new Date(Date.UTC(2020, 0, 4, 20, 28, 30)));
43+
expect(input).toEqual(new Date(Date.UTC(2015, 1, 24, 23, 59, 59)));
4444
});
4545
});

0 commit comments

Comments
 (0)