From 7267528f0e12a3463151b03bc7036ae4aa9c2f19 Mon Sep 17 00:00:00 2001 From: Javier de la Puente Date: Wed, 23 Oct 2024 10:16:13 +0200 Subject: [PATCH] Do not run pytest tests in tests/spread --- pyproject.toml | 1 + .../spread/commands/init-extensions/tests/unit/test_charm.py | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index 821beff30..faeac2724 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -132,6 +132,7 @@ xfail_strict = true markers = [ "slow: marks tests as slow (deselect with '-m \"not slow\"')", ] +addopts = "--ignore=tests/spread" [tool.coverage.run] branch = true diff --git a/tests/spread/commands/init-extensions/tests/unit/test_charm.py b/tests/spread/commands/init-extensions/tests/unit/test_charm.py index fb857bb5c..6c9c39de0 100644 --- a/tests/spread/commands/init-extensions/tests/unit/test_charm.py +++ b/tests/spread/commands/init-extensions/tests/unit/test_charm.py @@ -1,7 +1,7 @@ # Copyright 2024 Canonical Ltd. # See LICENSE file for licensing details. -"""Smoke scenario test for Flask.""" +"""Smoke scenario test for paas-charm based init templates.""" import os import pathlib @@ -12,7 +12,7 @@ def test_smoke(): - """The only goal of this test is a smoke test, that is, that the charm does not raise.""" + """The purpose of this test is that the charm does not raise on a handled event.""" os.chdir(pathlib.Path(charm.__file__).parent.parent) ctx = scenario.Context(charm.HelloWorldCharm) container_name = next(iter(ctx.charm_spec.meta["containers"].keys()))