Rename j$ to jasmineUnderTest for specs

- Clarifies what it is for when writing tests
- No longer named the same as the `jasmine` that is injected into live
  code
This commit is contained in:
Gregg Van Hove
2015-12-03 17:23:32 -08:00
parent a95c2cfe3f
commit 79206ccff5
60 changed files with 702 additions and 896 deletions
+7 -7
View File
@@ -1,6 +1,6 @@
describe("toThrow", function() {
it("throws an error when the actual is not a function", function() {
var matcher = j$.matchers.toThrow();
var matcher = jasmineUnderTest.matchers.toThrow();
expect(function() {
matcher.compare({});
@@ -9,7 +9,7 @@ describe("toThrow", function() {
});
it("fails if actual does not throw", function() {
var matcher = j$.matchers.toThrow(),
var matcher = jasmineUnderTest.matchers.toThrow(),
fn = function() {
return true;
},
@@ -25,7 +25,7 @@ describe("toThrow", function() {
var util = {
equals: jasmine.createSpy('delegated-equal').and.returnValue(true)
},
matcher = j$.matchers.toThrow(util),
matcher = jasmineUnderTest.matchers.toThrow(util),
fn = function() {
throw 5;
},
@@ -38,7 +38,7 @@ describe("toThrow", function() {
});
it("passes even if what is thrown is falsy", function() {
var matcher = j$.matchers.toThrow(),
var matcher = jasmineUnderTest.matchers.toThrow(),
fn = function() {
throw undefined;
},
@@ -53,7 +53,7 @@ describe("toThrow", function() {
var util = {
equals: jasmine.createSpy('delegated-equal').and.returnValue(true)
},
matcher = j$.matchers.toThrow(util),
matcher = jasmineUnderTest.matchers.toThrow(util),
fn = function() {
throw 5;
},
@@ -69,7 +69,7 @@ describe("toThrow", function() {
var util = {
equals: jasmine.createSpy('delegated-equal').and.returnValue(false)
},
matcher = j$.matchers.toThrow(util),
matcher = jasmineUnderTest.matchers.toThrow(util),
fn = function() {
throw 5;
},
@@ -85,7 +85,7 @@ describe("toThrow", function() {
var util = {
equals: jasmine.createSpy('delegated-equal').and.returnValue(false)
},
matcher = j$.matchers.toThrow(util),
matcher = jasmineUnderTest.matchers.toThrow(util),
fn = function() {
throw 5;
},