Add github actions yaml files.

Change-Id: I06e9968b792d9c218273873f36ee8e9157b04344
Reviewed-on: https://code.wireshark.org/review/36181
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
This commit is contained in:
Dario Lombardo 2020-02-15 23:01:54 +01:00 committed by Anders Broman
parent 321de10aad
commit a7e3942101
3 changed files with 117 additions and 0 deletions

35
.github/workflows/macos.yml vendored Normal file
View File

@ -0,0 +1,35 @@
name: Build MacOS
on: [push]
jobs:
windows:
name: Build & Test
runs-on: macos-latest
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Install deps
run: ./tools/macos-setup-brew.sh
- name: Mkdir
run: mkdir build
- name: Cmake
working-directory: build
run: cmake -GNinja ..
- name: Build
run: ninja
working-directory: build
- name: Build test-programs
run: ninja test-programs
working-directory: build
- name: Set up Python 3.8
uses: actions/setup-python@v1
with:
python-version: 3.8
- name: Install pytest
run: pip install pytest pytest-xdist
- name: Run tests
env:
PYTEST_ADDOPTS: --skip-missing-programs=rawshark
run: pytest
working-directory: build

35
.github/workflows/ubuntu.yml vendored Normal file
View File

@ -0,0 +1,35 @@
name: Build Ubuntu
on: [push]
jobs:
windows:
name: Build & Test
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Install deps
run: sudo tools/debian-setup.sh --install-optional --install-test-deps python3-pip -y
- name: Mkdir
run: mkdir build
- name: Cmake
working-directory: build
run: cmake -GNinja ..
- name: Build
run: ninja
working-directory: build
- name: Build test-programs
run: ninja test-programs
working-directory: build
- name: Set up Python 3.8
uses: actions/setup-python@v1
with:
python-version: 3.8
- name: Install pytest
run: pip install pytest pytest-xdist
- name: Run tests
env:
PYTEST_ADDOPTS: --skip-missing-programs=rawshark
run: pytest
working-directory: build

47
.github/workflows/windows.yml vendored Normal file
View File

@ -0,0 +1,47 @@
name: Build Windows
on: [push]
jobs:
windows:
name: Build & Test
runs-on: windows-latest
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Choco install
run: cinst -y --no-progress --force winflexbison3 cmake
- name: Install strawberryperl
run: |
choco install strawberryperl
echo "##[add-path]C:\strawberry\c\bin;C:\strawberry\perl\site\bin;C:\strawberry\perl\bin"
- name: Install Qt
# Using ouuan's due to this bug
# https://github.com/jurplel/install-qt-action/issues/27
uses: ouuan/install-qt-action@v2.3.1
- name: Mkdir
run: mkdir build
- name: Cmake
run: cmake -A x64 ..
env:
PLATFORM: x64
WIRESHARK_BASE_DIR: C:/wireshark-libs
QT5_BASE_DIR: C:/Qt/5.12.3/msvc2017_64
working-directory: build
- name: Build
run: cmake --build . --config RelWithDebInfo
working-directory: build
- name: Build test-programs
run: cmake --build . --config RelWithDebInfo --target test-programs
working-directory: build
- name: Set up Python 3.8
uses: actions/setup-python@v1
with:
python-version: 3.8
- name: Install pytest
run: pip install pytest pytest-xdist
- name: Run tests
env:
PYTEST_ADDOPTS: --skip-missing-programs=rawshark
run: pytest
working-directory: build