Skip to content

Commit

Permalink
Add CI tests, run VARNA tests only if java is installed (#8)
Browse files Browse the repository at this point in the history
* Add CI github workflow

* Only run VARNA tests if java executable can be found

* Add CI badge to README
  • Loading branch information
marcom authored Jun 26, 2023
1 parent 55c0617 commit 375c1bb
Show file tree
Hide file tree
Showing 3 changed files with 48 additions and 1 deletion.
41 changes: 41 additions & 0 deletions .github/workflows/CI.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
name: CI
on:
push:
branches:
- main
tags: ['*']
pull_request:
concurrency:
# Skip intermediate builds: always.
# Cancel intermediate builds: only if it is a pull request build.
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: ${{ startsWith(github.ref, 'refs/pull/') }}
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'
- '1'
os:
- ubuntu-latest
- macOS-latest
- windows-latest
arch:
- x64
steps:
- uses: actions/checkout@v2
- 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
- uses: julia-actions/julia-processcoverage@v1
- uses: codecov/codecov-action@v2
with:
files: lcov.info
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
# PlotRNA.jl

[![Build Status](https://github.com/marcom/PlotRNA.jl/actions/workflows/CI.yml/badge.svg?branch=main)](https://github.com/marcom/PlotRNA.jl/actions/workflows/CI.yml?query=branch%3Amain)

Plot nucleic acid secondary structures with Julia.

There are currently four different backends:
Expand Down
6 changes: 5 additions & 1 deletion test/runtests.jl
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,11 @@ showtestset() = println(" "^(2 * Test.get_testset_depth()), "testing ",
@testset verbose=true "PlotRNA" begin
showtestset()
include("plot_structure.jl")
include("varna.jl")
if isnothing(Sys.which("java"))
@warn "Can't find java executable, skipping VARNA tests"
else
include("varna.jl")
end
include("r2r.jl")
include("uniplot.jl")
include("plot_structure_makie.jl")
Expand Down

0 comments on commit 375c1bb

Please sign in to comment.