add more jobs to test stage

This commit is contained in:
rafay.khan 2022-10-04 12:48:08 +03:00
parent 35ece3fa5c
commit 70001348f0
No known key found for this signature in database
GPG Key ID: 29C7F47B06CEC974

View File

@ -31,7 +31,7 @@ install:
before_script:
- npm test
# after successful tests, publish binaries if specified in commit message
- ./scripts/publish.sh --toolset=${TOOLSET:-} --debug=$([ "${BUILDTYPE}" == 'debug' ] && echo "true" || echo "false")
# - ./scripts/publish.sh --toolset=${TOOLSET:-} --debug=$([ "${BUILDTYPE}" == 'debug' ] && echo "true" || echo "false")
# We set 'script' here to an empty array to prevent this section from automatically running 'npm test'
# The reason we do this is mentioned above in the comment about the 'before_script' stage.
@ -41,12 +41,157 @@ script:
# Build all binaries and if all succeed then publish based on the commit message
jobs:
include:
# linux publishable node v8
- os: linux
env: BUILDTYPE=release
node_js: 8
# linux publishable node v8/debug
- os: linux
env: BUILDTYPE=debug
node_js: 8
# linux publishable node v10
- os: linux
env: BUILDTYPE=release
node_js: 10
# linux publishable node v10/debug
- os: linux
env: BUILDTYPE=debug
node_js: 10
# linux publishable node v12
- os: linux
env: BUILDTYPE=release
node_js: 12
# linux publishable node v14/debug
- os: linux
env: BUILDTYPE=debug
node_js: 14
# linux publishable node v14
- os: linux
env: BUILDTYPE=release
node_js: 14
# linux publishable node v12/debug
- os: linux
env: BUILDTYPE=debug
node_js: 12
# linux publishable node v16
- os: linux
env: BUILDTYPE=release
node_js: 16
# linux publishable node v16/debug
- os: linux
env: BUILDTYPE=debug
node_js: 16
# osx publishable node v8
- os: osx
osx_image: xcode11
env: BUILDTYPE=release
node_js: 8
# osx publishable node v10
- os: osx
osx_image: xcode11
env: BUILDTYPE=release
node_js: 10
# osx publishable node v12
- os: osx
osx_image: xcode11
env: BUILDTYPE=release
node_js: 12
# osx publishable node v14
- os: osx
osx_image: xcode11
env: BUILDTYPE=release
node_js: 14
# osx publishable node v16
- os: osx
osx_image: xcode11
env: BUILDTYPE=release
node_js: 16
# Sanitizer build node v10/Debug
- os: linux
env: BUILDTYPE=debug TOOLSET=asan
node_js: 10
sudo: required
# Overrides `install` to set up custom asan flags
install:
- ./scripts/setup.sh --config local.env
# put mason and clang++ on PATH
- source local.env
# Note: to build without stopping on errors remove the -fno-sanitize-recover=all flag
# You might want to do this if there are multiple errors and you want to see them all before fixing
- export CXXFLAGS="${MASON_SANITIZE_CXXFLAGS} -fno-sanitize-recover=all"
- export LDFLAGS="${MASON_SANITIZE_LDFLAGS}"
- make ${BUILDTYPE}
# Overrides `script` to disable asan LD_PRELOAD before publishing
before_script:
- export LD_PRELOAD=${MASON_LLVM_RT_PRELOAD}
- export ASAN_OPTIONS=fast_unwind_on_malloc=0:${ASAN_OPTIONS}
- npm test
- unset LD_PRELOAD
# after successful tests, publish binaries if specified in commit message
# - ./scripts/publish.sh --toolset=${TOOLSET:-} --debug=$([ "${BUILDTYPE}" == 'debug' ] && echo "true" || echo "false")
script:
- true
# g++ build (default builds all use clang++)
- os: linux
# Note: -fext-numeric-literals is needed to workaround gcc bug:
# boost/math/constants/constants.hpp:269:3: error: unable to find numeric literal operator 'operatorQ'
env: BUILDTYPE=debug CXX="g++-9" CC="gcc-9" CXXFLAGS="-fext-numeric-literals"
node_js: 10
addons:
apt:
sources:
- sourceline: "ppa:ubuntu-toolchain-r/test"
packages:
- libstdc++-10-dev
- g++-9
# Overrides `install` to avoid initializing clang toolchain
install:
- make ${BUILDTYPE}
# Overrides `script` to disable publishing
before_script:
- npm test
# Coverage build
- os: linux
env: BUILDTYPE=debug CXXFLAGS="--coverage" LDFLAGS="--coverage"
node_js: 10
# Overrides `script` to publish coverage data to codecov
before_script:
- npm test
- mason install llvm-cov ${MASON_LLVM_RELEASE}
- mason link llvm-cov ${MASON_LLVM_RELEASE}
- which llvm-cov
- pip install --user codecov
- codecov --gcov-exec "llvm-cov gcov"
# avoid double-run of npm test
script:
- true
# Clang format build
- os: linux
# can be generic since we don't need nodejs to run formatting
language: generic
env: CLANG_FORMAT
# Overrides `install` to avoid initializing clang toolchain
install:
# Run the clang-format script. Any code formatting changes
# will trigger the build to fail (idea here is to get us to pay attention
# and get in the habit of running these locally before committing)
- make format
# Overrides `script`, no need to run tests
before_script:
# Clang tidy build
# - os: linux
# env: CLANG_TIDY
# node_js: 10
# # Overrides `install` to avoid initializing clang toolchain
# install:
# # First run the clang-tidy target
# # Any code formatting fixes automatically applied by clang-tidy
# # will trigger the build to fail (idea here is to get us to pay attention
# # and get in the habit of running these locally before committing)
# - make tidy
# # Overrides `script`, no need to run tests
# before_script:
- stage: publish
script: echo "publishing"
env: BUILDTYPE=release
node_js: 16