Rewrote all unit tests to use Mocha Chai instead of Tape. Fixes #237.#248
Rewrote all unit tests to use Mocha Chai instead of Tape. Fixes #237.#248aendra-rininsland wants to merge 4 commits intogithub-tools:masterfrom
Conversation
1447730 to
9e5bc2e
Compare
9e5bc2e to
2eec6af
Compare
|
I suggest that we add the gulpfile to the linter. |
package.json
Outdated
There was a problem hiding this comment.
Are we still using this Plato?
There was a problem hiding this comment.
@AurelioDeRosa I thought I removed that. Not at the moment, but it might be good to add later. Agreed with adding Gulpfile to linter, will update commit with both fixes.
|
@AurelioDeRosa Quite agreed; have added all JS files and linted them all. |
8c9ba7a to
a75eb14
Compare
.jscsrc
Outdated
There was a problem hiding this comment.
What are the exceptions in our naming conventions to disable this? Just wondering.
There was a problem hiding this comment.
Main reasons I disabled them were _request (dangling underscores) and "per_page" from GitHub's API (camelcase or upper).
Also removed requirement for curly brackets with if statements because quite a few just return or whatever without them. I'm open to requiring ifs with curly brackets, but have just set this that way for the moment so linting passes.
There was a problem hiding this comment.
I see, good point. I think that in regard of _request we can rename it wherever it's used because it isn't even private anymore. In regard of page, we can add an ad hoc exception on a specific line as we do with Istanbul. What do you think?
There was a problem hiding this comment.
@AurelioDeRosa Yep, agreed on renaming _request and re-enabling the check for dangling underscores. That's also a good suggestion re: ad hoc overriding where-ever GitHub uses an underscore for a space, will help prevent people from naming things badly.
For the moment though, can we leave _request as-is and save that for a separate PR? This one is already getting a bit unwieldy. 😄 Will update to re-enable requireCamelCase.
a75eb14 to
ca146fb
Compare
karma.conf.js
Outdated
There was a problem hiding this comment.
This can be removed as mentioned in the documentation:
By default, Karma loads all sibling NPM modules which have a name starting with karma-*.
ca146fb to
0d82b20
Compare
There was a problem hiding this comment.
I think we should explicitly call the file. This will be updated when we'll split in modules.
|
Closed by 1813b0d. |
This removes Tape and replaces it with Mocha + Chai + Sinon. Sinon might be unnecessary because we're testing against a real username/repo most of the time.