diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 7589a9e..84354af 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -22,7 +22,7 @@ jobs: pip install -r requirements.txt - name: Test with unittest run: | - python -m unittest src/test_core.py + python -m unittest techdocs_core/test_core.py - name: Uninstall dependencies run: | pip list --format=freeze | xargs pip uninstall -y diff --git a/README.md b/README.md index a64588f..6de3875 100644 --- a/README.md +++ b/README.md @@ -149,6 +149,10 @@ We only use `material-mkdocs` as base styles because Backstage also uses the `Ma ## Changelog +### 1.5.0 + - Renamed package namespace from `src` to `techdocs_core` + - Fix small deprecation in tests (`assertEquals` -> `assertEqual`) as it was deprecated since Python 3.2 and removed in 3.12 + ### 1.4.2 - Fixes an issue where individual extension configurations were being ignored if the extension was included within `pymdownx.extra`. See [#147](https://github.com/backstage/mkdocs-techdocs-core/issues/147) diff --git a/setup.py b/setup.py index 1c5821e..90e6659 100644 --- a/setup.py +++ b/setup.py @@ -28,7 +28,7 @@ setup( name="mkdocs-techdocs-core", - version="1.4.2", + version="1.5.0", description="The core MkDocs plugin used by Backstage's TechDocs as a wrapper around " "multiple MkDocs plugins and Python Markdown extensions", long_description=long_description, @@ -50,5 +50,5 @@ "Programming Language :: Python :: 3.8", ], packages=find_packages(), - entry_points={"mkdocs.plugins": ["techdocs-core = src.core:TechDocsCore"]}, + entry_points={"mkdocs.plugins": ["techdocs-core = techdocs_core.core:TechDocsCore"]}, ) diff --git a/src/__init__.py b/techdocs_core/__init__.py similarity index 100% rename from src/__init__.py rename to techdocs_core/__init__.py diff --git a/src/core.py b/techdocs_core/core.py similarity index 100% rename from src/core.py rename to techdocs_core/core.py diff --git a/src/test_core.py b/techdocs_core/test_core.py similarity index 97% rename from src/test_core.py rename to techdocs_core/test_core.py index 98c7d7c..3fd0b4c 100644 --- a/src/test_core.py +++ b/techdocs_core/test_core.py @@ -88,7 +88,7 @@ def test_theme_overrides_dirs(self): def test_template_renders__multiline_value_as_valid_json(self): self.techdocscore.on_config(self.mkdocs_yaml_config) env = Environment( - loader=PackageLoader("test", self.techdocscore.tmp_dir_techdocs_theme.name), + loader=PackageLoader("techdocs_core", self.techdocscore.tmp_dir_techdocs_theme.name), autoescape=select_autoescape(), ) template = env.get_template("techdocs_metadata.json") @@ -98,7 +98,7 @@ def test_template_renders__multiline_value_as_valid_json(self): } rendered = template.render(config=config) as_json = json.loads(rendered) - self.assertEquals(config, as_json) + self.assertEqual(config, as_json) def test_restrict_snippet_base_path(self): self.mkdocs_yaml_config["mdx_configs"] = {