From 19b633ed7b35c1834a2d1c59816c4fe7479607db Mon Sep 17 00:00:00 2001 From: Dima Tisnek Date: Mon, 9 Feb 2026 16:37:46 +0900 Subject: [PATCH] chore: clean up ops-testing project file --- .claude/subagents/test-runner.md | 2 +- testing/pyproject.toml | 41 ++++++++----------- .../{scenario => ops_scenario}/__init__.py | 0 .../_consistency_checker.py | 0 .../_ops_main_mock.py | 0 .../{scenario => ops_scenario}/_runtime.py | 0 .../src/{scenario => ops_scenario}/context.py | 0 .../src/{scenario => ops_scenario}/errors.py | 0 .../src/{scenario => ops_scenario}/logger.py | 0 .../src/{scenario => ops_scenario}/mocking.py | 0 .../src/{scenario => ops_scenario}/py.typed | 0 .../src/{scenario => ops_scenario}/state.py | 0 tox.ini | 2 +- 13 files changed, 20 insertions(+), 25 deletions(-) rename testing/src/{scenario => ops_scenario}/__init__.py (100%) rename testing/src/{scenario => ops_scenario}/_consistency_checker.py (100%) rename testing/src/{scenario => ops_scenario}/_ops_main_mock.py (100%) rename testing/src/{scenario => ops_scenario}/_runtime.py (100%) rename testing/src/{scenario => ops_scenario}/context.py (100%) rename testing/src/{scenario => ops_scenario}/errors.py (100%) rename testing/src/{scenario => ops_scenario}/logger.py (100%) rename testing/src/{scenario => ops_scenario}/mocking.py (100%) rename testing/src/{scenario => ops_scenario}/py.typed (100%) rename testing/src/{scenario => ops_scenario}/state.py (100%) diff --git a/.claude/subagents/test-runner.md b/.claude/subagents/test-runner.md index 28b7111c9..0571e45ba 100644 --- a/.claude/subagents/test-runner.md +++ b/.claude/subagents/test-runner.md @@ -44,5 +44,5 @@ tox -e lint # Type checking and linting - `test/` - Unit tests mirroring source structure - `test/conftest.py` - Pytest configuration - `test/charms/` - Test charm implementations -- `testing/src/scenario/` - Testing framework source +- `testing/src/ops_scenario/` - Testing framework source - `tox.ini` - Test environment configuration diff --git a/testing/pyproject.toml b/testing/pyproject.toml index 1e7b210df..0dc020825 100644 --- a/testing/pyproject.toml +++ b/testing/pyproject.toml @@ -1,44 +1,39 @@ -[build-system] -requires = [ - "setuptools >= 35.0.2", -] -build-backend = "setuptools.build_meta" - [project] name = "ops-scenario" - version = "8.6.0.dev0" - +description = "Python library providing a state-transition testing API for Operator Framework charms." +requires-python = ">=3.10" +readme = "README.md" +license = "Apache-2.0" authors = [ { name = "Pietro Pasotti", email = "pietro.pasotti@canonical.com" } ] maintainers = [ { name = "The Charm Tech team at Canonical Ltd." } ] -description = "Python library providing a state-transition testing API for Operator Framework charms." -license = "Apache-2.0" keywords = ["juju", "test"] - -dependencies = [ - "ops==3.6.0.dev0", - "PyYAML>=6.0.1", - "typing_extensions>=4.9.0", # for `deprecated` decorator, replace with stdlib `warnings.deprecated` when we're Python 3.13+ -] -readme = "README.md" -requires-python = ">=3.10" - classifiers = [ "Development Status :: 5 - Production/Stable", 'Framework :: Pytest', 'Intended Audience :: Developers', + "Programming Language :: Python", + "Programming Language :: Python :: 3", 'Topic :: Software Development :: Quality Assurance', 'Topic :: Software Development :: Testing', 'Topic :: Utilities', ] +dependencies = [ + "ops==3.6.0.dev0", + "PyYAML>=6.0.1", + "typing_extensions>=4.9.0", # for `deprecated` decorator, replace with stdlib `warnings.deprecated` when we're Python 3.13+ +] [project.urls] -"Homepage" = "https://github.com/canonical/operator" -"Bug Tracker" = "https://github.com/canonical/operator/issues" +"Repository" = "https://github.com/canonical/operator" +"Issues" = "https://github.com/canonical/operator/issues" +"Documentation" = "https://documentation.ubuntu.com/ops/latest/" +"Changelog" = "https://github.com/canonical/operator/blob/main/CHANGES.md" -[bdist_wheel] -universal = 1 +[build-system] +requires = ["uv_build"] +build-backend = "uv_build" diff --git a/testing/src/scenario/__init__.py b/testing/src/ops_scenario/__init__.py similarity index 100% rename from testing/src/scenario/__init__.py rename to testing/src/ops_scenario/__init__.py diff --git a/testing/src/scenario/_consistency_checker.py b/testing/src/ops_scenario/_consistency_checker.py similarity index 100% rename from testing/src/scenario/_consistency_checker.py rename to testing/src/ops_scenario/_consistency_checker.py diff --git a/testing/src/scenario/_ops_main_mock.py b/testing/src/ops_scenario/_ops_main_mock.py similarity index 100% rename from testing/src/scenario/_ops_main_mock.py rename to testing/src/ops_scenario/_ops_main_mock.py diff --git a/testing/src/scenario/_runtime.py b/testing/src/ops_scenario/_runtime.py similarity index 100% rename from testing/src/scenario/_runtime.py rename to testing/src/ops_scenario/_runtime.py diff --git a/testing/src/scenario/context.py b/testing/src/ops_scenario/context.py similarity index 100% rename from testing/src/scenario/context.py rename to testing/src/ops_scenario/context.py diff --git a/testing/src/scenario/errors.py b/testing/src/ops_scenario/errors.py similarity index 100% rename from testing/src/scenario/errors.py rename to testing/src/ops_scenario/errors.py diff --git a/testing/src/scenario/logger.py b/testing/src/ops_scenario/logger.py similarity index 100% rename from testing/src/scenario/logger.py rename to testing/src/ops_scenario/logger.py diff --git a/testing/src/scenario/mocking.py b/testing/src/ops_scenario/mocking.py similarity index 100% rename from testing/src/scenario/mocking.py rename to testing/src/ops_scenario/mocking.py diff --git a/testing/src/scenario/py.typed b/testing/src/ops_scenario/py.typed similarity index 100% rename from testing/src/scenario/py.typed rename to testing/src/ops_scenario/py.typed diff --git a/testing/src/scenario/state.py b/testing/src/ops_scenario/state.py similarity index 100% rename from testing/src/scenario/state.py rename to testing/src/ops_scenario/state.py diff --git a/tox.ini b/tox.ini index 0d808bf1f..dc309ad4c 100644 --- a/tox.ini +++ b/tox.ini @@ -23,7 +23,7 @@ envlist = lint, unit src_path = ops/ tst_path = test/ all_path = {[vars]src_path} {[vars]tst_path} -testing_src_path = testing/src/scenario/ +testing_src_path = testing/src/ops_scenario/ testing_tst_path = testing/tests/ tracing_tst_path = tracing/test/ examples_path = examples/