pub async fn constrained_test_pool(connections: u32) -> ConnectionPool<DB> {
        assert!(connections > 0, "Number of connections must be positive");
        let mut builder = TestTemplate::empty()
            .expect("failed creating test template")
            .create_db(connections)
            .await
            .expect("failed creating database for tests");
        let mut pool = builder
            .set_acquire_timeout(Some(Self::TEST_ACQUIRE_TIMEOUT), 0)
            .build()
            .await
            .expect("cannot build connection pool");
        pool.traced_connections = Some(Arc::default());
        pool
    }
Same as [`Self::test_pool()`], but with a configurable number of connections. This is useful to test
behavior of components that rely on singleton / constrained pools in production.
core/lib/db_connection/src/connection_pool.rs