ember-cli / ember-cli

The Ember.js command line utility.

Home Page:https://cli.emberjs.com

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

CI is failing

kategengler opened this issue · comments

@kategengler, @kellyselden, and I spent some time poking at this. It seems like a possible race condition because if you start putting in breakpoints the bug goes away. If you look after the tests fail the unresolvable files are in fact present. So it seems like the resolution failure is happening during a small time window in which there's a race between the test setup infrastructure and the code that's looking for these modules.

It is always the same 5 failures in acceptance/smoke-test-slow:

  1. Acceptance: smoke-test ember new foo, make sure addon template overwrites
  2. Acceptance: smoke-test ember test --path with previous build
  3. Acceptance: smoke-test ember test wasm
  4. Acceptance: smoke-test lint fixing after file generation does not fix lint errors with --no-lint-fix
  5. Acceptance: smoke-test lint fixing after file generation does fix lint errors with --lint-fix

They fail when run with yarn test:all or yarn test:slow but do not fail individually or when that entire file is run.

Narrowed to this:
node --unhandled-rejections=strict tests/runner tests/acceptance/addon-smoke-test-slow.js tests/acceptance/smoke-test-slow.js

If the former is run before the later, those 5 tests fail.

Narrowed down to ember addon foo, clean from scratch in the addon-smoke-test-slow file causing the error. Changing the command run there from test to help has no affect, so I determined it was something to do with the ember helper, however, other tests using the ember helper before smoke-test-slow do not cause the failures.

For now, changing the test to await runCommand('node_modules/ember-cli/bin/ember', 'test') solves the issue.

PR incoming.

The above solves this but does not explain what about the ember helper used in that particular test causes the later tests to fail.