-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Create CI.yml * Update CI.yml Fix -D option * add missing c_ptr and use .EQV. instead .EQ. * compare files * Update CI.yml check directory * Update CI.yml There is a problem with assumed rank arrays and gfortran v9 * only test gcc-10 and gcc-11
- Loading branch information
Showing
2 changed files
with
49 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
name: zfp Fortran Testing | ||
|
||
# Define when to trigger the workflow | ||
on: | ||
push: | ||
branches: [main] | ||
pull_request: | ||
branches: [main] | ||
workflow_dispatch: | ||
|
||
jobs: | ||
test_bindings: | ||
name: Test zfp Fortran example on ubuntu-latest | ||
runs-on: ubuntu-latest | ||
|
||
strategy: | ||
matrix: | ||
gcc-version: [10, 11] | ||
|
||
steps: | ||
# Setup GCC | ||
- name: Get compiler | ||
uses: fortran-lang/setup-fortran@v1 | ||
with: | ||
compiler: gcc | ||
version: ${{ matrix.gcc-version }} | ||
|
||
# Clone the own repository to access test data files | ||
- name: Clone own repository | ||
uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 0 | ||
|
||
# Build executable and compare output files | ||
- name: Build simple and exe executables and compare files | ||
run: | | ||
cmake -S . -B build -DREAL_KIND=REAL64 -DBUILD_EXAMPLES=ON -DCMAKE_VERBOSE_MAKEFILE=ON | ||
cmake --build build | ||
cd build | ||
./exe -c | ||
./exe -d | ||
cd _deps/zfp-build/bin/ | ||
./simple > compressed_c.zfp | ||
./simple -d < compressed_c.zfp > decompressed_c.zfp | ||
cmp compressed_c.zfp ../../../compressed.zfp && echo "Files are identical" || { echo "Files are different"; exit 1; } | ||
cmp decompressed_c.zfp ../../../decompressed.zfp && echo "Files are identical" || { echo "Files are different"; exit 1; } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters