Add test for JsonException
This commit is contained in:
parent
e9cf9f5f17
commit
6d52a912b4
15
test/Typertext/Json/JsonException.test.js
Normal file
15
test/Typertext/Json/JsonException.test.js
Normal file
|
@ -0,0 +1,15 @@
|
|||
describe("Typertext.Json.JsonException", function () {
|
||||
it("exists", function () {
|
||||
expect(typeof Typertext.Json.JsonException).toEqual("function");
|
||||
});
|
||||
|
||||
it("works according to the parent class", function () {
|
||||
var inputString = "Test message",
|
||||
inputCode = 239,
|
||||
testClass = new Typertext.Json.JsonException(inputString, inputCode, null);
|
||||
|
||||
expect(testClass.GetCode()).toEqual(inputCode);
|
||||
expect(testClass.GetCustom()).toEqual(null);
|
||||
expect(testClass.GetMessage()).toEqual(inputString);
|
||||
});
|
||||
});
|
Reference in a new issue