1
0
Fork 0
mirror of https://github.com/Neargye/magic_enum.git synced 2026-01-10 23:44:29 +00:00

update ci

This commit is contained in:
neargye 2020-07-02 17:37:19 +05:00
parent 98d234fafa
commit 06cb3163f1
2 changed files with 11 additions and 49 deletions

View file

@ -1,5 +1,5 @@
os: linux # Use linux unless specified otherwise.
dist: xenial
dist: bionic
sudo: required
language: cpp
@ -22,39 +22,9 @@ matrix:
addons:
apt:
sources:
- ubuntu-toolchain-r-test
- sourceline: 'deb https://apt.llvm.org/xenial/ llvm-toolchain-xenial-5.0 main'
- sourceline: 'deb https://apt.llvm.org/bionic/ llvm-toolchain-bionic-7 main'
key_url: 'https://apt.llvm.org/llvm-snapshot.gpg.key'
packages:
- g++-7
- clang-5.0
env:
- CXX_COMPILER=clang++-5.0 CC_COMPILER=clang-5.0
- os: linux
compiler: clang++
addons:
apt:
sources:
- ubuntu-toolchain-r-test
- sourceline: 'deb https://apt.llvm.org/xenial/ llvm-toolchain-xenial-6.0 main'
key_url: 'https://apt.llvm.org/llvm-snapshot.gpg.key'
packages:
- g++-7
- clang-6.0
env:
- CXX_COMPILER=clang++-6.0 CC_COMPILER=clang-6.0
- os: linux
compiler: clang++
addons:
apt:
sources:
- ubuntu-toolchain-r-test
- sourceline: 'deb https://apt.llvm.org/xenial/ llvm-toolchain-xenial-7 main'
key_url: 'https://apt.llvm.org/llvm-snapshot.gpg.key'
packages:
- g++-7
- clang-7
env:
- CXX_COMPILER=clang++-7 CC_COMPILER=clang-7
@ -64,11 +34,9 @@ matrix:
addons:
apt:
sources:
- ubuntu-toolchain-r-test
- sourceline: 'deb https://apt.llvm.org/xenial/ llvm-toolchain-xenial-8 main'
- sourceline: 'deb https://apt.llvm.org/bionic/ llvm-toolchain-bionic-8 main'
key_url: 'https://apt.llvm.org/llvm-snapshot.gpg.key'
packages:
- g++-7
- clang-8
env:
- CXX_COMPILER=clang++-8 CC_COMPILER=clang-8
@ -78,11 +46,9 @@ matrix:
addons:
apt:
sources:
- ubuntu-toolchain-r-test
- sourceline: 'deb https://apt.llvm.org/xenial/ llvm-toolchain-xenial-9 main'
- sourceline: 'deb https://apt.llvm.org/bionic/ llvm-toolchain-bionic-9 main'
key_url: 'https://apt.llvm.org/llvm-snapshot.gpg.key'
packages:
- g++-7
- clang-9
env:
- CXX_COMPILER=clang++-9 CC_COMPILER=clang-9
@ -92,11 +58,9 @@ matrix:
addons:
apt:
sources:
- ubuntu-toolchain-r-test
- sourceline: 'deb https://apt.llvm.org/xenial/ llvm-toolchain-xenial-10 main'
- sourceline: 'deb https://apt.llvm.org/bionic/ llvm-toolchain-bionic-10 main'
key_url: 'https://apt.llvm.org/llvm-snapshot.gpg.key'
packages:
- g++-7
- clang-10
env:
- CXX_COMPILER=clang++-10 CC_COMPILER=clang-10
@ -113,6 +77,12 @@ matrix:
env:
- CXX_COMPILER=clang++ CC_COMPILER=clang
- os: osx
compiler: clang++
osx_image: xcode12
env:
- CXX_COMPILER=clang++ CC_COMPILER=clang
install:
- export CC=${CC_COMPILER}
- export CXX=${CXX_COMPILER}

View file

@ -631,11 +631,7 @@ TEST_CASE("extrema") {
REQUIRE(magic_enum::detail::reflected_min_v<Directions> == MAGIC_ENUM_RANGE_MIN);
REQUIRE(magic_enum::detail::min_v<Directions> == -120);
#if defined(__clang__) && __clang_major__ == 5
// clang-5 linker fail: undefined reference to `magic_enum::enum_range<number>::min'.
#else
REQUIRE(magic_enum::enum_range<number>::min == 100);
#endif
REQUIRE(magic_enum::detail::reflected_min_v<number> == 100);
REQUIRE(magic_enum::detail::min_v<number> == 100);
}
@ -657,11 +653,7 @@ TEST_CASE("extrema") {
REQUIRE(magic_enum::detail::reflected_max_v<Directions> == MAGIC_ENUM_RANGE_MAX);
REQUIRE(magic_enum::detail::max_v<Directions> == 120);
#if defined(__clang__) && __clang_major__ == 5
// clang-5 linker fail: undefined reference to `magic_enum::enum_range<number>::max'.
#else
REQUIRE(magic_enum::enum_range<number>::max == 300);
#endif
REQUIRE(magic_enum::detail::reflected_max_v<number> == 300);
REQUIRE(magic_enum::detail::max_v<number> == 300);
}