debitoor / chai-subset

"containSubset" object properties matcher for Chai
http://chaijs.com/plugins/chai-subset/
MIT License
82 stars 20 forks source link

Support for AMD/global export #11

Closed leoselig closed 8 years ago

leoselig commented 8 years ago

We needed AMD compatibility for our RequireJS/Karma stack. I basically used the "module system magic" I know from https://github.com/domenic/chai-as-promised/ Would be nice to see it merge - let me know if there is anything that needs to be changed first

eagleeye commented 8 years ago

test coverege decreased, please write tests that uses all kinds of requires

eagleeye commented 8 years ago

@RobertHerhold Are you going to finish this PR?

RobertHerhold commented 8 years ago

@eagleeye I believe you meant @leoselig

eagleeye commented 8 years ago

@RobertHerhold whoops, sorry( Yea, I meant @leoselig

leoselig commented 8 years ago

I'd love to, I won't be able to do so this week though Until then: any experience on how to test the module system-agnostic export? Otherwise, I first have to take a look how this could be done best

On Tue, Aug 18, 2015, 16:12 Andrii Shumada notifications@github.com wrote:

@RobertHerhold https://github.com/RobertHerhold whoops, sorry( Yea, I meant @leoselig https://github.com/leoselig

— Reply to this email directly or view it on GitHub https://github.com/debitoor/chai-subset/pull/11#issuecomment-132223001.

eagleeye commented 8 years ago

@leoselig I think you should add requirejs in dependencies and add a small test, that requires chai and chai subset via requirejs. Also, you should make a cleaner branch for PR, where package name and description are not touched, as well as use strict is not included and so on

eagleeye commented 8 years ago

@leoselig also I found a bit better variation of AMD support in chai itself) https://github.com/chaijs/chai/commit/2035510254fec86d179b75146a552a37fbcdcd18#diff-cee0d57e893bb06a9c55e65f14c03cfdR2

eagleeye commented 8 years ago

Closing, because of inactivity of an author of PR. Feel free to create PR again, if you feel that you can finish what you started