Fixtures¶
cattle_grid.testing.fixtures ¶
actor_with_account
async
¶
actor_with_account(sql_session, account_for_test) -> Actor
Fixture to create an actor with an account
Source code in cattle_grid/testing/fixtures.py
loaded_config ¶
sql_engine_for_tests
async
¶
Provides the sql engine (as in memory sqlite) for tests
This fixture has autouse=True, meaning that by importing
it will run automatically. The engine is initialized in the place cattle_grid expects it.
Source code in cattle_grid/testing/fixtures.py
sql_session
async
¶
Returns an AsyncSession to be used by tests