Refactor uuid test

This commit is contained in:
Chris Tsang 2021-09-18 15:47:59 +08:00
parent 558cf5904a
commit 68787d1412
2 changed files with 2 additions and 11 deletions

View File

@ -10,13 +10,7 @@ pub struct Model {
pub bytes: Vec<u8>,
}
#[derive(Copy, Clone, Debug, EnumIter)]
#[derive(Copy, Clone, Debug, EnumIter, DeriveRelation)]
pub enum Relation {}
impl RelationTrait for Relation {
fn def(&self) -> RelationDef {
unreachable!()
}
}
impl ActiveModelBehavior for ActiveModel {}

View File

@ -2,7 +2,6 @@ pub mod common;
pub use common::{bakery_chain::*, setup::*, TestContext};
use sea_orm::{entity::prelude::*, DatabaseConnection, IntoActiveModel};
use uuid::Uuid;
#[sea_orm_macros::test]
#[cfg(any(
@ -11,10 +10,8 @@ use uuid::Uuid;
feature = "sqlx-postgres"
))]
async fn main() -> Result<(), DbErr> {
let ctx = TestContext::new("bakery_chain_schema_primary_key_tests").await;
let ctx = TestContext::new("bakery_chain_schema_uuid_tests").await;
create_metadata(&ctx.db).await?;
ctx.delete().await;
Ok(())