[][src]Module test_utils::rocket_support

This module includes several functions to help you test your code that uses Rocket. It assumes you have defined a ROCKET_TEST_DATABASE_URL environment variable (can be in a .env file if you have enabled the dotenv feature).

Functions

clean_db
init_pool
init_rocket
init_rocket_and_clean_tables
rocket_connection_without_transaction

Returns a connection to the database (specified through the ROCKET_TEST_DATABASE_URL) environment variable. The connection will directly hit the database as it is not wrapped in a transaction.

Type Definitions

PgPool