FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

✅ Refactor test_enums to make them independent of previous imports by tiangolo · Pull Request #1095 · fastapi/sqlmodel · GitHub

Repository navigation

✅ Refactor test_enums to make them independent of previous imports - #1095

Merged
tiangolo merged 1 commit into
mainfrom
test-enums
Aug 31, 2024
Merged

tiangolo merged 1 commit into
mainfrom
test-enums

Conversation

tiangolo commented Aug 31, 2024 •
edited
Loading

Copy link
Copy Markdown
Member

✅ Refactor test_enums to make them independent of previous imports

These tests are currently passing only because they are the first ones to be imported. But adding other tests before them, as in #1093 makes them fail.

With this refactor, because SQLModel and the metadata are cleared in a text fixture, and then the models are imported/reloaded, they are independent of anything else that could be loaded or registered.

tiangolo added the internal Internal changes label Aug 31, 2024
tiangolo marked this pull request as ready for review August 31, 2024 09:33
tiangolo merged commit e4f3ec7 into main Aug 31, 2024
tiangolo deleted the test-enums branch August 31, 2024 09:33
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

internal Internal changes

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant


Back | FazBrowse Home | New Git URL