-
Notifications
You must be signed in to change notification settings - Fork 833
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
6 changed files
with
167 additions
and
18 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,107 @@ | ||
name: mosquitto Tests | ||
|
||
on: | ||
workflow_call: | ||
|
||
jobs: | ||
build_wolfssl: | ||
name: Build wolfSSL | ||
# Just to keep it the same as the testing target | ||
runs-on: ubuntu-latest | ||
# This should be a safe limit for the tests to run. | ||
timeout-minutes: 4 | ||
steps: | ||
- name: Build wolfSSL | ||
uses: wolfSSL/actions-build-autotools-project@v1 | ||
with: | ||
path: wolfssl | ||
configure: --enable-mosquitto | ||
install: true | ||
|
||
- name: Upload built lib | ||
uses: actions/upload-artifact@v3 | ||
with: | ||
name: wolf-install-mosquitto | ||
path: build-dir | ||
retention-days: 1 | ||
|
||
mosquitto_check: | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
# List of releases to test | ||
include: | ||
- ref: v2.0.15 | ||
ignore-tests: >- | ||
./01-connect-zero-length-id.py 06-bridge-reconnect-local-out.py | ||
./08-ssl-connect-cert-auth-crl.py | ||
./08-ssl-connect-cert-auth-revoked.py | ||
./08-ssl-connect-cert-auth.py | ||
./08-ssl-connect-identity.py | ||
./08-ssl-connect-no-auth.py | ||
./08-ssl-connect-no-identity.py | ||
./08-ssl-hup-disconnect.py | ||
./14-dynsec-acl.py | ||
./14-dynsec-anon-group.py | ||
./14-dynsec-auth.py | ||
./14-dynsec-client-invalid.py | ||
./14-dynsec-client.py | ||
./14-dynsec-default-access.py | ||
./14-dynsec-disable-client.py | ||
./14-dynsec-group-invalid.py | ||
./14-dynsec-group.py | ||
./14-dynsec-modify-client.py | ||
./14-dynsec-modify-group.py | ||
./14-dynsec-modify-role.py | ||
./14-dynsec-plugin-invalid.py | ||
./14-dynsec-role-invalid.py | ||
./14-dynsec-role.py | ||
name: ${{ matrix.ref }} | ||
runs-on: ubuntu-latest | ||
# This should be a safe limit for the tests to run. | ||
timeout-minutes: 4 | ||
needs: build_wolfssl | ||
steps: | ||
- name: Download lib | ||
uses: actions/download-artifact@v3 | ||
with: | ||
name: wolf-install-mosquitto | ||
path: build-dir | ||
|
||
- name: Checkout OSP | ||
uses: actions/checkout@v3 | ||
with: | ||
repository: wolfssl/osp | ||
path: osp | ||
|
||
- name: Install dependencies | ||
run: | | ||
export DEBIAN_FRONTEND=noninteractive | ||
sudo apt-get update | ||
sudo apt-get install -y build-essential libev-dev libssl-dev automake python3-docutils libcunit1 libcunit1-doc libcunit1-dev pkg-config make | ||
- name: Checkout mosquitto | ||
uses: actions/checkout@v3 | ||
with: | ||
repository: eclipse/mosquitto | ||
ref: v2.0.15 | ||
path: mosquitto | ||
|
||
# Do this before configuring so that it only detects the updated list of | ||
# tests | ||
- if: ${{ matrix.ignore-tests }} | ||
name: Remove tests that we want to ignore | ||
working-directory: ./mosquitto/test/broker | ||
run: | | ||
rm ${{ matrix.ignore-tests }} | ||
- name: Configure and build mosquitto | ||
run: | | ||
cd $GITHUB_WORKSPACE/mosquitto/ | ||
patch -p1 < $GITHUB_WORKSPACE/osp/mosquitto/2.0.15.patch | ||
make WITH_TLS=wolfssl WITH_CJSON=no WITH_DOCS=no | ||
- name: Run mosquitto tests, skipping ignored tests | ||
working-directory: ./mosquitto | ||
run: | | ||
make WITH_TLS=wolfssl WITH_CJSON=no WITH_DOCS=no ptest |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters