diff --git a/pkgs/clan-cli/tests/test_flake_api.py b/pkgs/clan-cli/tests/test_flake_api.py index 8eafa2c9..7bca5fbc 100644 --- a/pkgs/clan-cli/tests/test_flake_api.py +++ b/pkgs/clan-cli/tests/test_flake_api.py @@ -4,48 +4,10 @@ import logging import pytest from api import TestClient from fixtures_flakes import FlakeForTest -from path import Path - -from clan_cli.dirs import user_history_file log = logging.getLogger(__name__) -def test_flake_history_append( - api: TestClient, test_flake: FlakeForTest, temporary_home: Path -) -> None: - response = api.post( - f"/api/flake/history?flake_dir={test_flake.path!s}", - json={}, - ) - assert response.status_code == 200, response.json() - assert user_history_file().exists() - - -# def test_flake_history_list( -# api: TestClient, test_flake: FlakeForTest, temporary_home: Path -# ) -> None: -# response = api.get( -# "/api/flake/history", -# ) -# assert response.status_code == 200, response.text -# assert response.json() == [] - -# # add the test_flake -# response = api.post( -# f"/api/flake/history?flake_dir={test_flake.path!s}", -# json={}, -# ) -# assert response.status_code == 200, response.text - -# # list the flakes again -# response = api.get( -# "/api/flake/history", -# ) -# assert response.status_code == 200, response.text -# assert response.json() == [str(test_flake.path)] - - @pytest.mark.impure def test_inspect_ok(api: TestClient, test_flake_with_core: FlakeForTest) -> None: params = {"url": str(test_flake_with_core.path)} diff --git a/pkgs/clan-cli/tests/test_flakes_cli.py b/pkgs/clan-cli/tests/test_flakes_cli.py index bbaf23bd..e6138c05 100644 --- a/pkgs/clan-cli/tests/test_flakes_cli.py +++ b/pkgs/clan-cli/tests/test_flakes_cli.py @@ -1,15 +1,13 @@ -import json from typing import TYPE_CHECKING import pytest from cli import Cli from fixtures_flakes import FlakeForTest -from pytest import CaptureFixture - if TYPE_CHECKING: pass + @pytest.mark.impure def test_flakes_inspect( test_flake_with_core: FlakeForTest, capsys: pytest.CaptureFixture diff --git a/pkgs/clan-cli/tests/test_history_cli.py b/pkgs/clan-cli/tests/test_history_cli.py index 73816000..ed793084 100644 --- a/pkgs/clan-cli/tests/test_history_cli.py +++ b/pkgs/clan-cli/tests/test_history_cli.py @@ -1,7 +1,6 @@ import json from typing import TYPE_CHECKING -import pytest from cli import Cli from fixtures_flakes import FlakeForTest from pytest import CaptureFixture @@ -47,5 +46,3 @@ def test_history_list( cli.run(["history", "add", str(test_flake.path)]) cli.run(cmd) assert str(test_flake.path) in capsys.readouterr().out - -