How to pass API key for a new pytest?

Hey, I wanted to ask how we should set the API keys for the Pytest. Should we mock the client, or configure them as environment variables in the CI for the tests to work?