-
-
Notifications
You must be signed in to change notification settings - Fork 519
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
Test cases improvement #1811
Test cases improvement #1811
Conversation
As discussed, the most needed test cases are for:
And we needed both unit testing e.g. https://github.com/SeaQL/sea-orm/blob/master/src/executor/paginator.rs#L299 https://github.com/SeaQL/sea-orm/blob/master/src/executor/cursor.rs#L308 and integration testing (which you are doing) to test the behaviour of |
} | ||
|
||
#[smol_potat::test] | ||
pub async fn with_related() -> Result<(), sea_orm::DbErr> { |
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.
Add 1 more case: Cake -> Filling
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.
I see new test cases for Cake -> Vendor but not Cake -> Filling?
cake_fruit_model(1, 1).into_mock_row(), | ||
cake_fruit_model(2, 1).into_mock_row(), |
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.
It can't duplicate right? This should be for Filling?
.into_connection(); | ||
|
||
assert_eq!( | ||
Cake::find().find_with_related(Fruit).all(&db).await?, |
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.
Same here, may be change this to Filling
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.
I will make the changes.
🎉 Released In 0.12.3 🎉Thank you everyone for the contribution! |
PR Info
New Features
Bug Fixes
Breaking Changes
Changes