add regression test

This commit is contained in:
Joey de Waal 2024-10-01 22:21:48 +02:00 committed by Austin Bonander
parent e62bbd7ee9
commit 81298b86b3

View file

@ -186,3 +186,16 @@ async fn it_gets_comments(pool: PgPool) -> sqlx::Result<()> {
async fn this_should_compile(_pool: PgPool) -> sqlx::Result<()> {
Ok(())
}
macro_rules! macro_using_test {
($migrations: literal) => {
#[sqlx::test(
migrations = $migrations,
fixtures(path = "../fixtures/postgres", scripts("users", "posts"))
)]
async fn macro_using_macro(_pool: PgPool) -> sqlx::Result<()> {
Ok(())
}
};
}
macro_using_test!("tests/postgres/migrations");