chainpad testing = true, reject non-compliant messages

This commit is contained in:
ansuz
2016-03-29 16:53:40 +02:00
parent afa1104d85
commit 6c340a6527

View File

@@ -372,7 +372,7 @@ var random = Patch.random = function (doc, opCount) {
var PARANOIA = module.exports.PARANOIA = false; var PARANOIA = module.exports.PARANOIA = false;
/* throw errors over non-compliant messages which would otherwise be treated as invalid */ /* throw errors over non-compliant messages which would otherwise be treated as invalid */
var TESTING = module.exports.TESTING = false; var TESTING = module.exports.TESTING = true;
var assert = module.exports.assert = function (expr) { var assert = module.exports.assert = function (expr) {
if (!expr) { throw new Error("Failed assertion"); } if (!expr) { throw new Error("Failed assertion"); }