Skip to content

ENH: Establish basic test pipeline

Florian Spreckelsen requested to merge f-int-tests into dev

Summary

As explained in https://gitlab.indiscale.com/caosdb/customers/lfpb/management/-/issues/359, this MR introduces integration tests and a basic pipeline that's automatically triggered by commits in caosdb-julialib.

Focus

Mainly pipeline stuff. Since it is not common practice to have tests and implementation in separate packages, there are two ways of using this package. For testing the remote package CaosDB.jl, mainly the way to go for the pipeline, this package can be used as any other Julia package, while for testing of a local CaosDB.jl, runtests.jl has either to be used separately or the local CaosDB.jl package has to be added as a test dependency manually (see below).

Test Environment

Mainly verify that the pipeline is correctly triggered by caosdb-julialib, that the correct branches are used, and that everything runs smoothly.

When executed from the CaosDBIntegrationTest.jl package, the package will try and use the CaosDB.jl package in a fitting branch from remote, so if you want to execute the integration tests with your local CaosDB.jl installation, do

julia test/runtests.jl

Note that without specifying the verbosity, there won't be (test) output if the tests succeed. Alternatively, you can add your local package to the test dependencies and then use Pkg.test as usual, i.e.,

julia> ] activate ./test
julia> ] add path/to/local/caosdb-julialib
julia> ] activate .
julia> ] test

Check List for the Author

Please, prepare your MR for a review. Be sure to write a summary and a focus and create gitlab comments for the reviewer. They should guide the reviewer through the changes, explain your changes and also point out open questions. For further good practices have a look at our review guidelines

  • All automated tests pass
  • Reference related Issues
  • Up-to-date CHANGELOG.md
  • Annotations in code (Gitlab comments)
    • Intent of new code
    • Problems with old code
    • Why this implementation?

Check List for the Reviewer

  • I understand the intent of this MR
  • All automated tests pass
  • Up-to-date CHANGELOG.md
  • The test environment setup works and the intended behavior is reproducible in the test environment
  • In-code documentation and comments are up-to-date.
  • Check: Are there spezifications? Are they satisfied?

For further good practices have a look at our review guidelines.

Edited by Florian Spreckelsen

Merge request reports