-
-
Notifications
You must be signed in to change notification settings - Fork 4.3k
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): update BelongsToManyGetAssociationsMixinOptions definition #11818
fix(types): update BelongsToManyGetAssociationsMixinOptions definition #11818
Conversation
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! |
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.
Please add at least one test to make sure your implementation works as intended and to prevent regressions 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 npm run test-typings
) here and here. Since it's just a compilation, getting no output from it means that it passed. Getting a compilation error is a failure. Note that if you directly throw an error from your typings test code, the test will still pass because throwing an error is something that compiles just fine.
For good examples on how to write typescript typings, check the following PRs: #11368 #11378 #11520
Let me know if you need further help!
Codecov Report
@@ Coverage Diff @@
## master #11818 +/- ##
=======================================
Coverage 96.26% 96.26%
=======================================
Files 94 94
Lines 9191 9191
=======================================
Hits 8848 8848
Misses 343 343 Continue to review full report at Codecov.
|
…ion' of github.com:thrymgjol/sequelize into update-BelongsToManyGetAssociationsMixinOptions-definition
Thank you!! |
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
This will add the
joinTableAttributes
property to theBelongsToManyGetAssociationsMixinOptions
interface.belongs-to-many.d.ts
defines an interface namedJoinTableAttributes
:However, this does not seem to be the appropriate type for this property. In
belongs-to-many.js
,joinTableAttributes
is assigned to theattributes
property of a set ofinclude
options, so I used the same type as theattributes
property fromIncludeOptions
(FindAttributeOptions
).