ember-cli / ember-cli/eslint-plugin-ember
Test files are picked up as ember core modules
- Dominant language
- JavaScript
- Stars
- 263
- Forks
- 214
- Avg merge
- 30m
- Merged PRs (30d)
- 5
Description
Currently tests are being picked up by the [isEmberCoreModule](https://github.com/ember-cli/eslint-plugin-ember/blob/master/lib/utils/ember.js#L115) check, possibly triggering rules, depending on the code in the test.
Given some test for a controller like this, it will be picked up as an ember controller because of the path and trigger the [alias-model-in-controller](https://github.com/ember-cli/eslint-plugin-ember/blob/master/lib/rules/alias-model-in-controller.js) rule.
```
import { moduleFor, test } from 'ember-qunit';
const somethingThatNeedsToUseExtend = Ember.Object.extend({...});
moduleFor('controller:my-controller', 'Unit | Controller | my controller', {
...
```
I wll submit a PR, but excluding files with `tests` in the path from the `isEmberCoreModule` check would solve this.
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.