1
0
mirror of https://github.com/actix/examples synced 2025-06-28 01:49:02 +02:00

fix(tests): ignore tests if postgres isn't up

This commit is contained in:
Alex Ted
2025-02-28 12:17:26 +03:00
parent c8da70bb0a
commit 9a25c3b233
2 changed files with 5 additions and 1 deletions

View File

@ -106,7 +106,8 @@ async fn initialize_db_pool() -> DbPool {
Pool::builder().build(connection_manager).await.unwrap()
}
#[cfg(test)]
#[cfg(not(feature = "postgres_tests"))]
#[allow(unused_imports)]
mod tests {
use actix_web::{http::StatusCode, test};
use diesel::prelude::*;