-
-
Notifications
You must be signed in to change notification settings - Fork 9
Add support for testdouble-chai #21
Add support for testdouble-chai #21
Conversation
Thinking about the fact that they conflict... Do you think it would be possible to patch one/both of |
@alexlafroscia I've asked a very similar question in nathanboktae/chai-dom#16 and we've concluded that it doesn't seem possible with the current API that Chai has for addons. As you can see in the lack of tests for Can you adjust the PR to only add support for the testdouble stuff for now but not include the failing test? |
Yup, absolutely. |
@@ -49,12 +49,19 @@ var sinonPlugin = { | |||
path: 'sinon-chai.js', | |||
}; | |||
|
|||
var testdoublePlugin = { | |||
name: 'testdouble-chai', | |||
constraint: '^0.5.0', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
what about the releases below 0.5.0
? they don't work?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
AFAIK they all "work" but 0.5.0
removed testdouble
as a peer dependency, which caused some issues with ember-cli-testdouble-chai
because testdouble
was provided by ember-cli-testdouble
.
I think I might need to add some code here to handle bootstrapping https://github.com/BaseCase/testdouble-chai#setup
|
indeed, their UMD wrapper doesn't seem to call |
Yeah, I'm thinking we can just include a file in the addon's |
Just found out about the |
Yeah but you can only overwrite existing methods, if you overwrite an unexisting method it won't work :-/ |
Not sure if you had something else in mind, but I ended up adding an additional, option property to the |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
thanks :)
released as v0.3.2 👍 |
As a note, I added a notice to the |
TODO
testdouble-chai
andsinon-chai
, when both can't be enabledCloses #19