Im trying to write a unit test that tests the result of a promise.
But im always getting this error:

The Debug variable is in the WinJS base.js file.
Im using Jasmine 2.0.
This is how my test looks:
describe("Tests", function () {
it("should pass", function (done) {
var promise = WinJS.Promise.timeout(500).then(function () {
return WinJS.Promise.as([{ name: "Smith" }]);
});
promise.then(function (result) {
expect(result).toBeDefined();
expect(result[0]).toBeDefined();
expect(result[0].name).toBe("Smith");
done(); // Jasmine method.
});
});
});
Anyone know what is wrong and how I can fix it?