Skip to content

Commit

Permalink
test
Browse files Browse the repository at this point in the history
  • Loading branch information
lrnv committed Sep 18, 2024
1 parent 0be4c4b commit 221e746
Showing 1 changed file with 29 additions and 13 deletions.
42 changes: 29 additions & 13 deletions .github/workflows/Downgrade.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,41 +11,57 @@ on:
- main
paths-ignore:
- 'docs/**'
jobs:
test:
runs-on: ubuntu-latest
strategy:
matrix:
version: ['1.6']
steps:
- uses: actions/checkout@v4
- uses: julia-actions/setup-julia@v1
with:
version: ${{ matrix.version }}
- uses: cjdoris/julia-downgrade-compat-action@v1
# if: ${{ matrix.version == '1.6' }}
with:
skip: InteractiveUtils,LinearAlgebra,Random,Test
- uses: julia-actions/julia-buildpkg@v1
- uses: julia-actions/julia-runtest@v1

jobs:
generate-matrix:
runs-on: ${{ github.event.inputs.os }}
runs-on: ubuntu-latest
outputs:
matrix: ${{ steps.genmat1.outputs.matrix || steps.genmat2.outputs.matrix }}
steps:
- uses: actions/checkout@v2
- uses: julia-actions/setup-julia@latest
with:
version: ${{ github.event.inputs.julia-version }}
arch: ${{ github.event.inputs.arch }}
version: 1
- run: julia -e 'using Pkg; pkg"add CompatHelperLocal"'
- run: julia -e 'using Pkg; pkg"add ${{ github.event.inputs.package }}${{ github.event.inputs.revision }}"'
- if: github.event.inputs.mode == 'two'
- run: julia -e 'using Pkg; pkg"add Copulas"'
- if: true #github.event.inputs.mode == 'two'
id: genmat1
run: |
echo '::echo::on'
julia -e 'import CompatHelperLocal as CHL; import ${{ github.event.inputs.package }}; projfile = joinpath(pathof(${{ github.event.inputs.package }}) |> dirname |> dirname, "Project.toml"); println(CHL.compats_combinations_to_gha_string(CHL.get_compats_combinations(projfile, only_resolveable=true)))'
- if: github.event.inputs.mode == 'all'
julia -e 'import CompatHelperLocal as CHL; import Copulas; projfile = joinpath(pathof(Copulas) |> dirname |> dirname, "Project.toml"); println(CHL.compats_combinations_to_gha_string(CHL.get_compats_combinations(projfile, only_resolveable=true)))'
- if: false # github.event.inputs.mode == 'all'
id: genmat2
run: |
echo '::echo::on'
julia -e 'import CompatHelperLocal as CHL; import ${{ github.event.inputs.package }}; projfile = joinpath(pathof(${{ github.event.inputs.package }}) |> dirname |> dirname, "Project.toml"); println(CHL.compats_combinations_to_gha_string(CHL.get_all_compats_combinations(projfile)))'
julia -e 'import CompatHelperLocal as CHL; import Copulas; projfile = joinpath(pathof(Copulas) |> dirname |> dirname, "Project.toml"); println(CHL.compats_combinations_to_gha_string(CHL.get_all_compats_combinations(projfile)))'
test:
needs: generate-matrix
runs-on: ${{ github.event.inputs.os }}
runs-on: ubuntu-latest
strategy:
matrix: ${{fromJSON(needs.generate-matrix.outputs.matrix)}}
fail-fast: false
steps:
- uses: actions/checkout@v2
- uses: julia-actions/setup-julia@latest
with:
version: ${{ github.event.inputs.julia-version }}
arch: ${{ github.event.inputs.arch }}
version: 1
- run: julia -e 'using Pkg; pkg"add CompatHelperLocal"'
- run: julia -e 'using Pkg; pkg"add ${{ github.event.inputs.package }}${{ github.event.inputs.revision }}"'
- run: julia -e 'import CompatHelperLocal as CHL; import ${{ github.event.inputs.package }}; CHL.test_compats_combinations(${{ github.event.inputs.package }}, [${{ matrix.compats }}])'
- run: julia -e 'using Pkg; pkg"add Copulas"'
- run: julia -e 'import CompatHelperLocal as CHL; import Copulas; CHL.test_compats_combinations(Copulas, [${{ matrix.compats }}])'

0 comments on commit 221e746

Please sign in to comment.