Skip to content

Feature/multi file #101

Feature/multi file

Feature/multi file #101

Workflow file for this run

name: Test
on:
push:
branches: [ main ]
pull_request:
branches: [ main, development ]
jobs:
test:
runs-on: ${{ matrix.os }}
env:
PYTHONNET_RUNTIME: coreclr
strategy:
matrix:
os: [ubuntu-latest]
steps:
- uses: actions/checkout@v4
with:
submodules: recursive
- name: Setup .NET
uses: actions/setup-dotnet@v4
with:
dotnet-version: 8.0.x
- name: Install NativeAOT dependencies (Linux)
if: runner.os == 'Linux'
run: |
sudo apt-get update
sudo apt-get install -y clang zlib1g-dev libkrb5-dev
- name: Publish NativeAOT lib
run: |
cd native/ThermoNativeReader
if [[ "${{ runner.os }}" == "macOS" ]]; then
ARCH=$(uname -m)
if [[ "$ARCH" == "arm64" ]]; then RID="osx-arm64"; else RID="osx-x64"; fi
LIB_FILE="ThermoNativeReader.dylib"
elif [[ "${{ runner.os }}" == "Linux" ]]; then
RID="linux-x64"
LIB_FILE="ThermoNativeReader.so"
else
RID="win-x64"
LIB_FILE="ThermoNativeReader.dll"
fi
dotnet publish -r $RID -c Release -p:PublishAot=true
echo "DYLIB_PATH=$(pwd)/bin/Release/net8.0/$RID/publish/$LIB_FILE" >> $GITHUB_ENV
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: '3.12'
- name: Install Rust
uses: dtolnay/rust-toolchain@stable
- name: Install dependencies
run: |
python -m venv .venv
source .venv/bin/activate
pip install maturin pytest numpy
pip install fisher-py
- name: Decompress test data
run: gunzip -d -k test_data/*.gz
- name: Download test data
run: |
wget -P test_data ftp://ftp.pride.ebi.ac.uk/pride/data/archive/2026/02/PXD066718/20250411_Ast0_500SPD_EVO685_JVO_EV1107_050ng_HEK-CPR_380-980_2Th_1P5ms_OFF_05_20250413081131.raw
wget -P test_data https://ftp.pride.ebi.ac.uk/pride/data/archive/2026/02/PXD066944/20250307_AST0_NEO5_JVO_MV50_DR_100SPD_10ng_HEK_Ref_DDA_2Th_1p5ms_10ms_v2Ref_cycle_03.raw
- name: Build and test
run: |
source .venv/bin/activate
# Patch fisher-py
python .github/patch_fisher_py.py
# Copy native lib for bundling
cp ${{ env.DYLIB_PATH }} native_fisher_py/python/native_fisher_py/
# Install the package
pip install ./native_fisher_py
# Parity tests will automatically fall back to ground_truth.json if fisher-py fails
python -m pytest tests