Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Mocha: expected [Function: wrapper] to throw an error #4

Open
deedubbleyoo opened this issue Apr 4, 2014 · 3 comments
Open

Mocha: expected [Function: wrapper] to throw an error #4

deedubbleyoo opened this issue Apr 4, 2014 · 3 comments

Comments

@deedubbleyoo
Copy link

Hi,

When running the service test template through Karma, the error test fails, as it is not throwing an error.

I happen to be using Mocha (and have converted the matcher to:

expect(wrapper).to.throw('mySvc:  not provided');

Do you have any insight why the test might be failing?

@daniellmb
Copy link
Owner

That test pattern was added about a month ago SHA 6562aa4#diff-3a53f5c03b03e7657006c210bf3d2149 I just ran through the Prepare your environment steps on a fresh clone of the repo and npm test ran without any errors. But that's using Jasmine, I would absolutely love to have AngularJS test patterns for Mocha/Chai but I need to stay focused on adding to the existing patterns before taking that on.

@daniellmb daniellmb changed the title AssertionError: expected [Function: wrapper] to throw an error Mocha: expected [Function: wrapper] to throw an error Apr 5, 2014
@deedubbleyoo
Copy link
Author

I totally understand. We've found your test patterns immensely helpful with our project so please accept our thanks!

If I manage to work out what's going on (and assuming it's mocha related) I'll happily submit a PR with our mocha versions for you.

@daniellmb
Copy link
Owner

Sounds great, I'd be interested in what you find. I have a lot more patterns in the works to add, just not time to do it ;-)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants