Added a test for setting the API key