Skip to content

Scripts for evaluating code performance #187

Scripts for evaluating code performance

Scripts for evaluating code performance #187

Workflow file for this run

name: auto_test
# This action is triggered:
# 1. when someone creates a pull request for a merge to the main branch
# 2. when changes are merged into the main branch (via a pull request)
on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
# Below are jobs, each of which runs sequentially.
jobs:
# This job builds the box model and runs our test suite.
build:
# A build matrix storing all desired configurations.
strategy:
matrix:
os: [ubuntu-22.04] #, macos-latest]
build-type: [Release, Debug]
sacado-on: [ON, OFF]
#fp-precision: [double] # single is not working for tchem.
runs-on: ${{ matrix.os }}
# Environment variables
env:
CI: 1 # indicates that we are running in a CI environment.
# Steps for building and running tests.
steps:
- name: Checking out repository
uses: actions/checkout@v2
with:
submodules: recursive
- name: Building TChem (${{ matrix.build-type }}, ${{ matrix.sacado-on }} sacado)
run: docker build -f Dockerfile -t tchem . --build-arg BUILD_TYPE=${{ matrix.build-type }} --build-arg SACADO=${{ matrix.sacado-on }}
- name: Testing TChem
run: docker run -t -v "$PWD:/shared" tchem bash -c 'cd /tchem_build; ctest; make coverage; mv coverage.info /shared'
- name: Uploading coverage report to codecov.io
if: ${{ (contains(matrix.os, 'ubuntu')) && (matrix.build-type == 'Debug') && (matrix.sacado-on == 'OFF') }}
uses: codecov/codecov-action@v3
with:
fail_ci_if_error: true
files: coverage.info
name: TChem-atm
token: ${{ secrets.CODECOV_TOKEN }}
verbose: true