Skip to content

Commit

Permalink
Merge pull request #10 from permamodel/mdpiper/use-github-actions
Browse files Browse the repository at this point in the history
Use GitHub Actions for CI testing
  • Loading branch information
mdpiper authored Oct 5, 2024
2 parents 4b864b7 + 14fc2e6 commit 41dd42a
Show file tree
Hide file tree
Showing 3 changed files with 56 additions and 46 deletions.
55 changes: 55 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
name: Test

on: [push, pull_request]

env:
BMI_VERSION: 1_2

jobs:
build-on-unix:

if:
github.event_name == 'push' || github.event.pull_request.head.repo.full_name !=
github.repository

runs-on: ${{ matrix.os }}

defaults:
run:
shell: bash -l {0}

env:
SHLIB_EXT: ${{ matrix.os == 'ubuntu-latest' && '.so' || '.dylib' }}

strategy:
matrix:
os: [ubuntu-latest, macos-latest]

steps:
- uses: actions/checkout@v4

- uses: mamba-org/setup-micromamba@v2
with:
micromamba-version: latest
environment-name: testing
create-args: >-
make
cmake
fortran-compiler
- name: Make build directory
run: cmake -E make_directory build

- name: Configure
working-directory: ${{ github.workspace }}/build
run: cmake .. -DCMAKE_INSTALL_PREFIX=$CONDA_PREFIX -DCMAKE_BUILD_TYPE=Release

- name: Build and install
working-directory: ${{ github.workspace }}/build
run: cmake --build . --target install --config Release

- name: Test
working-directory: ${{ github.workspace }}/build
run: |
test -h $CONDA_PREFIX/lib/libbmigiplf${{ env.SHLIB_EXT }}
ctest
45 changes: 0 additions & 45 deletions .travis.yml

This file was deleted.

2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

#### This is to develop a BMI for GIPL with FORTRAN. Original GIPL code is avaiable at [this repository](https://github.com/Elchin/GIPL).

[![Build Status](https://travis-ci.org/permamodel/GIPL-BMI-Fortran.svg?branch=master)](https://travis-ci.org/permamodel/GIPL-BMI-Fortran)
[![Test](https://github.com/permamodel/GIPL-BMI-Fortran/actions/workflows/test.yml/badge.svg)](https://github.com/permamodel/GIPL-BMI-Fortran/actions/workflows/test.yml)

#### **NOTE: Currently, it is only 1D version. More works are required for the spatial version**

Expand Down

0 comments on commit 41dd42a

Please sign in to comment.