Skip to content

Commit 0e37025

Browse files
committed
Update test to use interval divisible by 16 and target just main test
1 parent c195918 commit 0e37025

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@
3535
"prepare": "npm run build",
3636
"prepublishOnly": "node ./tools/build.js",
3737
"push-release": "git push origin master && git push --tags",
38-
"test": "jest"
38+
"test": "jest src/index"
3939
},
4040
"peerDependencies": {
4141
"react": ">=15"

src/index.test.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -118,7 +118,7 @@ describe('<Timer />', () => {
118118

119119
expect(onStart).toHaveBeenCalledWith({
120120
duration: null,
121-
progress: null,
121+
progress: 0,
122122
time: 0,
123123
});
124124

@@ -135,7 +135,7 @@ describe('<Timer />', () => {
135135
});
136136

137137
expect(onFinish).not.toBeCalled();
138-
clock.tick(115);
138+
clock.tick(112);
139139
expect(onFinish).toBeCalled();
140140

141141
component.unmount();
@@ -190,7 +190,7 @@ describe('<Timer />', () => {
190190
clock.tick(96);
191191
expect(onTimeUpdate).toHaveBeenLastCalledWith({
192192
duration: null,
193-
progress: null,
193+
progress: 0,
194194
time: 96,
195195
});
196196

0 commit comments

Comments
 (0)