-
Notifications
You must be signed in to change notification settings - Fork 74
chore(cli): lint test files #441
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
Conversation
| 'aws-sdk-client-mock', | ||
| 'aws-sdk-client-mock-jest', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These were missing dev deps that eslint discovered.
|
|
||
| test('require approval by default - respond no', async () => { | ||
| expect(() => requestResponse('n', plainMessage({ | ||
| await expect(() => requestResponse('n', plainMessage({ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this was missing before, all promises must be awaited
| deployments: new FakeCloudFormation({}), | ||
| }); | ||
| stderrMock.mockImplementation((...x) => { | ||
| // eslint-disable-next-line no-console |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
allow in this case
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #441 +/- ##
=======================================
Coverage 79.15% 79.15%
=======================================
Files 54 54
Lines 6889 6889
Branches 773 772 -1
=======================================
Hits 5453 5453
Misses 1418 1418
Partials 18 18
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
These were previously ignored, presumingly because they did not follow most of our linting rules. However now a lot less tests are in the CLI package (most moved to toolkit-lib) so we can safely re-enable linting of test files.
Added
'@typescript-eslint/unbound-method': 'off'for test files, since there were many violations of this and it doesn't seem necessary to enforce this rule in test code.Most test code changes are automated. I've annotated the few manual fixes I made.
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license