Skip to content

Commit

Permalink
Run tests automatically
Browse files Browse the repository at this point in the history
  • Loading branch information
kpushkaryov committed Dec 20, 2023
1 parent e93fce6 commit 8dedcfa
Show file tree
Hide file tree
Showing 2 changed files with 25 additions and 3 deletions.
22 changes: 22 additions & 0 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
name: Test with Buck

on: [push]

jobs:
test:
runs-on: ubuntu-20.04 # Not latest, because python3.6 is not available on latest
# https://github.com/actions/setup-python/issues/544
steps:
- name: Checkout repository and submodules
uses: actions/checkout@v4
with:
submodules: recursive
# We use tags to determine version, so fetch them
fetch-depth: 0
fetch-tags: true
- name: Perform tests
id: test
uses: SandakovMM/build-with-buck@v3
with:
command: test
target: --all
6 changes: 3 additions & 3 deletions pleskdistup/common/tests/motdtests.py
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ def tearDown(self):
def test_publish_simple_message(self):
expected_message = """
===============================================================================
Message from the Plesk dist-upgrade tool:
Message from the Plesk dist-upgrader tool:
one
You can remove this message from the {} file.
===============================================================================
Expand All @@ -78,7 +78,7 @@ def test_publish_simple_message(self):
def test_publish_several_messages(self):
expected_message = """
===============================================================================
Message from the Plesk dist-upgrade tool:
Message from the Plesk dist-upgrader tool:
one
two
You can remove this message from the {} file.
Expand All @@ -99,7 +99,7 @@ def test_backed_up_message_saved(self):
expected_message = """old
===============================================================================
Message from the Plesk dist-upgrade tool:
Message from the Plesk dist-upgrader tool:
one
two
You can remove this message from the {} file.
Expand Down

0 comments on commit 8dedcfa

Please sign in to comment.