Skip to content

Commit c103c7e

Browse files
committed
[test] Set CLANG_VERSION in support using interpreter
1 parent 79ea71b commit c103c7e

File tree

4 files changed

+8
-1
lines changed

4 files changed

+8
-1
lines changed

.github/workflows/MacOS.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -566,6 +566,7 @@ jobs:
566566
python -m pip install pytest
567567
python -m pip install pytest-xdist
568568
python -m pip install numba
569+
python -m pip install regex
569570
echo ::endgroup::
570571
echo ::group::Run complete test suite
571572
set -o pipefail

.github/workflows/Ubuntu.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -669,6 +669,7 @@ jobs:
669669
python -m uv pip install pytest-xdist
670670
python -m uv pip install numba
671671
python -m uv pip install psutil
672+
python -m uv pip install regex
672673
echo ::endgroup::
673674
echo ::group::Run complete test suite
674675
set -o pipefail

test/support.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
from __future__ import print_function
22
import os, py, sys, subprocess
3+
import regex as re
34

45
currpath = py.path.local(__file__).dirpath()
56

@@ -74,3 +75,7 @@ def setup_make(targetname):
7475
true
7576
#endif\n""") == 1)
7677
IS_CLING = not IS_CLANG_REPL
78+
79+
version_str = cppyy.gbl.Cpp.GetVersion()
80+
match = re.search(r'clang version (\d+)', version_str)
81+
CLANG_VER = int(match.group(1)) if match else None

test/test_cpp11features.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import py, os, sys
22
from pytest import raises, mark
3-
from .support import setup_make, ispypy, IS_CLANG_REPL, IS_LINUX_ARM, IS_MAC, IS_CLING
3+
from .support import setup_make, ispypy, IS_CLANG_REPL, IS_LINUX_ARM, IS_MAC, IS_CLING, CLANG_VER
44

55

66
currpath = py.path.local(__file__).dirpath()

0 commit comments

Comments
 (0)