velesin / jasmine-jquery

jQuery matchers and fixture loader for Jasmine framework
MIT License
1.89k stars 347 forks source link

instanceof check fails spec? #188

Open Nate-Wilkins opened 10 years ago

Nate-Wilkins commented 10 years ago
Expecting a function in instanceof check, but got undefined
    at jasmine.JQuery.matchersClass.(anonymous function)   
    (http://localhost:9876/base/Scripts/jasmine/jasmine-jquery.js:490:33)

Not sure why the instanceof would end up failing the spec?? I'm currently just calling toHaveClass

EDIT: Removed the only line of jasmine-jquery except that I'm including it in my runner and still get the above error.

Running Karma with PhantomJS, Chrome - same error

vebersol commented 10 years ago

It also happens to me.

I just put an expect like the one below and got this error:

expect(requests.length).toEqual(1);

Can it be related to the usage of SinonJS?

mrpollo commented 10 years ago

not sure if related but this happened to me as well and i fixed it by moving the load order in karma to make sure jquery was defined first