Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

no-test-import-export rule should allowed importing from tests/helpers folder #889

Closed
raido opened this issue Jul 16, 2020 · 3 comments · Fixed by #895
Closed

no-test-import-export rule should allowed importing from tests/helpers folder #889

raido opened this issue Jul 16, 2020 · 3 comments · Fixed by #895
Labels

Comments

@raido
Copy link
Contributor

raido commented Jul 16, 2020

I have hit use case where I have couple of helpers, like tests/helpers/setup-application-test.js which wrap default setupApplicationTest for additional setup.

Now with this rule all my helpers get triggered for lint error. For now I renamed the files but this seems inconvenient and also explicitly updating eslintrc.js to turn off this rule for just tests/helpers seems incorrect.

if (importSource.endsWith('-test')) {

@rwjblue
Copy link
Member

rwjblue commented Jul 17, 2020

Ya, agree. Also emberjs/rfcs#637 will explicitly be having folks import from my-app/tests/helpers (using tests/helpers/index.js for some reexports) in all generated tests. The RFC is in FCP, and will likely land soon...

@raido
Copy link
Contributor Author

raido commented Aug 12, 2020

Not sure this is fixed for relative path imports, see comment: #895 (review)

@bmish
Copy link
Member

bmish commented Aug 12, 2020

Follow-up fix: #911

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants