Fixed spec failure on Chrome
This commit is contained in:
@@ -96,8 +96,10 @@ describe("jasmineUnderTest.util", function() {
|
|||||||
|
|
||||||
describe("jasmineFile", function() {
|
describe("jasmineFile", function() {
|
||||||
it("returns the file containing jasmine.util", function() {
|
it("returns the file containing jasmine.util", function() {
|
||||||
expect(jasmineUnderTest.util.jasmineFile()).toMatch(/util.js$/);
|
// Chrome sometimes reports foo.js as foo.js/, so tolerate
|
||||||
expect(jasmine.util.jasmineFile()).toMatch(/jasmine.js$/);
|
// a trailing slash if present.
|
||||||
|
expect(jasmineUnderTest.util.jasmineFile()).toMatch(/util.js\/?$/);
|
||||||
|
expect(jasmine.util.jasmineFile()).toMatch(/jasmine.js\/?$/);
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|||||||
@@ -2201,13 +2201,12 @@ describe("Env integration", function() {
|
|||||||
|
|
||||||
var env = new jasmineUnderTest.Env();
|
var env = new jasmineUnderTest.Env();
|
||||||
var reporter = jasmine.createSpyObj('reporter', ['jasmineDone', 'suiteDone', 'specDone']);
|
var reporter = jasmine.createSpyObj('reporter', ['jasmineDone', 'suiteDone', 'specDone']);
|
||||||
|
|
||||||
reporter.jasmineDone.and.callFake(function(e) {
|
reporter.jasmineDone.and.callFake(function(e) {
|
||||||
debugger;
|
|
||||||
expect(e.overallStatus).toEqual('failed');
|
expect(e.overallStatus).toEqual('failed');
|
||||||
done();
|
done();
|
||||||
});
|
});
|
||||||
|
|
||||||
env.addReporter(reporter);
|
env.addReporter(reporter);
|
||||||
env.it('passes', function() {});
|
env.it('passes', function() {});
|
||||||
global.onerror('Uncaught Error: ENOCHEESE');
|
global.onerror('Uncaught Error: ENOCHEESE');
|
||||||
|
|||||||
Reference in New Issue
Block a user