Skip to content
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

meta: add tests to verify that showConstraints filters on schema #16785

Merged

Conversation

ghusse
Copy link
Contributor

@ghusse ghusse commented Nov 20, 2023

Pull Request Checklist

  • Have you added new tests to prevent regressions?
  • If a documentation update is necessary, have you opened a PR to the documentation repository?
  • Did you update the typescript typings accordingly (if applicable)?
  • Does the description below contain a link to an existing issue (Closes #[issue]) or a description of the issue you are solving?
  • Does the name of your PR follow our conventions?

Description Of Change

This PR is linked to #16770 on v6.

On v6, the equivalent function to retrieve constraints on a table did not correctly filter on schema name. I added tests on v7 to ensure filtering is correctly done also on schema name.

It seems to be the case, so we don't need to port the fix on v7. But maybe these tests would be useful to avoid future regressions on this subject.

@ghusse ghusse changed the title add tests to verify that showConstraints filters on schema meta: add tests to verify that showConstraints filters on schema Nov 20, 2023
@WikiRik
Copy link
Member

WikiRik commented Nov 23, 2023

Don't we also test for this in the unit tests for showConstraintQuery?

@ghusse
Copy link
Contributor Author

ghusse commented Nov 24, 2023

I'm not sure that we can rely on unit tests on this, because all it tests is that the query has a certain form. But it does not test the final behavior.

I just added the tests that show that the functionality is working as intended (which is not the case in v6), see #16770

@WikiRik WikiRik added this pull request to the merge queue Dec 6, 2023
Merged via the queue into sequelize:main with commit 1422e60 Dec 6, 2023
50 of 51 checks passed
papandreou added a commit to papandreou/sequelize that referenced this pull request Dec 19, 2023
v7.0.0-alpha.34

* tag 'v7.0.0-alpha.34': (94 commits)
  v7.0.0-alpha.34
  feat!: rename association classes to prevent conflicts with decorators (sequelize#16513)
  meta: add unit test for ARRAY(UUID) (sequelize#16841)
  fix: correct link to data types docs (sequelize#16674)
  feat: add support for `sql` tag & functions in `sequelize.query` (sequelize#16863)
  feat: add an option to control the behavior of `null` in JSON attributes (sequelize#16861)
  meta: update dependency nx to v17.2.1 (sequelize#16862)
  meta: update sequelize AUTHORS (sequelize#16856)
  meta: lock file maintenance (sequelize#16859)
  meta: update dependency typedoc-plugin-mdn-links to v3.1.7 (sequelize#16857)
  meta: update dependency markdownlint-cli to v0.38.0 (sequelize#16854)
  meta: update dependency nx to v17.2.0 (sequelize#16853)
  meta: update dependency ts-node to v10.9.2 (sequelize#16852)
  meta: update dependency @types/snowflake-sdk to v1.6.20 (sequelize#16850)
  meta: update dependency @types/snowflake-sdk to v1.6.19 (sequelize#16849)
  meta: update actions/stale action to v9 (sequelize#16847)
  meta: update dependency snowflake-sdk to v1.9.2 (sequelize#16846)
  meta: update dependency @types/node to v20.10.4 (sequelize#16845)
  meta: add tests to verify that showConstraints filters on schema (sequelize#16785)
  meta: update sequelize AUTHORS (sequelize#16781)
  ...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants