Index: test/filterClasses.js |
=================================================================== |
--- a/test/filterClasses.js |
+++ b/test/filterClasses.js |
@@ -159,16 +159,20 @@ |
test.equal(filter2.hitCount, 432, "Known filter returned"); |
filter2.hitCount = 234; |
test.equal(filter1.hitCount, 234, "Changing second wrapper modifies original as well"); |
filter1.delete(); |
filter2.delete(); |
+ test.throws(() => { filter1.delete() == 0; }); |
sergei
2017/10/11 12:52:55
What about putting them into a separate test?
sergei
2017/10/11 12:52:56
IMO it would be better to remove these comparisons
hub
2017/10/11 14:47:01
I don't know was I put the '== 0' here.
I think t
|
+ test.throws(() => { filter1.hitCount == 0; }); |
+ test.throws(() => { filter1._pointer == 0xdeadbeef; }); |
Wladimir Palant
2017/10/11 13:51:52
I agree, comparisons aren't necessary. Also, you s
hub
2017/10/11 14:47:01
Done.
|
+ |
let filter3 = Filter.fromText("someknownfilter"); |
test.equal(filter3.hitCount, 0, "Filter data has been reset once previous instances have been released"); |
filter3.delete(); |
test.done(); |
}; |
exports.testNormalize = function(test) |