From d152726e8bc0348c26d532e43def48add774e5b3 Mon Sep 17 00:00:00 2001 From: 201st-Luka Date: Sat, 19 Aug 2023 13:02:39 +0200 Subject: [PATCH 1/2] feat: created release workflow the build.sh file is redundant --- .github/workflows/release.yml | 35 +++++++++++++++++++++++++++++++++++ build.sh | 3 --- 2 files changed, 35 insertions(+), 3 deletions(-) create mode 100644 .github/workflows/release.yml delete mode 100644 build.sh diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml new file mode 100644 index 0000000..997ce24 --- /dev/null +++ b/.github/workflows/release.yml @@ -0,0 +1,35 @@ +name: Build and Upload Release + +on: + release: + types: + - created + +jobs: + build: + name: Build and Upload + runs-on: ubuntu-latest + + steps: + - name: Checkout Repository + uses: actions/checkout@v2 + + - name: Set up Python + uses: actions/setup-python@v2 + with: + python-version: 3.x + + - name: Install Dependencies + run: | + python -m pip install --upgrade pip + pip install setuptools wheel twine + + - name: Build Package + run: | + python setup.py sdist bdist_wheel + + - name: Upload to Release + uses: softprops/action-gh-release@v1 + with: + files: dist/* + token: ${{ secrets.GITHUB_TOKEN }} diff --git a/build.sh b/build.sh deleted file mode 100644 index 27ee70e..0000000 --- a/build.sh +++ /dev/null @@ -1,3 +0,0 @@ -rm -r build dist pyclasher.egg-info - -python setup.py sdist bdist_wheel From 6fd2eef7db3e0cd2e74f9e091f67d5b1e8c75ed6 Mon Sep 17 00:00:00 2001 From: 201st-Luka Date: Tue, 22 Aug 2023 13:24:58 +0200 Subject: [PATCH 2/2] tests: fixed wrong test in test_clan.py in `test_clan_members` line 79: `member.previous_clan_rank` is 0 if the player joined --- tests/requests/async_tests/test_clan.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/requests/async_tests/test_clan.py b/tests/requests/async_tests/test_clan.py index 13e8947..3d4915a 100644 --- a/tests/requests/async_tests/test_clan.py +++ b/tests/requests/async_tests/test_clan.py @@ -76,7 +76,7 @@ async def test_clan_member(event_loop, pyclasher_client): assert isinstance(member.league, League) assert isinstance(member.player_house, (PlayerHouse, Missing)) assert isinstance(member.previous_clan_rank, int) - assert 1 <= member.previous_clan_rank <= 50 + assert 0 <= member.previous_clan_rank <= 50 assert isinstance(member.role, ClanRole)