Skip to content

Commit

Permalink
Other: Added a test case to find out if all the fallbacks are just fo…
Browse files Browse the repository at this point in the history
…r IE8
  • Loading branch information
dcodeIO committed Dec 26, 2016
1 parent 0d66b83 commit 4375a48
Showing 1 changed file with 24 additions and 0 deletions.
24 changes: 24 additions & 0 deletions tests/_support.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
var tape = require("tape");

var protobuf = require("..");

function name(fn) {
if (!fn)
return "" + fn;
return fn.name;
}

var ans = {};
try {
Object.defineProperty(ans, "wer", {
get: function() {
return 42;
}
});
} catch (e) {}

tape.test("environment supports", function(test) {
test.ok(typeof Uint8Array !== "undefined", "Uint8Array");
test.ok(ans.wer === 42, "getters/setters");
test.end();
});

0 comments on commit 4375a48

Please sign in to comment.