This repository has been archived on 2019-05-14. You can view files and clone it, but cannot push or open issues or pull requests.
Typertext/test/Typertext/Http/HttpException.test.js

16 lines
650 B
JavaScript

describe("Typertext.Http.HttpException", function () {
it("exists", function () {
expect(typeof Typertext.Http.HttpException).toEqual("function");
});
it("works according to the parent class", function () {
var inputString = "Test message",
inputCode = 239,
inputHttp = Typertext.Http.HttpResponseStatus.clientError,
testClass = new Typertext.Http.HttpException(inputString, inputCode, inputHttp);
expect(testClass.GetCode()).toEqual(inputCode);
expect(testClass.GetCustom()).toEqual(inputHttp);
expect(testClass.GetMessage()).toEqual(inputString);
});
});