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
fix(types): add Buffer to WhereValue type #11499
fix(types): add Buffer to WhereValue type #11499
Conversation
Codecov Report
@@ Coverage Diff @@
## master #11499 +/- ##
=======================================
Coverage 96.27% 96.27%
=======================================
Files 94 94
Lines 9185 9185
=======================================
Hits 8843 8843
Misses 342 342 Continue to review full report at Codecov.
|
Can you please add a test for this as well? |
@SimonSchick if you tell me how, more than happy to. |
Hello! I see you are a first-time contributor, thank you for taking the time to help Sequelize! I hope to see more PRs from you in the future! Testing the TypeScript typings consists simply on checking if some code can be compiled. In other words, a typings test is just some TS code that should compile. What it does when executed is irrelevant, the test is simply to compile it without errors, as can be seen in our CI configuration (using For good examples on how to write typescript typings, check the following PRs: #11368 #11379 #11520 Let me know if you need further help! |
@papb right of course, makes sense. I've added a test for all WhereValue literals. I've noticed some linting issues in those typescript files. What do you think of covering them under the existing eslint setup? Happy to put it a PR for it. |
I'd rather use TSLint for that until eslint is fully feature on-par with it, PR is welcome though :) |
TSLint is reaching end of life on Jan 1st and will be officially replaced by ESLint (see palantir/tslint#4534). We've been using the |
I haven't checked on their progress, but that sounds promising feel free to ahead with that. |
5d6b33d
to
cfba292
Compare
@papb quick follow-up - all tests are passing now. |
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.
LGTM
🎉 This PR is included in version 5.19.7 🎉 The release is available on: Your semantic-release bot 📦🚀 |
Pull Request check-list
Please make sure to review and check all of these items:
npm run test
ornpm run test-DIALECT
pass with this change (including linting)?Description of change
where
clauses that contain Buffer values (querying binary fields) fail Typescript validation due to a missing type declaration. Example:This PR adds the missing Buffer type to the
WhereValue
type definition.I ran
npm run test-typings