AtChem / AtChem2

Atmospheric chemistry box-model for the MCM
MIT License
58 stars 23 forks source link

New Testsuite #464

Closed rs028 closed 2 years ago

rs028 commented 2 years ago

Starting work on the new test suite. This PR contains some reorganization of the directories to allow the new and the old tests to run in parallel until work is completed.

To make things clearer, the command to run the build and behavioural tests has been changed from make tests to make modeltests.

codecov[bot] commented 2 years ago

Codecov Report

Merging #464 (eabb9cf) into master (4d72237) will decrease coverage by 10.13%. The diff coverage is n/a.

Impacted file tree graph

@@             Coverage Diff             @@
##           master     #464       +/-   ##
===========================================
- Coverage   65.51%   55.37%   -10.14%     
===========================================
  Files          17       17               
  Lines        2047     2046        -1     
===========================================
- Hits         1341     1133      -208     
- Misses        706      913      +207     
Flag Coverage Δ
build 52.23% <ø> (ø)
tests ?
unittests 31.61% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
src/interpolationFunctions.f90 0.00% <0.00%> (-36.37%) :arrow_down:
src/inputFunctions.f90 36.07% <0.00%> (-18.87%) :arrow_down:
src/constraintFunctions.f90 21.70% <0.00%> (-18.61%) :arrow_down:
src/solverFunctions.f90 35.80% <0.00%> (-13.59%) :arrow_down:
src/dataStructures.f90 50.00% <0.00%> (-8.07%) :arrow_down:
src/outputFunctions.f90 50.00% <0.00%> (-5.85%) :arrow_down:
src/argparse.f90 24.21% <0.00%> (-3.91%) :arrow_down:
src/atchem2.f90 85.14% <0.00%> (-2.54%) :arrow_down:
src/parameterModules.f90 91.30% <0.00%> (-1.45%) :arrow_down:
test/unit_tests/date_test.f90
... and 9 more

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update 4d72237...eabb9cf. Read the comment docs.

rs028 commented 2 years ago

@spco Am I reading this wrong or CodeCov is working again? I haven't touched it.

spco commented 2 years ago

No idea - as far as I am concerned, CodeCov's input here should just be ignored regardless! :D

rs028 commented 2 years ago

You mean ignore it for this type of PR?

spco commented 2 years ago

Frankly, I don't trust it to be meaningful and/or correct on any PR!

rs028 commented 2 years ago

Fair enough. Should we consider removing it altogether or mark it as something to be (eventually) fixed?

rs028 commented 2 years ago

Any idea why test fails on MacOS with gfortran 8? It gives an error about sundials, but it appears that cvode is installed correctly.

spco commented 2 years ago

I'm not sure, but I think the error in the install cvode (MacOS) step may be something to do with it - it fail to link a simple fortran program.

-- Trying to compile and link a simple Fortran program... FAILED
WARNING: Fortran compiler not functional.
   FCMIX support will not be provided.

It looks like the image we use - macos-latest - has upgraded from 10.15 to 11 recently - see https://github.com/actions/virtual-environments/issues/4060 .

I suspect this may have something to do with it - perhaps v11 has some different permissions, or something else.

To diagnose whether this is the cause, perhaps you could change macos-latest at https://github.com/AtChem/AtChem2/blob/4d72237f2abbe72eb26a8cedb1575235f2d7739f/.github/workflows/ci.yml#L25 to macOS-10.15 (note the capitalisation) and see whether that runs successfully?

rs028 commented 2 years ago

Looks like that. I will leave it to version 10.15 for the time being and make a note of it. If there are no further comments I am ready to merge this and start developing the tests.