Skip to content

Commit

Permalink
Merge branch 'to-throw-error-unused-param' of https://github.com/Fuzz…
Browse files Browse the repository at this point in the history
…ySockets/jasmine into FuzzySockets-to-throw-error-unused-param
  • Loading branch information
Gregg Van Hove committed Oct 27, 2015
2 parents 8e317d4 + c2ae3b6 commit 25d7351
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 10 deletions.
2 changes: 1 addition & 1 deletion lib/jasmine-core/jasmine.js
Original file line number Diff line number Diff line change
Expand Up @@ -3230,7 +3230,7 @@ getJasmineRequireObj().toThrow = function(j$) {
};

getJasmineRequireObj().toThrowError = function(j$) {
function toThrowError (util) {
function toThrowError () {
return {
compare: function(actual) {
var threw = false,
Expand Down
16 changes: 8 additions & 8 deletions spec/core/matchers/toThrowErrorSpec.js
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,7 @@ describe("toThrowError", function() {
var util = {
equals: jasmine.createSpy('delegated-equal').and.returnValue(true)
},
matcher = j$.matchers.toThrowError(util),
matcher = j$.matchers.toThrowError(),
fn = function() {
throw new Error();
},
Expand All @@ -162,7 +162,7 @@ describe("toThrowError", function() {
var util = {
equals: jasmine.createSpy('delegated-equal').and.returnValue(true)
},
matcher = j$.matchers.toThrowError(util),
matcher = j$.matchers.toThrowError(),
CustomError = function CustomError(arg) { arg.x },
fn = function() {
throw new CustomError({ x: 1 });
Expand All @@ -181,7 +181,7 @@ describe("toThrowError", function() {
var util = {
equals: jasmine.createSpy('delegated-equal').and.returnValue(false)
},
matcher = j$.matchers.toThrowError(util),
matcher = j$.matchers.toThrowError(),
fn = function() {
throw new Error();
},
Expand All @@ -197,7 +197,7 @@ describe("toThrowError", function() {
var util = {
equals: jasmine.createSpy('delegated-equal').and.returnValue(true)
},
matcher = j$.matchers.toThrowError(util),
matcher = j$.matchers.toThrowError(),
fn = function() {
throw new TypeError("foo");
},
Expand All @@ -213,7 +213,7 @@ describe("toThrowError", function() {
var util = {
equals: jasmine.createSpy('delegated-equal').and.returnValue(true)
},
matcher = j$.matchers.toThrowError(util),
matcher = j$.matchers.toThrowError(),
CustomError = function CustomError(arg) { this.message = arg.message },
fn = function() {
throw new CustomError({message: "foo"});
Expand All @@ -232,7 +232,7 @@ describe("toThrowError", function() {
var util = {
equals: jasmine.createSpy('delegated-equal').and.returnValue(false)
},
matcher = j$.matchers.toThrowError(util),
matcher = j$.matchers.toThrowError(),
fn = function() {
throw new TypeError("foo");
},
Expand All @@ -248,7 +248,7 @@ describe("toThrowError", function() {
var util = {
equals: jasmine.createSpy('delegated-equal').and.returnValue(true)
},
matcher = j$.matchers.toThrowError(util),
matcher = j$.matchers.toThrowError(),
fn = function() {
throw new TypeError("foo");
},
Expand All @@ -264,7 +264,7 @@ describe("toThrowError", function() {
var util = {
equals: jasmine.createSpy('delegated-equal').and.returnValue(false)
},
matcher = j$.matchers.toThrowError(util),
matcher = j$.matchers.toThrowError(),
fn = function() {
throw new TypeError("foo");
},
Expand Down
2 changes: 1 addition & 1 deletion src/core/matchers/toThrowError.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
getJasmineRequireObj().toThrowError = function(j$) {
function toThrowError (util) {
function toThrowError () {
return {
compare: function(actual) {
var threw = false,
Expand Down

0 comments on commit 25d7351

Please sign in to comment.