Skip to content

Introduce some new test workflow #2

Introduce some new test workflow

Introduce some new test workflow #2

Workflow file for this run

name: Verification, norma
on:
# Trigger the workflow on push or pull request
push:
# Trigger the workflow manually
# schedule:
# - cron: '0 22 */7 * *'
workflow_dispatch:
env:
GFORTRAN_VERSION: 12
jobs:
test:
name: Verify BDS.
runs-on: ${{matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest]
matlab: [latest]
with_optim_toolbox: [yes]
Algorithm: [cbds, ds, pbds, rbds, pads, scbds]
parallel: [true, false]
steps:
- name: Check out repository
uses: actions/checkout@v4
with:
submodules: recursive
- name: Clone bds_development
uses: actions/checkout@v4
with:
repository: blockwise-direct-search/bds_development
path: bds_development
- name: Clone MatCUTEst
uses: actions/checkout@v4
with:
repository: matcutest/matcutest_compiled
path: matcutest
- name: Link gfortran for MATLAB on Linux
if: startsWith(matrix.os, 'ubuntu')
run: bash .github/scripts/link_gfortran ${{ env.GFORTRAN_VERSION }}
- name: Install epstopdf and ghostscript
if: startsWith(matrix.os, 'ubuntu')
run: bash .github/scripts/install_epstopdf && bash .github/scripts/install_ghostscript
- name: Install Texlive
run: sudo apt-get update && sudo apt-get install texlive
- name: Check whether LaTeX is installed
run: pdflatex --version
- name: Cache MATLAB
id: cache-matlab
uses: actions/cache@v4.0.1
with:
path: ${{ runner.tool_cache }}/MATLAB
key: ${{ matrix.os }}-${{ matrix.matlab }}-${{ matrix.with_optim_toolbox }}
- name: Set up MATLAB with optimization toolbox
if: ${{ matrix.with_optim_toolbox == 'yes' }}
uses: matlab-actions/setup-matlab@v2.1.2
with:
release: ${{ matrix.matlab }}
products: Optimization_Toolbox
- name: Run test
uses: matlab-actions/run-command@v2.1.1
with:
command: |
root_dir = pwd()
ls
% Install MatCUTEst
cd(fullfile(root_dir, 'matcutest'));
install(); cd(root_dir);
% Setup bds_development
cd(fullfile(root_dir, 'bds_development'));
cd(fullfile(root_dir, 'bds_development', 'norma'));
setup
% Setup bds
setup
% Run test
cd(fullfile(root_dir, 'tests'))
parameters.Algorithm = '${{ matrix.Algorithm }}';
parameters.parallel = ${{ matrix.parallel }};
verify_bds(parameters);