|
| 1 | +name: CI (NonlinearSolveHomotopyContinuation) |
| 2 | + |
| 3 | +on: |
| 4 | + pull_request: |
| 5 | + branches: |
| 6 | + - master |
| 7 | + paths: |
| 8 | + - "lib/NonlinearSolveHomotopyContinuation/**" |
| 9 | + - ".github/workflows/CI_NonlinearSolveHomotopyContinuation.yml" |
| 10 | + - "lib/NonlinearSolveBase/**" |
| 11 | + push: |
| 12 | + branches: |
| 13 | + - master |
| 14 | + |
| 15 | +concurrency: |
| 16 | + # Skip intermediate builds: always. |
| 17 | + # Cancel intermediate builds: only if it is a pull request build. |
| 18 | + group: ${{ github.workflow }}-${{ github.ref }} |
| 19 | + cancel-in-progress: ${{ startsWith(github.ref, 'refs/pull/') }} |
| 20 | + |
| 21 | +jobs: |
| 22 | + test: |
| 23 | + runs-on: ${{ matrix.os }} |
| 24 | + strategy: |
| 25 | + fail-fast: false |
| 26 | + matrix: |
| 27 | + version: |
| 28 | + - "1.10" |
| 29 | + - "1" |
| 30 | + os: |
| 31 | + - ubuntu-latest |
| 32 | + - macos-latest |
| 33 | + - windows-latest |
| 34 | + steps: |
| 35 | + - uses: actions/checkout@v4 |
| 36 | + - uses: julia-actions/setup-julia@v2 |
| 37 | + with: |
| 38 | + version: ${{ matrix.version }} |
| 39 | + - uses: actions/cache@v4 |
| 40 | + env: |
| 41 | + cache-name: cache-artifacts |
| 42 | + with: |
| 43 | + path: ~/.julia/artifacts |
| 44 | + key: ${{ runner.os }}-test-${{ env.cache-name }}-${{ hashFiles('**/Project.toml') }} |
| 45 | + restore-keys: | |
| 46 | + ${{ runner.os }}-test-${{ env.cache-name }}- |
| 47 | + ${{ runner.os }}-test- |
| 48 | + ${{ runner.os }}- |
| 49 | + - name: "Install Dependencies and Run Tests" |
| 50 | + run: | |
| 51 | + import Pkg |
| 52 | + Pkg.Registry.update() |
| 53 | + # Install packages present in subdirectories |
| 54 | + dev_pks = Pkg.PackageSpec[] |
| 55 | + for path in ("lib/NonlinearSolveBase",) |
| 56 | + push!(dev_pks, Pkg.PackageSpec(; path)) |
| 57 | + end |
| 58 | + Pkg.develop(dev_pks) |
| 59 | + Pkg.instantiate() |
| 60 | + Pkg.test(; coverage="user") |
| 61 | + shell: julia --color=yes --code-coverage=user --depwarn=yes --project=lib/NonlinearSolveHomotopyContinuation {0} |
| 62 | + - uses: julia-actions/julia-processcoverage@v1 |
| 63 | + with: |
| 64 | + directories: lib/NonlinearSolveBase/src,lib/NonlinearSolveBase/ext,lib/NonlinearSolveHomotopyContinuation/src |
| 65 | + - uses: codecov/codecov-action@v5 |
| 66 | + with: |
| 67 | + file: lcov.info |
| 68 | + token: ${{ secrets.CODECOV_TOKEN }} |
| 69 | + verbose: true |
| 70 | + fail_ci_if_error: false |
| 71 | + |
| 72 | + downgrade: |
| 73 | + runs-on: ubuntu-latest |
| 74 | + strategy: |
| 75 | + fail-fast: false |
| 76 | + matrix: |
| 77 | + version: |
| 78 | + - "1.10" |
| 79 | + steps: |
| 80 | + - uses: actions/checkout@v4 |
| 81 | + - uses: julia-actions/setup-julia@v2 |
| 82 | + with: |
| 83 | + version: ${{ matrix.version }} |
| 84 | + - uses: julia-actions/julia-downgrade-compat@v1 |
| 85 | + with: |
| 86 | + skip: NonlinearSolveBase, SciMLJacobianOperators |
| 87 | + - name: "Install Dependencies and Run Tests" |
| 88 | + run: | |
| 89 | + import Pkg |
| 90 | + Pkg.Registry.update() |
| 91 | + # Install packages present in subdirectories |
| 92 | + dev_pks = Pkg.PackageSpec[] |
| 93 | + for path in ("lib/NonlinearSolveBase",) |
| 94 | + push!(dev_pks, Pkg.PackageSpec(; path)) |
| 95 | + end |
| 96 | + Pkg.develop(dev_pks) |
| 97 | + Pkg.instantiate() |
| 98 | + Pkg.test(; coverage="user") |
| 99 | + shell: julia --color=yes --code-coverage=user --depwarn=yes --project=lib/NonlinearSolveHomotopyContinuation {0} |
| 100 | + - uses: julia-actions/julia-processcoverage@v1 |
| 101 | + with: |
| 102 | + directories: lib/NonlinearSolveBase/src,lib/NonlinearSolveBase/ext,lib/NonlinearSolveHomotopyContinuation/src |
| 103 | + - uses: codecov/codecov-action@v5 |
| 104 | + with: |
| 105 | + file: lcov.info |
| 106 | + token: ${{ secrets.CODECOV_TOKEN }} |
| 107 | + verbose: true |
| 108 | + fail_ci_if_error: false |
0 commit comments