-
Notifications
You must be signed in to change notification settings - Fork 7
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
Instructions for installing & using seem to be incomplete, throwing ERROR #29
Comments
Hey, do you have "plugins" option in your Karma configuration file? If you do, then you also have to add the reporter in there, that's how karma works (see "Loading Plugins" section) |
Ah, my bad. Thanks. Might be worth updating the README.md for others who oops like I did. So added that, but I still get the same output: Expected $[0] to have properties
candy: 'bars'
@test/spec/services/membership/membershipSpec.js:284:7 Essentially I'm running: expect(Module.generateConfig(foo, bar)).toEqual({ candy: 'bars' }); // except this is a 65 line object... Guessing this hits the |
Ran a few follow-up tests looking similar to: expect({
name: 'foo',
value: [1,2,3,4,5,6],
things: {stuff: [{andThings: 'shizzle'}]}
}).toEqual({
name: 'foo',
value: [1,2,4,4,5,7],
things: {stuff: [{andThings: 'shizzlesss'}]}
}); Can't be the Expected $.value[2] = 3 to equal 4.
Expected $.value[5] = 6 to equal 7.
Expected $.things.stuff[0].andThings = 'shizzle' to equal 'shizzlesss'. |
My setup is:
|
You are using a jasmne version, which has it's own diff reporting now. My reporter only works with the old jasmine output format. In order to use legacy jasmine output format and my reporter as well, use a 'legacy' option in configuration file. (https://github.com/mradionov/karma-jasmine-diff-reporter#legacy) I will update documentation to adress both of these issues. |
Thanks, thats helpful. Is there a recommended path? If what I am seeing is Jasmine's diff, its not awesome :) |
I guess you choose what works for you. My position is to respect whatever the creators of the Jasmine lib do, not to change it's default behavior for the end users out of the box. Maybe I should consider releasing a new major version, which will have a legacy output by default, if Jasmine's diff is really that bad. It will be either one way or another, because these two ways of displaying diffs are completely different. |
I took legacy = deprecated. Meaning it might be supported soon. Is that incorrect? If not, great. I'm trying to sell my team on using your lib as we upgrade our toolchain, but since it sounded already deprecated there were reservations. Thanks for the feedback! |
Turning the option on ( |
Gotcha. Because with the new output there is no good way to actually do a diff. |
Great, thx! |
Following the example in the
README.md
:$ npm install karma-jasmine-diff-reporter --save-dev my-project@1.3.0-alpha ~/github/my-project └── karma-jasmine-diff-reporter@1.1.0
and
results in:
The text was updated successfully, but these errors were encountered: