Skip to content

Commit acb99b6

Browse files
committed
update tests
1 parent 8a67787 commit acb99b6

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

test/ExampleWorker.js

+1
Original file line numberDiff line numberDiff line change
@@ -185,6 +185,7 @@ const prepareEnvironment = options => {
185185
height: 600,
186186
style: {},
187187
addEventListener: () => {},
188+
setAttribute: () => {},
188189
getAttribute: name => ({
189190
'data-pixel-ratio': '1'
190191
}[name]),

test/TestTools.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -238,7 +238,7 @@ const extrinsicSimilarity = (currentCaptures, referenceCaptures, key='extrinsic'
238238
}
239239
}
240240

241-
result[name] = 1 - (totalSimilarity / totalCount);
241+
result[name] = 1 - (totalSimilarity / (totalCount || 1));
242242
}
243243

244244
return result;

0 commit comments

Comments
 (0)