Skip to content

Commit 852ea2d

Browse files
committed
feat: new concept exercise - appointment-time
1 parent 0e49622 commit 852ea2d

File tree

4 files changed

+32
-2
lines changed

4 files changed

+32
-2
lines changed

config.json

+8
Original file line numberDiff line numberDiff line change
@@ -255,6 +255,14 @@
255255
"concepts": ["classes"],
256256
"prerequisites": ["objects", "functions", "conditionals-ternary"],
257257
"status": "beta"
258+
},
259+
{
260+
"slug": "appointment-time",
261+
"name": "Appointment Time",
262+
"uuid": "0f694053-a388-457f-89ca-f49be4560469",
263+
"concepts": ["dates"],
264+
"prerequisites": ["classes", "conditionals"],
265+
"status": "beta"
258266
}
259267
],
260268
"practice": [
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
audit=false
+21
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
MIT License
2+
3+
Copyright (c) 2021 Exercism
4+
5+
Permission is hereby granted, free of charge, to any person obtaining a copy
6+
of this software and associated documentation files (the "Software"), to deal
7+
in the Software without restriction, including without limitation the rights
8+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9+
copies of the Software, and to permit persons to whom the Software is
10+
furnished to do so, subject to the following conditions:
11+
12+
The above copyright notice and this permission notice shall be included in all
13+
copies or substantial portions of the Software.
14+
15+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21+
SOFTWARE.

exercises/concept/appointment-time/appointment-time.spec.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -8,13 +8,13 @@ import {
88

99
describe('createAppointment', () => {
1010
test('creates appointment of 4 days later', () => {
11-
expect(createAppointment(4)).toBe(
11+
expect(createAppointment(4)).toEqual(
1212
new Date(Date.now() + 4 * 24 * 3600 * 1000)
1313
);
1414
});
1515

1616
test('creates appointment of 124 days later', () => {
17-
expect(createAppointment(124)).toBe(
17+
expect(createAppointment(124)).toEqual(
1818
new Date(Date.now() + 124 * 24 * 3600 * 1000)
1919
);
2020
});

0 commit comments

Comments
 (0)