Skip to content

ci: build Debug

ci: build Debug #15

name: Build Pull Request
on:
pull_request:
branches:
- '**'
concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number }}
cancel-in-progress: true
jobs:
build-n-test:
runs-on: [gpu]
container:
image: ghcr.io/bnlnpps/esi-shell
volumes:
- /usr/local/optix:/usr/local/optix
options: -i -t
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Build
shell: bash
run: |
echo OPTICKS_PREFIX=$OPTICKS_PREFIX
rm -fr $OPTICKS_PREFIX/*
cmake -S . -B $OPTICKS_PREFIX/build -DCMAKE_INSTALL_PREFIX=$OPTICKS_PREFIX -DCMAKE_BUILD_TYPE=Debug
cmake --build $OPTICKS_PREFIX/build --parallel --target install
- name: Test
shell: bash
run: |
QCurandState_SPEC=3:0:0 /usr/local/opticks/lib/QCurandStateTest
ls -la $HOME/
ls -la $HOME/.opticks/
mkdir -p $HOME/.opticks/GEOM
cp tests/GEOM.sh $HOME/.opticks/GEOM/
ctest --test-dir $OPTICKS_PREFIX/build/okconf
ctest --test-dir $OPTICKS_PREFIX/build/sysrap -E STTFTest
ctest --test-dir $OPTICKS_PREFIX/build/ana
ctest --test-dir $OPTICKS_PREFIX/build/analytic
ctest --test-dir $OPTICKS_PREFIX/build/bin
ctest --test-dir $OPTICKS_PREFIX/build/CSG -E "CSGNodeTest|CSGPrimSpecTest|CSGPrimTest|CSGFoundryTest|CSGFoundry_getCenterExtent_Test|CSGFoundry_findSolidIdx_Test|CSGNameTest|CSGTargetTest|CSGTargetGlobalTest|CSGFoundry_MakeCenterExtentGensteps_Test|CSGFoundry_getFrame_Test|CSGFoundry_getFrameE_Test|CSGFoundry_getMeshName_Test|CSGFoundryLoadTest|CSGQueryTest|CSGSimtraceTest|CSGSimtraceRerunTest|CSGSimtraceSampleTest|CSGCopyTest|CSGScanTest"
ctest --test-dir $OPTICKS_PREFIX/build/qudarap -E "QSimTest|QOpticalTest|QSim_Lifecycle_Test|QSimWithEventTest"
ctest --test-dir $OPTICKS_PREFIX/build/CSGOptiX -E CSGOptiXRenderTest
ctest --test-dir $OPTICKS_PREFIX/build/gdxml
ctest --test-dir $OPTICKS_PREFIX/build/u4 -E "U4GDMLReadTest|U4RandomTest|U4TraverseTest"
ctest --test-dir $OPTICKS_PREFIX/build/g4cx -E G4CXRenderTest