ember-cli / ember-cli/eslint-plugin-ember
New rule: no-setupTest-from-ember-qunit
- Dominant language
- JavaScript
- Stars
- 263
- Forks
- 214
- Avg merge
- 30m
- Merged PRs (30d)
- 5
Description
As of ember-cli@4.3.0 [emberjs/rfcs#637](https://github.com/emberjs/rfcs/blob/master/text/0637-customizable-test-setups.md) has been implemented in the new application blueprint.
Once an addon or application has migrated to using the new re-exports from `tests/helpers/index.js` they should no longer import them from the classic `ember-qunit` locations.
*Rule details:*
- Prevent importing `setupTest`, `setupApplicationTest`, and `setupRenderingTest` from the `ember-qunit` module
- _Consider_ attempting to write a fixer that will add a new import from `app-name/helpers` instead.
**Bad:**
```js
import { setupTest } from 'ember-qunit';
import { setupRenderingTest } from 'ember-qunit';
import { setupApplicationTest } from 'ember-qunit'
```
(all of these should be forbidden)
**Good:**
```js
import { setupTest } from 'app-name/helpers';
import { setupRenderingTest } from 'app-name/helpers';
import { setupApplicationTest } from 'app-name/helpers';
```
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.