trackler 2.2.1.108 → 2.2.1.109
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/trackler/version.rb +1 -1
- data/tracks/java/exercises/hamming/.meta/version +1 -1
- data/tracks/java/exercises/kindergarten-garden/.meta/version +1 -1
- data/tracks/java/exercises/rotational-cipher/.meta/version +1 -1
- data/tracks/java/exercises/scrabble-score/.meta/version +1 -1
- data/tracks/java/exercises/secret-handshake/.meta/version +1 -1
- data/tracks/java/exercises/twelve-days/.meta/version +1 -1
- data/tracks/ocaml/tools/test-generator/src/model.ml +21 -0
- data/tracks/ocaml/tools/test-generator/src/ocaml_special_cases.ml +4 -5
- data/tracks/ocaml/tools/test-generator/src/parser.ml +16 -4
- data/tracks/ocaml/tools/test-generator/src/test_gen.ml +2 -2
- data/tracks/ocaml/tools/test-generator/src/utils.ml +1 -1
- data/tracks/ocaml/tools/test-generator/templates/ocaml/all-your-base/test.ml +1 -1
- data/tracks/ocaml/tools/test-generator/templates/ocaml/bob/test.ml +2 -2
- data/tracks/ocaml/tools/test-generator/templates/ocaml/bracket-push/test.ml +1 -1
- data/tracks/ocaml/tools/test-generator/templates/ocaml/dominoes/test.ml +1 -1
- data/tracks/ocaml/tools/test-generator/templates/ocaml/leap/test.ml +2 -2
- data/tracks/ocaml/tools/test-generator/templates/ocaml/luhn/test.ml +1 -1
- data/tracks/ocaml/tools/test-generator/templates/ocaml/minesweeper/test.ml +1 -1
- data/tracks/ocaml/tools/test-generator/templates/ocaml/palindrome-products/test.ml +1 -1
- data/tracks/ocaml/tools/test-generator/templates/ocaml/pangram/test.ml +1 -1
- data/tracks/ocaml/tools/test-generator/templates/ocaml/prime-factors/test.ml +1 -1
- data/tracks/ocaml/tools/test-generator/templates/ocaml/rectangles/test.ml +1 -1
- data/tracks/ocaml/tools/test-generator/templates/ocaml/run-length-encoding/test.ml +3 -3
- data/tracks/ocaml/tools/test-generator/templates/ocaml/say/test.ml +1 -1
- data/tracks/ocaml/tools/test-generator/templates/ocaml/word-count/test.ml +1 -1
- data/tracks/ocaml/tools/test-generator/test/beer-song.json +382 -31
- data/tracks/ocaml/tools/test-generator/test/clock.json +484 -333
- data/tracks/ocaml/tools/test-generator/test/difference_of_squares.json +38 -26
- data/tracks/ocaml/tools/test-generator/test/hello_world.json +12 -18
- data/tracks/ocaml/tools/test-generator/test/leap.json +33 -34
- data/tracks/ocaml/tools/test-generator/test/parser_test.ml +18 -14
- data/tracks/ocaml/tools/test-generator/test/with-methods-key.json +1 -1
- data/tracks/rust/exercises/allergies/Cargo.toml +1 -1
- data/tracks/rust/exercises/atbash-cipher/Cargo.toml +1 -1
- data/tracks/rust/exercises/binary-search/Cargo.toml +1 -1
- data/tracks/rust/exercises/bob/Cargo.toml +1 -1
- data/tracks/rust/exercises/bracket-push/Cargo.toml +1 -1
- data/tracks/rust/exercises/collatz-conjecture/Cargo.toml +1 -1
- data/tracks/rust/exercises/difference-of-squares/Cargo.toml +1 -1
- data/tracks/rust/exercises/dominoes/Cargo.toml +1 -1
- data/tracks/rust/exercises/gigasecond/Cargo.toml +1 -1
- data/tracks/rust/exercises/grains/Cargo.toml +1 -1
- data/tracks/rust/exercises/hello-world/Cargo.toml +1 -1
- data/tracks/rust/exercises/isogram/Cargo.toml +1 -1
- data/tracks/rust/exercises/largest-series-product/Cargo.toml +1 -1
- data/tracks/rust/exercises/minesweeper/Cargo.toml +1 -1
- data/tracks/rust/exercises/pascals-triangle/Cargo.toml +1 -1
- data/tracks/rust/exercises/perfect-numbers/Cargo.toml +1 -1
- data/tracks/rust/exercises/poker/Cargo.toml +1 -1
- data/tracks/rust/exercises/prime-factors/Cargo.toml +1 -1
- data/tracks/rust/exercises/queen-attack/Cargo.toml +1 -1
- data/tracks/rust/exercises/raindrops/Cargo.toml +1 -1
- data/tracks/rust/exercises/react/Cargo.toml +1 -1
- data/tracks/rust/exercises/rectangles/Cargo.toml +1 -1
- data/tracks/rust/exercises/robot-simulator/Cargo.toml +1 -1
- data/tracks/rust/exercises/run-length-encoding/Cargo.toml +1 -1
- data/tracks/rust/exercises/saddle-points/Cargo.toml +1 -1
- data/tracks/rust/exercises/say/Cargo.toml +1 -1
- data/tracks/rust/exercises/scrabble-score/Cargo.toml +1 -1
- data/tracks/rust/exercises/sieve/Cargo.toml +1 -1
- data/tracks/rust/exercises/space-age/Cargo.toml +1 -1
- data/tracks/rust/exercises/tournament/Cargo.toml +1 -1
- data/tracks/rust/exercises/variable-length-quantity/Cargo.toml +1 -1
- data/tracks/rust/exercises/wordy/Cargo.toml +1 -1
- metadata +2 -2
@@ -1,437 +1,588 @@
|
|
1
|
-
|
2
1
|
{
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
2
|
+
"exercise": "clock",
|
3
|
+
"version": "2.2.1",
|
4
|
+
"comments": [
|
5
|
+
"Most languages require constructing a clock with initial values,",
|
6
|
+
"adding or subtracting some number of minutes, and testing equality",
|
7
|
+
"in some language-native way. Negative and out of range values are",
|
8
|
+
"generally expected to wrap around rather than represent errors."
|
9
|
+
],
|
10
|
+
"cases": [
|
11
|
+
{
|
12
|
+
"description": "Create a new clock with an initial time",
|
14
13
|
"cases": [
|
15
|
-
|
16
|
-
|
14
|
+
{
|
15
|
+
"description": "on the hour",
|
16
|
+
"property": "create",
|
17
|
+
"input": {
|
17
18
|
"hour": 8,
|
18
|
-
"minute": 0
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
19
|
+
"minute": 0
|
20
|
+
},
|
21
|
+
"expected": "08:00"
|
22
|
+
},
|
23
|
+
{
|
24
|
+
"description": "past the hour",
|
25
|
+
"property": "create",
|
26
|
+
"input": {
|
23
27
|
"hour": 11,
|
24
|
-
"minute": 9
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
28
|
+
"minute": 9
|
29
|
+
},
|
30
|
+
"expected": "11:09"
|
31
|
+
},
|
32
|
+
{
|
33
|
+
"description": "midnight is zero hours",
|
34
|
+
"property": "create",
|
35
|
+
"input": {
|
29
36
|
"hour": 24,
|
30
|
-
"minute": 0
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
37
|
+
"minute": 0
|
38
|
+
},
|
39
|
+
"expected": "00:00"
|
40
|
+
},
|
41
|
+
{
|
42
|
+
"description": "hour rolls over",
|
43
|
+
"property": "create",
|
44
|
+
"input": {
|
35
45
|
"hour": 25,
|
36
|
-
"minute": 0
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
46
|
+
"minute": 0
|
47
|
+
},
|
48
|
+
"expected": "01:00"
|
49
|
+
},
|
50
|
+
{
|
51
|
+
"description": "hour rolls over continuously",
|
52
|
+
"property": "create",
|
53
|
+
"input": {
|
41
54
|
"hour": 100,
|
42
|
-
"minute": 0
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
55
|
+
"minute": 0
|
56
|
+
},
|
57
|
+
"expected": "04:00"
|
58
|
+
},
|
59
|
+
{
|
60
|
+
"description": "sixty minutes is next hour",
|
61
|
+
"property": "create",
|
62
|
+
"input": {
|
47
63
|
"hour": 1,
|
48
|
-
"minute": 60
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
64
|
+
"minute": 60
|
65
|
+
},
|
66
|
+
"expected": "02:00"
|
67
|
+
},
|
68
|
+
{
|
69
|
+
"description": "minutes roll over",
|
70
|
+
"property": "create",
|
71
|
+
"input": {
|
53
72
|
"hour": 0,
|
54
|
-
"minute": 160
|
55
|
-
|
56
|
-
|
57
|
-
|
58
|
-
|
73
|
+
"minute": 160
|
74
|
+
},
|
75
|
+
"expected": "02:40"
|
76
|
+
},
|
77
|
+
{
|
78
|
+
"description": "minutes roll over continuously",
|
79
|
+
"property": "create",
|
80
|
+
"input": {
|
59
81
|
"hour": 0,
|
60
|
-
"minute": 1723
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
82
|
+
"minute": 1723
|
83
|
+
},
|
84
|
+
"expected": "04:43"
|
85
|
+
},
|
86
|
+
{
|
87
|
+
"description": "hour and minutes roll over",
|
88
|
+
"property": "create",
|
89
|
+
"input": {
|
65
90
|
"hour": 25,
|
66
|
-
"minute": 160
|
67
|
-
|
68
|
-
|
69
|
-
|
70
|
-
|
91
|
+
"minute": 160
|
92
|
+
},
|
93
|
+
"expected": "03:40"
|
94
|
+
},
|
95
|
+
{
|
96
|
+
"description": "hour and minutes roll over continuously",
|
97
|
+
"property": "create",
|
98
|
+
"input": {
|
71
99
|
"hour": 201,
|
72
|
-
"minute": 3001
|
73
|
-
|
74
|
-
|
75
|
-
|
76
|
-
|
100
|
+
"minute": 3001
|
101
|
+
},
|
102
|
+
"expected": "11:01"
|
103
|
+
},
|
104
|
+
{
|
105
|
+
"description": "hour and minutes roll over to exactly midnight",
|
106
|
+
"property": "create",
|
107
|
+
"input": {
|
77
108
|
"hour": 72,
|
78
|
-
"minute": 8640
|
79
|
-
|
80
|
-
|
81
|
-
|
82
|
-
|
109
|
+
"minute": 8640
|
110
|
+
},
|
111
|
+
"expected": "00:00"
|
112
|
+
},
|
113
|
+
{
|
114
|
+
"description": "negative hour",
|
115
|
+
"property": "create",
|
116
|
+
"input": {
|
83
117
|
"hour": -1,
|
84
|
-
"minute": 15
|
85
|
-
|
86
|
-
|
87
|
-
|
88
|
-
|
118
|
+
"minute": 15
|
119
|
+
},
|
120
|
+
"expected": "23:15"
|
121
|
+
},
|
122
|
+
{
|
123
|
+
"description": "negative hour rolls over",
|
124
|
+
"property": "create",
|
125
|
+
"input": {
|
89
126
|
"hour": -25,
|
90
|
-
"minute": 0
|
91
|
-
|
92
|
-
|
93
|
-
|
94
|
-
|
127
|
+
"minute": 0
|
128
|
+
},
|
129
|
+
"expected": "23:00"
|
130
|
+
},
|
131
|
+
{
|
132
|
+
"description": "negative hour rolls over continuously",
|
133
|
+
"property": "create",
|
134
|
+
"input": {
|
95
135
|
"hour": -91,
|
96
|
-
"minute": 0
|
97
|
-
|
98
|
-
|
99
|
-
|
100
|
-
|
136
|
+
"minute": 0
|
137
|
+
},
|
138
|
+
"expected": "05:00"
|
139
|
+
},
|
140
|
+
{
|
141
|
+
"description": "negative minutes",
|
142
|
+
"property": "create",
|
143
|
+
"input": {
|
101
144
|
"hour": 1,
|
102
|
-
"minute": -40
|
103
|
-
|
104
|
-
|
105
|
-
|
106
|
-
|
145
|
+
"minute": -40
|
146
|
+
},
|
147
|
+
"expected": "00:20"
|
148
|
+
},
|
149
|
+
{
|
150
|
+
"description": "negative minutes roll over",
|
151
|
+
"property": "create",
|
152
|
+
"input": {
|
107
153
|
"hour": 1,
|
108
|
-
"minute": -160
|
109
|
-
|
110
|
-
|
111
|
-
|
112
|
-
|
154
|
+
"minute": -160
|
155
|
+
},
|
156
|
+
"expected": "22:20"
|
157
|
+
},
|
158
|
+
{
|
159
|
+
"description": "negative minutes roll over continuously",
|
160
|
+
"property": "create",
|
161
|
+
"input": {
|
113
162
|
"hour": 1,
|
114
|
-
"minute": -4820
|
115
|
-
|
116
|
-
|
117
|
-
|
118
|
-
|
163
|
+
"minute": -4820
|
164
|
+
},
|
165
|
+
"expected": "16:40"
|
166
|
+
},
|
167
|
+
{
|
168
|
+
"description": "negative hour and minutes both roll over",
|
169
|
+
"property": "create",
|
170
|
+
"input": {
|
119
171
|
"hour": -25,
|
120
|
-
"minute": -160
|
121
|
-
|
122
|
-
|
123
|
-
|
124
|
-
|
172
|
+
"minute": -160
|
173
|
+
},
|
174
|
+
"expected": "20:20"
|
175
|
+
},
|
176
|
+
{
|
177
|
+
"description": "negative hour and minutes both roll over continuously",
|
178
|
+
"property": "create",
|
179
|
+
"input": {
|
125
180
|
"hour": -121,
|
126
|
-
"minute": -5810
|
127
|
-
|
128
|
-
|
181
|
+
"minute": -5810
|
182
|
+
},
|
183
|
+
"expected": "22:10"
|
184
|
+
}
|
129
185
|
]
|
130
|
-
|
131
|
-
|
132
|
-
"description":
|
133
|
-
"Test adding and subtracting minutes."
|
134
|
-
],
|
186
|
+
},
|
187
|
+
{
|
188
|
+
"description": "Add minutes",
|
135
189
|
"cases": [
|
136
|
-
|
137
|
-
|
190
|
+
{
|
191
|
+
"description": "add minutes",
|
192
|
+
"property": "add",
|
193
|
+
"input": {
|
138
194
|
"hour": 10,
|
139
195
|
"minute": 0,
|
140
|
-
"
|
141
|
-
|
142
|
-
|
143
|
-
|
144
|
-
|
196
|
+
"value": 3
|
197
|
+
},
|
198
|
+
"expected": "10:03"
|
199
|
+
},
|
200
|
+
{
|
201
|
+
"description": "add no minutes",
|
202
|
+
"property": "add",
|
203
|
+
"input": {
|
145
204
|
"hour": 6,
|
146
205
|
"minute": 41,
|
147
|
-
"
|
148
|
-
|
149
|
-
|
150
|
-
|
151
|
-
|
206
|
+
"value": 0
|
207
|
+
},
|
208
|
+
"expected": "06:41"
|
209
|
+
},
|
210
|
+
{
|
211
|
+
"description": "add to next hour",
|
212
|
+
"property": "add",
|
213
|
+
"input": {
|
152
214
|
"hour": 0,
|
153
215
|
"minute": 45,
|
154
|
-
"
|
155
|
-
|
156
|
-
|
157
|
-
|
158
|
-
|
216
|
+
"value": 40
|
217
|
+
},
|
218
|
+
"expected": "01:25"
|
219
|
+
},
|
220
|
+
{
|
221
|
+
"description": "add more than one hour",
|
222
|
+
"property": "add",
|
223
|
+
"input": {
|
159
224
|
"hour": 10,
|
160
225
|
"minute": 0,
|
161
|
-
"
|
162
|
-
|
163
|
-
|
164
|
-
|
165
|
-
|
226
|
+
"value": 61
|
227
|
+
},
|
228
|
+
"expected": "11:01"
|
229
|
+
},
|
230
|
+
{
|
231
|
+
"description": "add more than two hours with carry",
|
232
|
+
"property": "add",
|
233
|
+
"input": {
|
166
234
|
"hour": 0,
|
167
235
|
"minute": 45,
|
168
|
-
"
|
169
|
-
|
170
|
-
|
171
|
-
|
172
|
-
|
236
|
+
"value": 160
|
237
|
+
},
|
238
|
+
"expected": "03:25"
|
239
|
+
},
|
240
|
+
{
|
241
|
+
"description": "add across midnight",
|
242
|
+
"property": "add",
|
243
|
+
"input": {
|
173
244
|
"hour": 23,
|
174
245
|
"minute": 59,
|
175
|
-
"
|
176
|
-
|
177
|
-
|
178
|
-
|
179
|
-
|
246
|
+
"value": 2
|
247
|
+
},
|
248
|
+
"expected": "00:01"
|
249
|
+
},
|
250
|
+
{
|
251
|
+
"description": "add more than one day (1500 min = 25 hrs)",
|
252
|
+
"property": "add",
|
253
|
+
"input": {
|
180
254
|
"hour": 5,
|
181
255
|
"minute": 32,
|
182
|
-
"
|
183
|
-
|
184
|
-
|
185
|
-
|
186
|
-
|
256
|
+
"value": 1500
|
257
|
+
},
|
258
|
+
"expected": "06:32"
|
259
|
+
},
|
260
|
+
{
|
261
|
+
"description": "add more than two days",
|
262
|
+
"property": "add",
|
263
|
+
"input": {
|
187
264
|
"hour": 1,
|
188
265
|
"minute": 1,
|
189
|
-
"
|
190
|
-
|
191
|
-
|
192
|
-
|
193
|
-
|
266
|
+
"value": 3500
|
267
|
+
},
|
268
|
+
"expected": "11:21"
|
269
|
+
}
|
270
|
+
]
|
271
|
+
},
|
272
|
+
{
|
273
|
+
"description": "Subtract minutes",
|
274
|
+
"cases": [
|
275
|
+
{
|
276
|
+
"description": "subtract minutes",
|
277
|
+
"property": "subtract",
|
278
|
+
"input": {
|
194
279
|
"hour": 10,
|
195
280
|
"minute": 3,
|
196
|
-
"
|
197
|
-
|
198
|
-
|
199
|
-
|
200
|
-
|
281
|
+
"value": 3
|
282
|
+
},
|
283
|
+
"expected": "10:00"
|
284
|
+
},
|
285
|
+
{
|
286
|
+
"description": "subtract to previous hour",
|
287
|
+
"property": "subtract",
|
288
|
+
"input": {
|
201
289
|
"hour": 10,
|
202
290
|
"minute": 3,
|
203
|
-
"
|
204
|
-
|
205
|
-
|
206
|
-
|
207
|
-
|
291
|
+
"value": 30
|
292
|
+
},
|
293
|
+
"expected": "09:33"
|
294
|
+
},
|
295
|
+
{
|
296
|
+
"description": "subtract more than an hour",
|
297
|
+
"property": "subtract",
|
298
|
+
"input": {
|
208
299
|
"hour": 10,
|
209
300
|
"minute": 3,
|
210
|
-
"
|
211
|
-
|
212
|
-
|
213
|
-
|
214
|
-
|
301
|
+
"value": 70
|
302
|
+
},
|
303
|
+
"expected": "08:53"
|
304
|
+
},
|
305
|
+
{
|
306
|
+
"description": "subtract across midnight",
|
307
|
+
"property": "subtract",
|
308
|
+
"input": {
|
215
309
|
"hour": 0,
|
216
310
|
"minute": 3,
|
217
|
-
"
|
218
|
-
|
219
|
-
|
220
|
-
|
221
|
-
|
311
|
+
"value": 4
|
312
|
+
},
|
313
|
+
"expected": "23:59"
|
314
|
+
},
|
315
|
+
{
|
316
|
+
"description": "subtract more than two hours",
|
317
|
+
"property": "subtract",
|
318
|
+
"input": {
|
222
319
|
"hour": 0,
|
223
320
|
"minute": 0,
|
224
|
-
"
|
225
|
-
|
226
|
-
|
227
|
-
|
228
|
-
|
321
|
+
"value": 160
|
322
|
+
},
|
323
|
+
"expected": "21:20"
|
324
|
+
},
|
325
|
+
{
|
326
|
+
"description": "subtract more than two hours with borrow",
|
327
|
+
"property": "subtract",
|
328
|
+
"input": {
|
229
329
|
"hour": 6,
|
230
330
|
"minute": 15,
|
231
|
-
"
|
232
|
-
|
233
|
-
|
234
|
-
|
235
|
-
|
331
|
+
"value": 160
|
332
|
+
},
|
333
|
+
"expected": "03:35"
|
334
|
+
},
|
335
|
+
{
|
336
|
+
"description": "subtract more than one day (1500 min = 25 hrs)",
|
337
|
+
"property": "subtract",
|
338
|
+
"input": {
|
236
339
|
"hour": 5,
|
237
340
|
"minute": 32,
|
238
|
-
"
|
239
|
-
|
240
|
-
|
241
|
-
|
242
|
-
|
341
|
+
"value": 1500
|
342
|
+
},
|
343
|
+
"expected": "04:32"
|
344
|
+
},
|
345
|
+
{
|
346
|
+
"description": "subtract more than two days",
|
347
|
+
"property": "subtract",
|
348
|
+
"input": {
|
243
349
|
"hour": 2,
|
244
350
|
"minute": 20,
|
245
|
-
"
|
246
|
-
|
247
|
-
|
351
|
+
"value": 3000
|
352
|
+
},
|
353
|
+
"expected": "00:20"
|
354
|
+
}
|
248
355
|
]
|
249
|
-
|
250
|
-
|
251
|
-
"description":
|
252
|
-
"Construct two separate clocks, set times, test if they are equal."
|
253
|
-
],
|
356
|
+
},
|
357
|
+
{
|
358
|
+
"description": "Compare two clocks for equality",
|
254
359
|
"cases": [
|
255
|
-
|
256
|
-
|
360
|
+
{
|
361
|
+
"description": "clocks with same time",
|
362
|
+
"property": "equal",
|
363
|
+
"input": {
|
257
364
|
"clock1": {
|
258
|
-
|
259
|
-
|
365
|
+
"hour": 15,
|
366
|
+
"minute": 37
|
260
367
|
},
|
261
368
|
"clock2": {
|
262
|
-
|
263
|
-
|
264
|
-
}
|
265
|
-
|
266
|
-
|
267
|
-
|
268
|
-
|
369
|
+
"hour": 15,
|
370
|
+
"minute": 37
|
371
|
+
}
|
372
|
+
},
|
373
|
+
"expected": true
|
374
|
+
},
|
375
|
+
{
|
376
|
+
"description": "clocks a minute apart",
|
377
|
+
"property": "equal",
|
378
|
+
"input": {
|
269
379
|
"clock1": {
|
270
|
-
|
271
|
-
|
380
|
+
"hour": 15,
|
381
|
+
"minute": 36
|
272
382
|
},
|
273
383
|
"clock2": {
|
274
|
-
|
275
|
-
|
276
|
-
}
|
277
|
-
|
278
|
-
|
279
|
-
|
280
|
-
|
384
|
+
"hour": 15,
|
385
|
+
"minute": 37
|
386
|
+
}
|
387
|
+
},
|
388
|
+
"expected": false
|
389
|
+
},
|
390
|
+
{
|
391
|
+
"description": "clocks an hour apart",
|
392
|
+
"property": "equal",
|
393
|
+
"input": {
|
281
394
|
"clock1": {
|
282
|
-
|
283
|
-
|
395
|
+
"hour": 14,
|
396
|
+
"minute": 37
|
284
397
|
},
|
285
398
|
"clock2": {
|
286
|
-
|
287
|
-
|
288
|
-
}
|
289
|
-
|
290
|
-
|
291
|
-
|
292
|
-
|
399
|
+
"hour": 15,
|
400
|
+
"minute": 37
|
401
|
+
}
|
402
|
+
},
|
403
|
+
"expected": false
|
404
|
+
},
|
405
|
+
{
|
406
|
+
"description": "clocks with hour overflow",
|
407
|
+
"property": "equal",
|
408
|
+
"input": {
|
293
409
|
"clock1": {
|
294
|
-
|
295
|
-
|
410
|
+
"hour": 10,
|
411
|
+
"minute": 37
|
296
412
|
},
|
297
413
|
"clock2": {
|
298
|
-
|
299
|
-
|
300
|
-
}
|
301
|
-
|
302
|
-
|
303
|
-
|
304
|
-
|
414
|
+
"hour": 34,
|
415
|
+
"minute": 37
|
416
|
+
}
|
417
|
+
},
|
418
|
+
"expected": true
|
419
|
+
},
|
420
|
+
{
|
421
|
+
"description": "clocks with hour overflow by several days",
|
422
|
+
"property": "equal",
|
423
|
+
"input": {
|
305
424
|
"clock1": {
|
306
|
-
|
307
|
-
|
425
|
+
"hour": 3,
|
426
|
+
"minute": 11
|
308
427
|
},
|
309
428
|
"clock2": {
|
310
|
-
|
311
|
-
|
312
|
-
}
|
313
|
-
|
314
|
-
|
315
|
-
|
316
|
-
|
429
|
+
"hour": 99,
|
430
|
+
"minute": 11
|
431
|
+
}
|
432
|
+
},
|
433
|
+
"expected": true
|
434
|
+
},
|
435
|
+
{
|
436
|
+
"description": "clocks with negative hour",
|
437
|
+
"property": "equal",
|
438
|
+
"input": {
|
317
439
|
"clock1": {
|
318
|
-
|
319
|
-
|
440
|
+
"hour": 22,
|
441
|
+
"minute": 40
|
320
442
|
},
|
321
443
|
"clock2": {
|
322
|
-
|
323
|
-
|
324
|
-
}
|
325
|
-
|
326
|
-
|
327
|
-
|
328
|
-
|
444
|
+
"hour": -2,
|
445
|
+
"minute": 40
|
446
|
+
}
|
447
|
+
},
|
448
|
+
"expected": true
|
449
|
+
},
|
450
|
+
{
|
451
|
+
"description": "clocks with negative hour that wraps",
|
452
|
+
"property": "equal",
|
453
|
+
"input": {
|
329
454
|
"clock1": {
|
330
|
-
|
331
|
-
|
455
|
+
"hour": 17,
|
456
|
+
"minute": 3
|
332
457
|
},
|
333
458
|
"clock2": {
|
334
|
-
|
335
|
-
|
336
|
-
}
|
337
|
-
|
338
|
-
|
339
|
-
|
340
|
-
|
459
|
+
"hour": -31,
|
460
|
+
"minute": 3
|
461
|
+
}
|
462
|
+
},
|
463
|
+
"expected": true
|
464
|
+
},
|
465
|
+
{
|
466
|
+
"description": "clocks with negative hour that wraps multiple times",
|
467
|
+
"property": "equal",
|
468
|
+
"input": {
|
341
469
|
"clock1": {
|
342
|
-
|
343
|
-
|
470
|
+
"hour": 13,
|
471
|
+
"minute": 49
|
344
472
|
},
|
345
473
|
"clock2": {
|
346
|
-
|
347
|
-
|
348
|
-
}
|
349
|
-
|
350
|
-
|
351
|
-
|
352
|
-
|
474
|
+
"hour": -83,
|
475
|
+
"minute": 49
|
476
|
+
}
|
477
|
+
},
|
478
|
+
"expected": true
|
479
|
+
},
|
480
|
+
{
|
481
|
+
"description": "clocks with minute overflow",
|
482
|
+
"property": "equal",
|
483
|
+
"input": {
|
353
484
|
"clock1": {
|
354
|
-
|
355
|
-
|
485
|
+
"hour": 0,
|
486
|
+
"minute": 1
|
356
487
|
},
|
357
488
|
"clock2": {
|
358
|
-
|
359
|
-
|
360
|
-
}
|
361
|
-
|
362
|
-
|
363
|
-
|
364
|
-
|
489
|
+
"hour": 0,
|
490
|
+
"minute": 1441
|
491
|
+
}
|
492
|
+
},
|
493
|
+
"expected": true
|
494
|
+
},
|
495
|
+
{
|
496
|
+
"description": "clocks with minute overflow by several days",
|
497
|
+
"property": "equal",
|
498
|
+
"input": {
|
365
499
|
"clock1": {
|
366
|
-
|
367
|
-
|
500
|
+
"hour": 2,
|
501
|
+
"minute": 2
|
368
502
|
},
|
369
503
|
"clock2": {
|
370
|
-
|
371
|
-
|
372
|
-
}
|
373
|
-
|
374
|
-
|
375
|
-
|
376
|
-
|
504
|
+
"hour": 2,
|
505
|
+
"minute": 4322
|
506
|
+
}
|
507
|
+
},
|
508
|
+
"expected": true
|
509
|
+
},
|
510
|
+
{
|
511
|
+
"description": "clocks with negative minute",
|
512
|
+
"property": "equal",
|
513
|
+
"input": {
|
377
514
|
"clock1": {
|
378
|
-
|
379
|
-
|
515
|
+
"hour": 2,
|
516
|
+
"minute": 40
|
380
517
|
},
|
381
518
|
"clock2": {
|
382
|
-
|
383
|
-
|
384
|
-
}
|
385
|
-
|
386
|
-
|
387
|
-
|
388
|
-
|
519
|
+
"hour": 3,
|
520
|
+
"minute": -20
|
521
|
+
}
|
522
|
+
},
|
523
|
+
"expected": true
|
524
|
+
},
|
525
|
+
{
|
526
|
+
"description": "clocks with negative minute that wraps",
|
527
|
+
"property": "equal",
|
528
|
+
"input": {
|
389
529
|
"clock1": {
|
390
|
-
|
391
|
-
|
530
|
+
"hour": 4,
|
531
|
+
"minute": 10
|
392
532
|
},
|
393
533
|
"clock2": {
|
394
|
-
|
395
|
-
|
396
|
-
}
|
397
|
-
|
398
|
-
|
399
|
-
|
400
|
-
|
534
|
+
"hour": 5,
|
535
|
+
"minute": -1490
|
536
|
+
}
|
537
|
+
},
|
538
|
+
"expected": true
|
539
|
+
},
|
540
|
+
{
|
541
|
+
"description": "clocks with negative minute that wraps multiple times",
|
542
|
+
"property": "equal",
|
543
|
+
"input": {
|
401
544
|
"clock1": {
|
402
|
-
|
403
|
-
|
545
|
+
"hour": 6,
|
546
|
+
"minute": 15
|
404
547
|
},
|
405
548
|
"clock2": {
|
406
|
-
|
407
|
-
|
408
|
-
}
|
409
|
-
|
410
|
-
|
411
|
-
|
412
|
-
|
549
|
+
"hour": 6,
|
550
|
+
"minute": -4305
|
551
|
+
}
|
552
|
+
},
|
553
|
+
"expected": true
|
554
|
+
},
|
555
|
+
{
|
556
|
+
"description": "clocks with negative hours and minutes",
|
557
|
+
"property": "equal",
|
558
|
+
"input": {
|
413
559
|
"clock1": {
|
414
|
-
|
415
|
-
|
560
|
+
"hour": 7,
|
561
|
+
"minute": 32
|
416
562
|
},
|
417
563
|
"clock2": {
|
418
|
-
|
419
|
-
|
420
|
-
}
|
421
|
-
|
422
|
-
|
423
|
-
|
424
|
-
|
564
|
+
"hour": -12,
|
565
|
+
"minute": -268
|
566
|
+
}
|
567
|
+
},
|
568
|
+
"expected": true
|
569
|
+
},
|
570
|
+
{
|
571
|
+
"description": "clocks with negative hours and minutes that wrap",
|
572
|
+
"property": "equal",
|
573
|
+
"input": {
|
425
574
|
"clock1": {
|
426
|
-
|
427
|
-
|
575
|
+
"hour": 18,
|
576
|
+
"minute": 7
|
428
577
|
},
|
429
578
|
"clock2": {
|
430
|
-
|
431
|
-
|
432
|
-
}
|
433
|
-
|
434
|
-
|
579
|
+
"hour": -54,
|
580
|
+
"minute": -11513
|
581
|
+
}
|
582
|
+
},
|
583
|
+
"expected": true
|
584
|
+
}
|
435
585
|
]
|
436
|
-
|
586
|
+
}
|
587
|
+
]
|
437
588
|
}
|