diff --git a/.github/workflows/main.yaml b/.github/workflows/main.yaml index 3f260fa..505ff03 100644 --- a/.github/workflows/main.yaml +++ b/.github/workflows/main.yaml @@ -1,6 +1,9 @@ name: Check and test -on: [push, pull_request] +on: + push: + branches: [main] + pull_request: env: FORCE_COLOR: 1 @@ -15,13 +18,11 @@ jobs: - "3.13" # latest include: - python-version: "3.10" - os: windows-2022 + os: windows-latest - python-version: "3.10" os: macos-12 runs-on: ${{ matrix.os }} - # Fails because of https://github.com/beetbox/mediafile/pull/75 - continue-on-error: ${{ matrix.python-version == '3.13' }} steps: - uses: actions/checkout@v4 @@ -36,6 +37,8 @@ jobs: - run: poetry run ruff format --check - run: poetry run ruff check - run: poetry run pyright --warnings + - run: sudo apt-get install -y imagemagick + if: runner.os == 'Linux' - run: poetry run pytest - run: poetry run coverage xml - uses: coverallsapp/github-action@v2 @@ -55,6 +58,7 @@ jobs: - "git+https://github.com/beetbox/beets#master" - "beets==1.6.1" + continue-on-error: ${{ contains(matrix.beets, 'master') }} steps: - uses: actions/checkout@v4 - run: pip install poetry @@ -62,8 +66,9 @@ jobs: with: python-version: "3.10" cache: poetry - - run: poetry env use $(which python) + - run: poetry env use "$(which python)" - run: poetry install - run: poetry add ${{ matrix.beets }} - run: poetry run pyright --warnings + - run: sudo apt-get install -y imagemagick - run: poetry run pytest diff --git a/poetry.lock b/poetry.lock index 0b06b0b..3c26bb6 100644 --- a/poetry.lock +++ b/poetry.lock @@ -1,4 +1,4 @@ -# This file is automatically @generated by Poetry 1.8.4 and should not be changed by hand. +# This file is automatically @generated by Poetry 1.8.5 and should not be changed by hand. [[package]] name = "beets" @@ -225,14 +225,6 @@ files = [ {file = "jellyfish-1.1.0-cp312-cp312-musllinux_1_1_x86_64.whl", hash = "sha256:2fcaefebe9d67f282d89d3a66646b77184a42b3eca2771636789b2dc1288c003"}, {file = "jellyfish-1.1.0-cp312-none-win32.whl", hash = "sha256:e512c99941a257541ffd9f75c7a5c4689de0206841b72f1eb015599d17fed2c3"}, {file = "jellyfish-1.1.0-cp312-none-win_amd64.whl", hash = "sha256:2b928bad2887c662783a4d9b5828ed1fa0e943f680589f7fc002c456fc02e184"}, - {file = "jellyfish-1.1.0-cp313-cp313-macosx_10_12_x86_64.whl", hash = "sha256:5d510b04e2a39f27aef391ca18bf527ec5d9a2438a63731b87faada83996cb92"}, - {file = "jellyfish-1.1.0-cp313-cp313-macosx_11_0_arm64.whl", hash = "sha256:57d005cc5daa4d0a8d88341d86b1dce24e3f1d7721da75326c0b7af598a4f58c"}, - {file = "jellyfish-1.1.0-cp313-cp313-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:889edab0fb2a29d29c148c9327752df525c9bdaef03eef01d1bd9c1f90b47ebf"}, - {file = "jellyfish-1.1.0-cp313-cp313-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:937b657aacba8fe8482ebc5fea5ba1aee987ecb9da0f037bfb8a1a9045d05746"}, - {file = "jellyfish-1.1.0-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:3cb5088436ce1fdabcb46aed3a3cc215f0432313596f4e5abe5300ed833b697c"}, - {file = "jellyfish-1.1.0-cp313-cp313-musllinux_1_1_aarch64.whl", hash = "sha256:af74156301a0ff05a22e8cf46250678e23fa447279ba6dffbf9feff01128f51d"}, - {file = "jellyfish-1.1.0-cp313-cp313-musllinux_1_1_i686.whl", hash = "sha256:3f978bc430bbed4df3c10b2a66be7b5bddd09e6c2856c7a17fa2298fb193d4d4"}, - {file = "jellyfish-1.1.0-cp313-cp313-musllinux_1_1_x86_64.whl", hash = "sha256:b460f0bbde533f6f8624c1d7439e7f511b227ca18a58781e7f38f21961bd3f09"}, {file = "jellyfish-1.1.0-cp38-cp38-macosx_10_12_x86_64.whl", hash = "sha256:7cd4b706cb6c4739846d78a398c67996cb451b09a732a625793cfe8d4f37af1b"}, {file = "jellyfish-1.1.0-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:61cded25b47fe6b4c2ea9478c0a5a7531845218525a1b2627c67907ee9fe9b15"}, {file = "jellyfish-1.1.0-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:04bf33577059afba33227977e4a2c08ccb954eb77c849fde564af3e31ee509d9"}, diff --git a/test/cli_test.py b/test/cli_test.py index bcbb4ba..70ed029 100644 --- a/test/cli_test.py +++ b/test/cli_test.py @@ -342,7 +342,7 @@ def test_unkown_collection(self): assert str(e.value) == "Alternative collection 'unkown' not found." @pytest.mark.skipif( - sys.platform.startswith("win"), reason="Image conversion not available" + not sys.platform.startswith("linux"), reason="Image conversion not available" ) def test_embed_art(self, tmp_path: Path): """Test that artwork is embedded and updated to match the source file.