Skip to content

Commit 43b2eba

Browse files
authored
Merge pull request #16 from IMIO/ADD-gha-test-workflow
Add gha test workflow
2 parents 6090827 + fcba532 commit 43b2eba

File tree

2 files changed

+44
-1
lines changed

2 files changed

+44
-1
lines changed

.github/workflows/docker-publish.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,8 @@ name: Update images
33
on:
44
workflow_dispatch:
55
push:
6-
branches: [ master ]
6+
branches:
7+
- master
78

89
concurrency:
910
group: ${{ github.workflow }}

.github/workflows/tests.yml

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
name: Test package
2+
3+
on:
4+
workflow_dispatch:
5+
push:
6+
branches:
7+
- master
8+
9+
concurrency:
10+
group: ${{ github.workflow }}-${{ github.ref }}
11+
cancel-in-progress: true
12+
13+
jobs:
14+
test:
15+
runs-on: gha-runners-delib-py2
16+
continue-on-error: ${{ matrix.experimental }}
17+
strategy:
18+
fail-fast: false
19+
matrix:
20+
python-version: ["2.7"]
21+
plone-version: ["4.3"]
22+
experimental: [false]
23+
if: ${{ !github.event_name == 'pull_request' || !github.event.pull_request.draft }}
24+
steps:
25+
- name: Needed for local development
26+
if: ${{ env.ACT }}
27+
run: echo /home/runner/externals/node20/bin >> $GITHUB_PATH
28+
shell: bash
29+
- name: Launch soffice
30+
run: soffice '--accept=socket,host=0.0.0.0,port=2002;urp;StarOffice.ServiceManager' --nologo --headless --nofirststartwizard --norestore &
31+
shell: bash
32+
- name: Run tests
33+
uses: IMIO/gha/plone-package-test-notify@v4
34+
env:
35+
cache-name: cache-eggs
36+
with:
37+
BUILDOUT_CONFIG_FILE: prod-test.cfg
38+
CACHE_KEY: ${{ runner.os }}-build-${{ env.cache-name }}-${{ matrix.python-version }}
39+
TEST_COMMAND: OO_SERVER=localhost OO_PORT=2002 bin/testprod --layer=\!ROBOT --test=\!\(testSetup\|testPerf\)
40+
INSTALL_DEPENDENCIES_COMMANDS: |
41+
sudo pip install -r requirements.txt
42+
MATTERMOST_WEBHOOK_URL: ${{ secrets.DELIB_MATTERMOST_WEBHOOK_URL }}

0 commit comments

Comments
 (0)