keeping track of passed expectations
This commit is contained in:
committed by
Sheel Choksi
parent
e1e49e8292
commit
5f34be446c
@@ -23,16 +23,19 @@ getJasmineRequireObj().Spec = function(j$) {
|
||||
id: this.id,
|
||||
description: this.description,
|
||||
fullName: this.getFullName(),
|
||||
failedExpectations: []
|
||||
failedExpectations: [],
|
||||
passedExpectations: []
|
||||
};
|
||||
}
|
||||
|
||||
Spec.prototype.addExpectationResult = function(passed, data) {
|
||||
this.expectCalled = true;
|
||||
var expectationResult = this.expectationResultFactory(data);
|
||||
if (passed) {
|
||||
return;
|
||||
this.result.passedExpectations.push(expectationResult);
|
||||
} else {
|
||||
this.result.failedExpectations.push(expectationResult);
|
||||
}
|
||||
this.result.failedExpectations.push(this.expectationResultFactory(data));
|
||||
};
|
||||
|
||||
Spec.prototype.expect = function(actual) {
|
||||
|
||||
Reference in New Issue
Block a user