Skip to content
This repository has been archived by the owner on Dec 13, 2019. It is now read-only.

Test helper #169

Merged
merged 9 commits into from
Nov 6, 2017
Merged

Test helper #169

merged 9 commits into from
Nov 6, 2017

Conversation

rorticus
Copy link
Contributor

@rorticus rorticus commented Nov 3, 2017

Copying the custom loader from https://github.com/dojo/shim/pull/114/files#diff-f2f1547c4e267fa797af2b73e3456bd3R1 and injecting into the intern config automagically.

This loader loads the @dojo/loader, configures it with @dojo/shim/util/amd and loads @dojo/shim/main to load the TS helpers.

This removes a bunch of boilerplate config from the other packages. Unfortunately this doesn't work when testing @dojo/shim, since the loader is different, so we have to provide a way to override the loader.

@codecov
Copy link

codecov bot commented Nov 3, 2017

Codecov Report

Merging #169 into master will increase coverage by 0.9%.
The diff coverage is 100%.

Impacted file tree graph

@@            Coverage Diff            @@
##           master     #169     +/-   ##
=========================================
+ Coverage   69.62%   70.53%   +0.9%     
=========================================
  Files          27       28      +1     
  Lines         642      655     +13     
  Branches      102      104      +2     
=========================================
+ Hits          447      462     +15     
+ Misses        186      184      -2     
  Partials        9        9
Impacted Files Coverage Δ
options/intern.ts 100% <100%> (+100%) ⬆️
lib/intern/internLoader.js 80% <0%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update c50e6fd...d8ce2f8. Read the comment docs.

Copy link
Member

@kitsonk kitsonk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No tests?

@rorticus rorticus mentioned this pull request Nov 3, 2017
3 tasks
@rorticus
Copy link
Contributor Author

rorticus commented Nov 3, 2017

@kitsonk well... the test helper is loaded by intern so there isn't any coverage info for that. I can try to mock the global intern methods and then load the script from a test. Could get some coverage that way. Also.. it looks like the intern task doesn't have any tests right now 😛

With all that being said. I'm happy to add the tests if we want to put that additional time in as part of this PR.

@rorticus
Copy link
Contributor Author

rorticus commented Nov 3, 2017

Tested this with @dojo/widget-core to ensure backwards compatibility, we should be able to release this now and existing packages will work.

@rorticus rorticus requested a review from jason0x43 November 6, 2017 14:44
"dojo-loader": "latest",
"grunt": "^1.0.1",
"istanbul-lib-instrument": "^1.9.1",
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't know that I technically need this as it is already loaded by intern...

@rorticus rorticus merged commit bb29af5 into dojo:master Nov 6, 2017
@dylans dylans added this to the beta.4 milestone Dec 22, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants