-
Notifications
You must be signed in to change notification settings - Fork 230
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
minimum example to test formatting and feasibility
- Loading branch information
1 parent
7f21df2
commit 2433840
Showing
2 changed files
with
135 additions
and
5 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
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,99 @@ | ||
name: Generate Regression Baseline | ||
|
||
on: | ||
workflow_dispatch: | ||
|
||
schedule: | ||
- cron: "0 6 * * 1-5" | ||
|
||
jobs: | ||
build-and-test-linux: | ||
runs-on: ubuntu-latest | ||
env: # update this if needed to match a pull request on the RMG-database | ||
RMG_DATABASE_BRANCH: main | ||
defaults: | ||
run: | ||
shell: bash -l {0} | ||
steps: | ||
- uses: actions/checkout@v2 | ||
|
||
# configures the mamba environment manager | ||
- name: Setup Mambaforge Python 3.7 | ||
uses: conda-incubator/setup-miniconda@v2 | ||
with: | ||
environment-file: environment.yml | ||
miniforge-variant: Mambaforge | ||
miniforge-version: latest | ||
python-version: 3.7 | ||
activate-environment: rmg_env | ||
use-mamba: true | ||
|
||
# list the environment for debugging purposes | ||
- name: mamba info | ||
run: | | ||
mamba info | ||
mamba list | ||
# RMG installation and linking to Julia | ||
- name: Install and link Julia dependencies | ||
run: | | ||
julia -e "using Pkg; Pkg.add(PackageSpec(url=\"https://github.com/ReactionMechanismGenerator/ReactionMechanismSimulator.jl\", rev=\"main\"))" | ||
julia -e "using Pkg; Pkg.add(\"PyCall\"); Pkg.add(\"DifferentialEquations\")" | ||
python -c "import julia; julia.install()" | ||
ln -sfn $(which python-jl) $(which python) | ||
# Attempt to install MOPAC | ||
- name: Install MOPAC | ||
env: | ||
MOPACKEY: ${{ secrets.MOPACKEY }} | ||
timeout-minutes: 1 | ||
continue-on-error: true # allowed to fail on pull request from a forked repository | ||
run: | | ||
set +o pipefail | ||
yes 'Yes' | ${CONDA_PREFIX}/bin/mopac "$MOPACKEY" | ||
# Clone the other needed repositories | ||
- name: Install and Compile RMG | ||
run: | | ||
cd .. | ||
git clone -b $RMG_DATABASE_BRANCH https://github.com/ReactionMechanismGenerator/RMG-database.git | ||
cd RMG-Py | ||
git clone -b arkanepy3 https://github.com/mjohnson541/Q2DTor.git external/Q2DTor | ||
make | ||
# Regression Testing | ||
- name: Regression Tests | ||
run: | | ||
timeout 600 python-jl rmg.py test/regression/aromatics/input.py | ||
# python-jl scripts/checkModels.py test/regression/aromatics $benchmark_model/chemkin/chem_annotated.inp $benchmark_model/chemkin/species_dictionary.txt $testing_model/chemkin/chem_annotated.inp $testing_model/chemkin/species_dictionary.txt | ||
# aromatics_status=$? | ||
# ./run.sh test/regression/nitrogen | ||
# nitrogen_status=$? | ||
# ./run.sh test/regression/sulfur | ||
# sulfur_status=$? | ||
# ./run.sh test/regression/oxidation | ||
# oxidation_status=$? | ||
# ./run.sh test/regression/liquid_oxidation | ||
# liquid_oxidation_status=$? | ||
# ./run.sh test/regression/superminimal | ||
# superminimal_status=$? | ||
# ./run.sh test/regression/eg1 | ||
# eg1_status=$? | ||
# echo "aromatics status: $aromatics_status" | ||
# echo "nitrogen status: $nitrogen_status" | ||
# echo "sulfur status: $sulfur_status" | ||
# echo "oxidation status: $oxidation_status" | ||
# echo "liquid oxidation status: $liquid_oxidation_status" | ||
# echo "superminimal status: $superminimal_status" | ||
# echo "eg1 status: $eg1_status" | ||
# if [ $(($aromatics_status | $nitrogen_status | $sulfur_status | $oxidation_status | $liquid_oxidation_status | $superminimal_status | $eg1_status)) -ne 0 ]; | ||
# then | ||
# echo "Failed regression tests (non-zero exit code from regression test)" | ||
# exit 1 | ||
# fi | ||
# Install and Call codecov only if ALL the tests were successful | ||
- name: Upload Results as Artifacts | ||
run: | | ||
echo "Jackson do this also." |