digiaonline / react-foundation

Foundation as React components.
https://digia.online/react-foundation-docs/
MIT License
601 stars 68 forks source link

fix(utilities): cause test suite to run #82

Closed imsnif closed 6 years ago

imsnif commented 6 years ago

Changes proposed in this pull request:

Hey - so I'm not sure if this is intentional or not, but before these changes the aforementioned test suite did not run when running tests. I'm not a mocha expert, but I think it doesn't run describe suites that don't have one or more it clauses?

Anyway, I hope this helps. :)

hugovk commented 6 years ago

@imsnif Hi, thanks for the PR.

How exactly is the test suite failing at the moment?

I just triggered a master build on Travis CI and at least that passed:

https://travis-ci.org/digiaonline/react-foundation/builds/453835366

imsnif commented 6 years ago

Hey @hugovk - sure thing. :) The test suite passes, but these tests do not run. Notice that before this PR, if you do yarn test, 385 tests run - after it, 390 tests run. Mocha apparently doesn't run tests that do not have an it clause.

imsnif commented 6 years ago

Hmm. Though now I notice that on the CI all 390 tests run, just for me locally it's 385 before and 390 after the change. Locally for you it's 390 consistently?

hugovk commented 6 years ago

Aha, locally I also get the same as you!

Before

  385 passing (976ms)

=============================== Coverage summary ===============================
Statements   : 100% ( 416/416 )
Branches     : 94.55% ( 208/220 )
Functions    : 100% ( 67/67 )
Lines        : 100% ( 413/413 )
================================================================================

After

  390 passing (1s)

=============================== Coverage summary ===============================
Statements   : 100% ( 416/416 )
Branches     : 94.55% ( 208/220 )
Functions    : 100% ( 67/67 )
Lines        : 100% ( 413/413 )
================================================================================
imsnif commented 6 years ago

Now I'm mega-curious. :) I think travis has an "ssh into build to debug" feature. Dare I hope you'd be able to do that and look around to feed our curiosity?

Jalle19 commented 6 years ago

@imsnif I don't think that'll be necessary, the master build also ran only 385 tests while the build for this PR ran 390.

hugovk commented 6 years ago

Great!

I'm not sure what Scrutinizer was complaining about and it doesn't give much detail:

image

I restarted it and it's now green:

image

Merging, thanks!