Skip to content

Commit

Permalink
Don't install and start consul and etcd in tests
Browse files Browse the repository at this point in the history
  • Loading branch information
GeorgianaElena committed Jul 7, 2021
1 parent f9aca81 commit 9e473df
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 4 deletions.
3 changes: 1 addition & 2 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,6 @@ jobs:
# steps as if would used `export MY_ENV=my-value`.
- name: Configure environment variables
run: |
echo "ETCDCTL_API=3" >> $GITHUB_ENV
echo "PATH=$PWD/bin:$PATH" >> $GITHUB_ENV
- uses: actions/checkout@v2
# NOTE: actions/setup-python@v2 make use of a cache within the GitHub base
Expand All @@ -57,7 +56,7 @@ jobs:
run: |
pip install --upgrade setuptools pip
pip install -r dev-requirements.txt --upgrade .
python -m jupyterhub_traefik_proxy.install --traefik --etcd --consul --output=./bin
python -m jupyterhub_traefik_proxy.install --traefik --output=./bin
pip freeze
- name: Run tests
run: |
Expand Down
4 changes: 2 additions & 2 deletions tests/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ def external_toml_proxy():
traefik_process.wait()


@pytest.fixture(scope="session", autouse=True)
@pytest.fixture(scope="session", autouse=False)
def etcd():
etcd_proc = subprocess.Popen("etcd", stdout=None, stderr=None)
yield etcd_proc
Expand All @@ -81,7 +81,7 @@ def etcd():
shutil.rmtree(os.getcwd() + "/default.etcd/")


@pytest.fixture(scope="function", autouse=True)
@pytest.fixture(scope="function", autouse=False)
def clean_etcd():
subprocess.run(["etcdctl", "del", '""', "--from-key=true"])

Expand Down

0 comments on commit 9e473df

Please sign in to comment.