typescript-eslint / typescript-eslint/ts-api-utils
🧪 Tests: Add tests for remaining functions in src/flags.ts
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 122
- Forks
- 17
- PR merge metrics
- No merged PRs in 30d
Description
Bug Report Checklist
- I have tried restarting my IDE and the issue persists.
- I have pulled the latest
mainbranch of the repository. - I have searched for related issues and found none that matched my issue.
Overview
#6 added a first round of unit tests. Let's add some more tests! 🙌
The src/flags.ts file is not yet tested. This issue tracks adding in tests for its exported functions.
Additional Info
See #6 for examples of tests: including those that work with AST nodes and/or type checking.
There might be existing tests in https://github.com/ajafff/tsutils that are relevant here. If you do find them, it's fine to copy & paste them over - as long as there's a comment like this above any area of copy & pasted code (or on top of a file if the entire file is copy & pasted):
// Code largely based on https://github.com/ajafff/tsutils
// Original license: https://github.com/ajafff/tsutils/blob/26b195358ec36d59f00333115aa3ffd9611ca78b/LICENSE
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the exported functions in src/flags.ts, then read the tests added in #6 for patterns involving AST nodes and type checking. Review relevant tests in tsutils if useful, preserving the requested attribution for copied code. Done means the remaining exported functions have focused unit-test coverage for their relevant cases.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- compilers, testing
- Issue type
- Feature
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 48/100