Skip to content

Commit

Permalink
Remove the check command (#52)
Browse files Browse the repository at this point in the history
  • Loading branch information
scmmmh committed Feb 27, 2024
1 parent 9fccf1b commit 7c1ef37
Show file tree
Hide file tree
Showing 17 changed files with 18 additions and 361 deletions.
4 changes: 4 additions & 0 deletions docs/de/changelog.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# Änderungsgeschichte

## In Entwicklung

* **Entfernt**: Undokumentierten "check" Kommandozeilenbefehl entfernt

## 1.3.2 (26.02.2024)

* **Bugfix**: Weiteren Fehler in der Sortierung nach Seitenzahlen behoben
Expand Down
4 changes: 4 additions & 0 deletions docs/en/changelog.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# Changelog

## In Development

* **Removed**: Removed undocumented "check" command

## 1.3.2 (26.02.2024)

* **Bugfix**: Further bugfix in the sorting by page functionality
Expand Down
60 changes: 0 additions & 60 deletions tests/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -82,66 +82,6 @@ def multilang_app() -> Generator[Typer, None, None]:
os.chdir(cwd)


@fixture
def missing_core_files_app() -> Generator[Typer, None, None]:
"""Yield a basic application where the core _config.yml and _toc.yml files are missing."""
cwd = os.getcwd()
try:
os.chdir("tests/fixtures/missing_core_files")
from uedition.cli import app
from uedition.settings import reload_settings

reload_settings()
yield app
finally:
os.chdir(cwd)


@fixture
def invalid_core_files_app() -> Generator[Typer, None, None]:
"""Yield a basic application where the core _config.yml and _toc.yml files are invalid YAML."""
cwd = os.getcwd()
try:
os.chdir("tests/fixtures/invalid_core_files")
from uedition.cli import app
from uedition.settings import reload_settings

reload_settings()
yield app
finally:
os.chdir(cwd)


@fixture
def missing_toc_root_app() -> Generator[Typer, None, None]:
"""Yield a basic application where the _toc.yml file is missing the root entry."""
cwd = os.getcwd()
try:
os.chdir("tests/fixtures/missing_toc_root")
from uedition.cli import app
from uedition.settings import reload_settings

reload_settings()
yield app
finally:
os.chdir(cwd)


@fixture
def missing_toc_root_file_app() -> Generator[Typer, None, None]:
"""Yield a basic application where the _toc.yml file points to a missing root file."""
cwd = os.getcwd()
try:
os.chdir("tests/fixtures/missing_toc_root_file")
from uedition.cli import app
from uedition.settings import reload_settings

reload_settings()
yield app
finally:
os.chdir(cwd)


@fixture
def missing_files_app() -> Generator[Typer, None, None]:
"""Yield a basic application where some files are missing root file."""
Expand Down
3 changes: 0 additions & 3 deletions tests/fixtures/invalid_core_files/en/_config.yml

This file was deleted.

3 changes: 0 additions & 3 deletions tests/fixtures/invalid_core_files/en/_toc.yml

This file was deleted.

9 changes: 0 additions & 9 deletions tests/fixtures/invalid_core_files/uEdition.yaml

This file was deleted.

9 changes: 0 additions & 9 deletions tests/fixtures/missing_core_files/uEdition.yaml

This file was deleted.

3 changes: 0 additions & 3 deletions tests/fixtures/missing_toc_root/en/_config.yml

This file was deleted.

4 changes: 0 additions & 4 deletions tests/fixtures/missing_toc_root/en/_toc.yml

This file was deleted.

9 changes: 0 additions & 9 deletions tests/fixtures/missing_toc_root/uEdition.yaml

This file was deleted.

3 changes: 0 additions & 3 deletions tests/fixtures/missing_toc_root_file/en/_config.yml

This file was deleted.

5 changes: 0 additions & 5 deletions tests/fixtures/missing_toc_root_file/en/_toc.yml

This file was deleted.

9 changes: 0 additions & 9 deletions tests/fixtures/missing_toc_root_file/uEdition.yaml

This file was deleted.

54 changes: 0 additions & 54 deletions tests/test_check.py

This file was deleted.

10 changes: 10 additions & 0 deletions tests/test_settings.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
"""Tests for the 'build' functionality."""

from typer import Typer
from typer.testing import CliRunner


def test_yaml_load(runner: CliRunner, yaml_app: Typer) -> None:
"""Test that the basic build works."""
result = runner.invoke(yaml_app, ["build"])
assert result.exit_code == 0
7 changes: 0 additions & 7 deletions uedition/cli/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@

from uedition.__about__ import __version__
from uedition.cli import build as build_module
from uedition.cli import check as check_module
from uedition.cli import create as create_module
from uedition.cli import language as language_module
from uedition.cli import serve as serve_module
Expand Down Expand Up @@ -37,12 +36,6 @@ def serve() -> None:
serve_module.run()


@app.command()
def check() -> None:
"""Check that the μEdition is set up correctly."""
check_module.run()


@app.command()
def update() -> None:
"""Update the μEdition."""
Expand Down
Loading

0 comments on commit 7c1ef37

Please sign in to comment.