MCPcopy Create free account
hub / github.com/SeaQL/sea-orm / test_query_err

Function test_query_err

src/database/mock.rs:860–869  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

858
859 #[smol_potat::test]
860 async fn test_query_err() {
861 let db = MockDatabase::new(DbBackend::MySql)
862 .append_query_errors([query_err("this is a mock query error")])
863 .into_connection();
864
865 assert_eq!(
866 cake::Entity::find().all(&db).await,
867 Err(query_err("this is a mock query error"))
868 );
869 }
870
871 #[smol_potat::test]
872 async fn test_exec_err() {

Callers

nothing calls this directly

Calls 4

query_errFunction · 0.85
into_connectionMethod · 0.80
append_query_errorsMethod · 0.80
newFunction · 0.50

Tested by

no test coverage detected