Skip to content
Snippets Groups Projects
Commit 5d220ba6 authored by Cyril Moineau's avatar Cyril Moineau
Browse files

[GitLabCI] Add first iteration of GitLab CI.

parent f6f1c60c
No related branches found
No related tags found
No related merge requests found
###############################################################################
# Aidge Continious Integration and Continious Deployment #
# #
###############################################################################
stages:
# Analyse code
- static_analysis
# Build Aidge
- build
# Unit test stage
- test
include:
- local: '/.gitlab/ci/_global.gitlab-ci.yml'
- local: '/.gitlab/ci/static_analysis.gitlab-ci.yml'
- local: '/.gitlab/ci/build.gitlab-ci.yml'
- local: '/.gitlab/ci/test.gitlab-ci.yml'
################################################################################
# Centralized definitions of common job parameter values. #
# Parameters with many optional configurations may be in separate files. #
# #
################################################################################
variables:
GIT_SUBMODULE_STRATEGY: recursive
OMP_NUM_THREADS: 4
GIT_SSL_NO_VERIFY: 1
DEBIAN_FRONTEND: noninteractive
build:ubuntu:
stage: build
tags:
- docker
image: n2d2-ci/ubuntu20.04/cpu:latest
script:
- mkdir -p build
- mkdir -p install
- cd build
- cmake -DCMAKE_INSTALL_PREFIX:PATH=../install -DCMAKE_BUILD_TYPE=Debug -DWERROR=ON ..
- make -j4 all install
artifacts:
paths:
- build/
- install/
static_analysis:cpp:
stage: static_analysis
tags:
- static_analysis
allow_failure: true
script:
- cppcheck --enable=all --error-exitcode=-1 src/
static_analysis:python:
stage: static_analysis
tags:
- static_analysis
allow_failure: true
script:
- pip install pylint
- pip install pylint-exit
- pylint --rcfile=.pylintrc aidge_core/ || pylint-exit $?
test:ubuntu_cpp:
stage: test
needs: ["build:ubuntu"]
tags:
- docker
image: n2d2-ci/ubuntu20.04/cpu:latest
script:
- cd build
- ctest --output-on-failure
test:ubuntu_python:
stage: test
needs: ["build:ubuntu"]
tags:
- docker
image: n2d2-ci/ubuntu20.04/cpu:latest
script:
- cd aidge_core
# Run on discovery all tests located in core/unit_tests/python and discard the stdout
# only to show the errors/warnings and the results of the tests
- python3 -m unittest discover -s unit_tests/ -v -b 1> /dev/null
.pylintrc 0 → 100644
This diff is collapsed.
from aidge_core.aidge_core import * # import so generated by PyBind
\ No newline at end of file
"""
Copyright (c) 2023 CEA-List
This program and the accompanying materials are made available under the
terms of the Eclipse Public License 2.0 which is available at
http://www.eclipse.org/legal/epl-2.0.
SPDX-License-Identifier: EPL-2.0
"""
from aidge_core.aidge_core import * # import so generated by PyBind
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