-
Notifications
You must be signed in to change notification settings - Fork 2
[WIP] Run tests as part of the CI process #89
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from 35 commits
Commits
Show all changes
36 commits
Select commit
Hold shift + click to select a range
4887933
add ci job for UbuntuTestSuite
AdelekeBankole 7a83204
add workflow run
AdelekeBankole 6f5d06c
add steps needed for job
AdelekeBankole c3cc6c7
add pFUnit to steps required in job
AdelekeBankole e729a7b
Update .github/workflows/test_suite_ubuntu.yml
AdelekeBankole 3d149eb
Update .github/workflows/test_suite_ubuntu.yml
AdelekeBankole 8841015
Update .github/workflows/test_suite_ubuntu.yml
AdelekeBankole 58098f1
add steps to run test suite
AdelekeBankole 02ba569
Update .github/workflows/test_suite_ubuntu.yml
AdelekeBankole 49f6e5b
add python linter, ruff
AdelekeBankole 9b33b65
add hdf5 in requirements.txt
AdelekeBankole 7e011f1
remove hdf5in requirements.txt
AdelekeBankole 1be238f
add and install hdf5
AdelekeBankole cf48d06
allow root privileges in getting hdf5
AdelekeBankole 7636480
add and install netcdf lib to dependencies
AdelekeBankole dfc4958
restrict python version
AdelekeBankole a6d5ac5
update python run options
AdelekeBankole 3bbf4db
remove pins from dependencies in sounding generation requirements.
jatkinson1000 e391538
remove ruff from testing suite as covered in the linting checks CI.
jatkinson1000 ebac2ff
test changing python version.
jatkinson1000 02902e3
Add SAM sounding file.
jatkinson1000 1ddcdaf
remove sounding generation from CI workflow as sounding has been uplo…
jatkinson1000 5053ec8
add netcdf-Fortran to the dependencies installed in the testing CI.
jatkinson1000 ca2326a
run test from test directory.
jatkinson1000 ec8a042
Fix ruff errors and pin version to prevent unanticipated issues from …
jatkinson1000 cee5bd7
Minor tidying of the python CI workflow file.
jatkinson1000 4b8662b
remove duplicate running of CAM interface test script in test-suite.
jatkinson1000 0b2ceec
Merge pull request #90 from m2lines/jwa-ci-dependencies-patch
AdelekeBankole 6ce1e13
add exit codes run step
AdelekeBankole 3cc3a8a
add stop 999
AdelekeBankole ddb302d
try to break code
AdelekeBankole 970b701
remove exit code
AdelekeBankole 11cf9d4
remove the break
AdelekeBankole 50bea02
add YOG convection test in ci
AdelekeBankole 609efb2
remove YOG convection test in ci
AdelekeBankole 04efe1e
Update .github/workflows/test_suite_ubuntu.yml
AdelekeBankole File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or 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
This file contains hidden or 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,71 @@ | ||
# Workflow to run CAM-ML test suite | ||
name: TestSuiteUbuntu | ||
|
||
# Controls when the workflow will run | ||
on: | ||
# Triggers the workflow on pushes to the "main" branch, i.e., PR merges | ||
push: | ||
branches: [ "main" ] | ||
|
||
# Triggers the workflow on pushes to open pull requests with code changes | ||
pull_request: | ||
paths: | ||
- '.github/workflows/test_suite_ubuntu.yml' | ||
- '**.f90' | ||
- '**.F90' | ||
- '**CMakeLists.txt' | ||
- '**requirements.txt' | ||
|
||
# Allows you to run this workflow manually from the Actions tab | ||
workflow_dispatch: | ||
|
||
# Cancel jobs running if new commits are pushed | ||
concurrency: | ||
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} | ||
cancel-in-progress: true | ||
|
||
# Workflow run - one or more jobs that can run sequentially or in parallel | ||
jobs: | ||
# This workflow contains a single job called "test-suite-ubuntu" | ||
test-suite-ubuntu: | ||
# The type of runner that the job will run on | ||
runs-on: ubuntu-latest | ||
strategy: | ||
fail-fast: false | ||
|
||
# These steps represent sequence of tasks that will be executed as part of the job | ||
steps: | ||
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it | ||
- name: Checkout code | ||
with: | ||
persist-credentials: false | ||
uses: actions/checkout@v4 | ||
|
||
# Install Python 3 | ||
- name: Install Python | ||
uses: actions/setup-python@v5 | ||
with: | ||
python-version: '3.x' | ||
|
||
# Install dependencies | ||
- name: Install dependencies | ||
run: | | ||
sudo apt-get update | ||
sudo apt-get install -y libhdf5-dev libnetcdf-dev libnetcdff-dev | ||
|
||
# Build the code with cmake | ||
- name: Build test suite | ||
run: | | ||
cd tests/ | ||
mkdir build | ||
cd build | ||
cmake .. | ||
cmake --build . | ||
|
||
# Run the test suites | ||
- name: Test suite | ||
run: | | ||
cd tests/build | ||
./test_CAM_interface | ||
# This YOG convection test will be addressed in a separate issue | ||
# ./test_YOG_convection |
Binary file not shown.
This file contains hidden or 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 |
---|---|---|
@@ -1,4 +1,4 @@ | ||
certifi==2023.7.22 | ||
cftime==1.6.2 | ||
netCDF4==1.6.4 | ||
numpy==1.21.6 | ||
certifi | ||
cftime | ||
netCDF4 | ||
numpy |
This file contains hidden or 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 |
---|---|---|
@@ -1,4 +1,4 @@ | ||
torch | ||
netcdf4 | ||
ruff | ||
ruff==0.9.1 | ||
pytest |
This file contains hidden or 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
This file contains hidden or 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
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.