Skip to content

Add new tests for seven modules. Include GH workflow. #3

Add new tests for seven modules. Include GH workflow.

Add new tests for seven modules. Include GH workflow. #3

Workflow file for this run

name: CI
on:
pull_request:
push:
branches: [main, develop]
tags: ['*']
jobs:
test:
name: Julia ${{ matrix.version }} - ${{ matrix.os }} - ${{ matrix.arch }} - ${{ github.event_name}}
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
version:
- "1.6" # LTS (64-bit Linux)
- "1.7"
- "1.8"
- '1.9' # latest stable Julia release (Linux)
os:
- ubuntu-latest
arch:
- x64
include: # additional tests [Julia-nightly] (Linux)
- os: ubuntu-latest
version: 'nightly'
arch: x64
allow_failure: true
steps:
- uses: actions/checkout@v3
- name: Create a new branch and pull test logs from repo
run: |
git checkout -b ${GITHUB_REF#refs/heads/}-testlogs
mkdir test/Logs; cd test/Logs
git config --global init.defaultBranch main
git init
git config --local user.name GenXProject
git config --local user.email "[email protected]"
git remote add testlog https://[email protected]/GenXProject/GenX-testlog.git
git pull testlog main
if [ -d Logs_v${{ matrix.version }} ]; then
mv Logs_v${{ matrix.version }}/*.log .
else
mkdir Logs_v${{ matrix.version }}
fi
env:
LOG_TOKEN: ${{ secrets.LOG_TOKEN }}
- uses: julia-actions/setup-julia@v1
with:
version: ${{ matrix.version }}
arch: ${{ matrix.arch }}
- uses: julia-actions/cache@v1
- uses: julia-actions/julia-buildpkg@v1
- uses: julia-actions/julia-runtest@v1
- name: Commit logs and push back to repo
run: |
cd ${GITHUB_WORKSPACE}/test/Logs
mv *.log Logs_v${{ matrix.version }}
git add -f Logs_v${{ matrix.version }}
git commit -m "Update test logs for Julia v${{ matrix.version }}"
git pull --rebase testlog main # pull again to avoid conflicts from other versions
git push testlog main
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- uses: julia-actions/julia-processcoverage@v1
- uses: codecov/codecov-action@v3
with:
file: lcov.info