From af38c467173bcea52e08a4083723e6e6832e0308 Mon Sep 17 00:00:00 2001 From: Lev Vereshchagin Date: Sun, 1 May 2022 16:41:50 +0300 Subject: [PATCH] Fix builds failing Fixes #792 --- tests/conftest.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/tests/conftest.py b/tests/conftest.py index 030e79f9..df0e9969 100644 --- a/tests/conftest.py +++ b/tests/conftest.py @@ -1,6 +1,7 @@ import os import shutil import subprocess +from contextlib import suppress from dataclasses import dataclass from pathlib import Path @@ -42,7 +43,11 @@ def compose(env_file: str): @pytest.fixture(autouse=True, scope="session") def frappe_setup(compose: Compose): - compose.stop() + # Stop all containers in `test` project if they are running. + # We don't care if it fails. + with suppress(subprocess.CalledProcessError): + compose.stop() + compose("up", "-d", "--quiet-pull") yield compose.stop()