Closed BnitoBzh closed 2 years ago
Thanks for reporting this issue. The fasted way to get this issue resolved would be to submit a PR, as at the moment I don't know when I will have time to look at this issue.
Regarding the https://github.com/ember-cli/eslint-plugin-ember/blob/master/docs/rules/no-test-import-export.md rule, it only mentions to not import any file ending in -test.js
. I am not sure how this applies here, as the mock does not end in -test.js
.
Not sure what is going on with your test support issue, as addon-test-support
seems to be the recommended location to place such files.
Fix released in 2.0.3
. Please reopen in case you are still having issues.
With
ember-stripe-elements@2.0.2
According to the rule from
eslint-plugin-ember
ember/no-test-support-import
The Stripe library mock initializer is not correct, the rule is not fired due to the dynamic import usecase here.The initialization condition has been changed .. The new condition
typeof FastBoot !== 'undefined' || stripeConfig.mock
has not the same behavior from the previoustypeof FastBoot === 'undefined' && stripeConfig.mock
.Probably independently from this, i have created a iban element (like card element) and the test failed because it does not found the StripeMock.
import StripeMock from '@adopted-ember-addons/ember-stripe-elements/test-support';
.Here is the full test :