Skip to content

Commit

Permalink
Merge pull request #29 from daschw/ci
Browse files Browse the repository at this point in the history
Use Github Actions
  • Loading branch information
daschw authored Jun 30, 2020
2 parents 1caebad + 3f1d4e0 commit 086a3ff
Show file tree
Hide file tree
Showing 5 changed files with 86 additions and 67 deletions.
80 changes: 80 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,80 @@
name: ci

on:
push:
pull_request:

defaults:
run:
shell: bash

jobs:
CI:
if: "!contains(github.event.head_commit.message, '[skip ci]')"
env:
GKS_ENCODING: "utf8"
GKSwstype: "100"

name: Julia ${{ matrix.version }} - ${{ matrix.os }}
runs-on: ${{ matrix.os }}
continue-on-error: ${{ matrix.version == 'nightly' }}
strategy:
fail-fast: false
matrix:
version:
- '1.3'
- '1'
- 'nightly'
os:
- ubuntu-latest
- windows-latest
- macos-latest
arch:
- x64
# - x86

steps:

# Setup environment
- uses: actions/checkout@v2
- uses: julia-actions/setup-julia@latest
with:
version: ${{ matrix.version }}
- name: Cache artifacts
uses: actions/cache@v1
env:
cache-name: cache-artifacts
with:
path: ~/.julia/artifacts
key: ${{ runner.os }}-test-${{ env.cache-name }}-${{ hashFiles('**/Project.toml') }}
restore-keys: |
${{ runner.os }}-test-${{ env.cache-name }}-
${{ runner.os }}-test-
${{ runner.os }}-
# TESTCMD
- name: Default TESTCMD
run: echo ::set-env name=TESTCMD::"julia"
- name: Ubuntu TESTCMD
if: startsWith(matrix.os,'ubuntu')
run: echo ::set-env name=TESTCMD::"xvfb-run julia"

# Julia Dependencies
- name: Install Julia dependencies
uses: julia-actions/julia-buildpkg@latest

# Run tests
- name: Run Graphical test
run: $TESTCMD --project -e 'using Pkg; Pkg.test(coverage=true);'

# - name: Codecov
# uses: julia-actions/julia-uploadcodecov@latest
# env:
# CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}

Skip:
if: "contains(github.event.head_commit.message, '[skip ci]')"
runs-on: ubuntu-latest
steps:
- name: Skip CI 🚫
run: echo skip ci
14 changes: 0 additions & 14 deletions .travis.yml

This file was deleted.

7 changes: 4 additions & 3 deletions Project.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
name = "VisualRegressionTests"
uuid = "34922c18-7c2a-561c-bac1-01e79b2c4c92"
author = "Thomas Breloff"
version = "0.3.3"
version = "1.0.0"

[deps]
ColorTypes = "3da002f7-5984-5a60-b8a6-cbb66c0b333f"
Expand All @@ -20,13 +20,14 @@ ImageFiltering = "0.4, 0.5, 0.6"
ImageMagick = "0.7, 1"
QuartzImageIO = "0.7"
Requires = "1"
julia = "1"
julia = "1.3"

[extras]
Gtk = "4c0ca9eb-093a-5379-98c5-f87ac0bbbf44"
Pkg = "44cfe95a-1eb2-52ea-b672-e2afdf69b78f"
Plots = "91a5bcdd-55d7-5caf-9e0b-520d859cae80"
Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40"
TestImages = "5e47fb64-e119-507b-a336-dd2b206d9990"

[targets]
test = ["Pkg", "Test", "Plots", "TestImages"]
test = ["Gtk", "Pkg", "Test", "Plots", "TestImages"]
43 changes: 0 additions & 43 deletions appveyor.yml

This file was deleted.

9 changes: 2 additions & 7 deletions test/runtests.jl
Original file line number Diff line number Diff line change
@@ -1,12 +1,7 @@
using VisualRegressionTests
using Pkg, Test, Plots
using Gtk, Plots, Test, VisualRegressionTests

# popup on local machine only
istravis = "TRAVIS" keys(ENV)
if !istravis
Pkg.add("Gtk")
using Gtk
end
istravis = get(ENV, "CI", "false") == "true"

# load an image for testing
import FileIO, TestImages
Expand Down

2 comments on commit 086a3ff

@daschw
Copy link
Member Author

@daschw daschw commented on 086a3ff Jun 30, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@JuliaRegistrator
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Registration pull request created: JuliaRegistries/General/17253

After the above pull request is merged, it is recommended that a tag is created on this repository for the registered package version.

This will be done automatically if the Julia TagBot GitHub Action is installed, or can be done manually through the github interface, or via:

git tag -a v1.0.0 -m "<description of version>" 086a3ff7d0767568cb65cc526a92ff594e0c2107
git push origin v1.0.0

Please sign in to comment.