diff --git a/tests/conftest.py b/tests/conftest.py index 4bdaa4cad..b87de35a5 100644 --- a/tests/conftest.py +++ b/tests/conftest.py @@ -1,5 +1,6 @@ import pytest from unittest.mock import patch, MagicMock +import os @pytest.fixture def mock_token_managers(): @@ -17,4 +18,11 @@ def mock_token_managers(): mock_s2s_inst.get_token.return_value = "mock_s2s_token" mock_s2s.return_value = mock_s2s_inst - yield \ No newline at end of file + yield + +@pytest.fixture(scope="session", autouse=True) +def setup_env_vars(): + """Set up required environment variables for tests""" + os.environ.setdefault("ENVIRONMENT", "sbox") + os.environ.setdefault("LZ_KEY", "01") + os.environ.setdefault("PR_NUMBER", "1234") \ No newline at end of file diff --git a/tests/requirements.txt b/tests/requirements.txt index 20a549c7b..798906386 100644 --- a/tests/requirements.txt +++ b/tests/requirements.txt @@ -9,4 +9,5 @@ azure-eventhub azure-storage-blob aiohttp pyspark -pandas \ No newline at end of file +pandas +azure.functions \ No newline at end of file