Skip to content
Snippets Groups Projects
Commit 5021f28c authored by Riccardo Boero's avatar Riccardo Boero :innocent:
Browse files

Integration of test into CI/CD worflow

parent 07be2c6e
No related branches found
No related tags found
No related merge requests found
image: julia:latest image: julia:latest
stages: stages:
- test # New stage for running tests
- documentation - documentation
- deploy - deploy
# Test stage for running unit tests with Docker
test:
stage: test
services:
- docker:dind # Docker-in-Docker service to allow Docker commands in your job
variables:
JULIA_PROJECT: "." # Ensure that Julia uses the project environment
before_script:
- julia -e 'using Pkg; Pkg.instantiate()' # Install required packages
script:
- julia --project=. -e 'using Test; include("test/runtest.jl")' # Run the tests
only:
- main
tags:
- docker # Optional: tag for specific runners that support Docker
# Documentation stage
build documentation: build documentation:
stage: documentation stage: documentation
script: script:
...@@ -16,6 +34,7 @@ build documentation: ...@@ -16,6 +34,7 @@ build documentation:
only: only:
- main - main
# Deploy stage for GitLab Pages
pages: pages:
stage: deploy stage: deploy
script: script:
...@@ -24,4 +43,4 @@ pages: ...@@ -24,4 +43,4 @@ pages:
paths: paths:
- public - public
only: only:
- main - main
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment