OPM / opm-reference-manual

Other
1 stars 5 forks source link

Revert "Also run github action tests for docker directory" #423

Closed lisajulia closed 2 weeks ago

lisajulia commented 2 weeks ago

Reverts OPM/opm-reference-manual#276

lisajulia commented 2 weeks ago

Here, the github action fails with:

Run cd docker
  cd docker
  poetry run pytest tests
  shell: /bin/bash -e {0}
  env:
    pythonLocation: /Users/runner/hostedtoolcache/Python/3.11.9/arm64
    PKG_CONFIG_PATH: /Users/runner/hostedtoolcache/Python/3.11.9/arm64/lib/pkgconfig
    Python_ROOT_DIR: /Users/runner/hostedtoolcache/Python/3.11.9/arm64
    Python2_ROOT_DIR: /Users/runner/hostedtoolcache/Python/3.11.9/arm64
    Python3_ROOT_DIR: /Users/runner/hostedtoolcache/Python/3.11.9/arm64
============================= test session starts ==============================
platform darwin -- Python 3.11.9, pytest-8.0.0, pluggy-1.4.0
rootdir: /Users/runner/work/opm-reference-manual/opm-reference-manual/docker
plugins: mock-3.12.0
collected 12 items

tests/test_find_git_root.py F                                            [  8%]
tests/test_user_input.py ...........                                     [100%]

=================================== FAILURES ===================================
_____________________________ test_git_root_exists _____________________________

tmp_path = PosixPath('/private/var/folders/1y/56hdyx6x0_jb18k7b4ys9b6w0000gn/T/pytest-of-runner/pytest-1/test_git_root_exists0')

    def test_git_root_exists(tmp_path: Path):
        # Create a dummy git repository in the tmp_path directory
        git_dir = tmp_path / ".git"
        git_dir.mkdir()
        # Create a folders and a file: "docker/.venv/lib/python3.12/site-packages/lodocker/run_container.py"
        docker_dir = tmp_path / "docker/.venv/lib/python3.12/site-packages/lodocker"
        docker_dir.mkdir(parents=True)
        run_container = docker_dir / "run_container.py"
        run_container.touch()
        # Create a parts directory
        parts_dir = tmp_path / "parts"
        parts_dir.mkdir()
        # Create a main.fodt file
        main_fodt = parts_dir / "main.fodt"
        main_fodt.touch()
>       found_root = Helpers.locate_git_root_from_file(str(run_container))
E       AttributeError: type object 'Helpers' has no attribute 'locate_git_root_from_file'

tests/test_find_git_root.py:19: AttributeError
=========================== short test summary info ============================
FAILED tests/test_find_git_root.py::test_git_root_exists - AttributeError: type object 'Helpers' has no attribute 'locate_git_root_from_file'
========================= 1 failed, 11 passed in 0.06s =========================
Error: Process completed with exit code 1.