meson: inline gtest_test_protocol now that it's always 'gtest'

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21485>
This commit is contained in:
Eric Engestrom 2023-02-23 10:49:37 +00:00 committed by Marge Bot
parent a18f439f52
commit f5d3d1e7ed
23 changed files with 26 additions and 34 deletions

View File

@ -27,14 +27,6 @@ project(
default_options : ['buildtype=debugoptimized', 'b_ndebug=if-release', 'c_std=c11', 'cpp_std=c++17', 'rust_std=2021']
)
# In recent versions, meson can inject some extra arguments to get richer
# results from gtest based tests. Feature was added in 0.55, but requiring
# 0.59.2 to include an important fix. See https://github.com/mesonbuild/meson/pull/9283.
gtest_test_protocol = 'exitcode'
if meson.version().version_compare('>= 0.59.2')
gtest_test_protocol = 'gtest'
endif
cc = meson.get_compiler('c')
cpp = meson.get_compiler('cpp')

View File

@ -121,6 +121,6 @@ if with_tests
link_with : [libasahi_compiler],
),
suite : ['asahi'],
protocol : gtest_test_protocol,
protocol : 'gtest',
)
endif

View File

@ -50,6 +50,6 @@ if with_tests
link_with : [libasahi_layout],
),
suite : ['asahi'],
protocol : gtest_test_protocol,
protocol : 'gtest',
)
endif

View File

@ -89,7 +89,7 @@ if with_tests
link_with : [libasahi_lib],
),
suite : ['asahi'],
protocol : gtest_test_protocol,
protocol : 'gtest',
)
endif

View File

@ -32,7 +32,7 @@ test(
dependencies : [dep_clock, dep_thread, idep_gtest, idep_mesautil],
),
suite : ['compiler', 'glsl'],
protocol : gtest_test_protocol,
protocol : 'gtest',
)
test(
@ -47,7 +47,7 @@ test(
dependencies : [dep_thread, idep_gtest, idep_mesautil],
),
suite : ['compiler', 'glsl'],
protocol : gtest_test_protocol,
protocol : 'gtest',
)
test(
@ -62,7 +62,7 @@ test(
dependencies : [dep_thread, idep_gtest],
),
suite : ['compiler', 'glsl'],
protocol : gtest_test_protocol,
protocol : 'gtest',
)
# Meson can't auto-skip these on cross builds because of the python wrapper

View File

@ -88,7 +88,7 @@ if with_tests
dependencies : [dep_thread, idep_gtest, idep_nir, idep_mesautil],
),
suite : ['compiler', 'spirv'],
protocol : gtest_test_protocol,
protocol : 'gtest',
)
endif

View File

@ -428,7 +428,7 @@ if with_tests
dependencies : [dep_thread, idep_gtest, idep_nir, idep_mesautil],
),
suite : ['compiler', 'nir'],
protocol : gtest_test_protocol,
protocol : 'gtest',
)
test(
@ -453,7 +453,7 @@ if with_tests
suite : ['compiler', 'nir'],
# TODO: Use a negative filter for gtest instead of the expect failure here.
should_fail : meson.get_external_property('xfail', '').contains('load_store_vectorizer'),
protocol : gtest_test_protocol,
protocol : 'gtest',
)
test(

View File

@ -534,7 +534,7 @@ if with_tests
dependencies : [idep_gtest],
),
suite: 'gallium',
protocol : gtest_test_protocol,
protocol : 'gtest',
)
endif

View File

@ -144,6 +144,6 @@ if with_tests
dependencies : [idep_gtest, idep_nir],
),
suite : ['compiler', 'etnaviv'],
protocol : gtest_test_protocol,
protocol : 'gtest',
)
endif

View File

@ -28,5 +28,5 @@ test(
link_with : [libvirgl, libgallium],
),
suite : ['virgl'],
protocol : gtest_test_protocol,
protocol : 'gtest',
)

View File

@ -78,6 +78,6 @@ if with_tests
suite : ['wgl'],
env : wgl_test_env,
depends : [libopengl32],
protocol : gtest_test_protocol,
protocol : 'gtest',
)
endif

View File

@ -94,6 +94,6 @@ if with_tests
dependencies : [idep_gtest],
),
suite: 'gallium',
protocol : gtest_test_protocol,
protocol : 'gtest',
)
endif

View File

@ -50,6 +50,6 @@ if with_shared_glapi
dependencies : [dep_libdrm, dep_glproto, dep_thread, idep_gtest]
),
suite : ['glx'],
protocol : gtest_test_protocol,
protocol : 'gtest',
)
endif

View File

@ -210,6 +210,6 @@ if with_tests
dependencies : [idep_gtest, idep_nir, idep_mesautil, idep_intel_dev],
),
suite : ['intel'],
protocol : gtest_test_protocol,
protocol : 'gtest',
)
endif

View File

@ -171,6 +171,6 @@ if with_tests
cpp_args : '-DIN_UNIT_TEST',
),
suite : ['intel'],
protocol : gtest_test_protocol,
protocol : 'gtest',
)
endif

View File

@ -111,6 +111,6 @@ if with_any_opengl and not with_shared_glapi and with_tests and not with_platfor
dependencies : [idep_gtest, dep_thread],
),
suite : ['mapi'],
protocol : gtest_test_protocol,
protocol : 'gtest',
)
endif

View File

@ -74,7 +74,7 @@ if with_any_opengl and with_tests
dependencies : [dep_thread, idep_gtest, idep_mesautilc11],
),
suite : ['mapi'],
protocol : gtest_test_protocol,
protocol : 'gtest',
)
if with_symbols_check
test(

View File

@ -47,5 +47,5 @@ test(
link_with : [libmesa, libgallium, link_main_test],
),
suite : ['mesa'],
protocol : gtest_test_protocol,
protocol : 'gtest',
)

View File

@ -44,7 +44,7 @@ if dep_dxheaders.found() and host_machine.system() == 'windows'
)
if build_machine.system() == 'windows'
test('clc_compiler_test', clc_compiler_test, timeout: 180, protocol : gtest_test_protocol)
test('clc_compiler_test', clc_compiler_test, timeout: 180, protocol : 'gtest')
endif
endif

View File

@ -185,6 +185,6 @@ if with_tests
link_with : [libpanfrost_bifrost],
),
suite : ['panfrost'],
protocol : gtest_test_protocol,
protocol : 'gtest',
)
endif

View File

@ -142,6 +142,6 @@ if with_tests
dependencies: [idep_gtest, libpanfrost_dep],
),
suite : ['panfrost'],
protocol : gtest_test_protocol,
protocol : 'gtest',
)
endif

View File

@ -52,6 +52,6 @@ if with_tests
link_with : [libpanfrost_shared],
),
suite : ['panfrost'],
protocol : gtest_test_protocol,
protocol : 'gtest',
)
endif

View File

@ -329,7 +329,7 @@ if with_tests
'tests', 'drirc_home'),
'DRIRC_CONFIGDIR=' + join_paths(meson.current_source_dir(),
'tests', 'drirc_configdir')],
protocol : gtest_test_protocol,
protocol : 'gtest',
)
endif
@ -381,7 +381,7 @@ if with_tests
dependencies : [idep_mesautil, idep_gtest],
),
suite : ['util'],
protocol : gtest_test_protocol,
protocol : 'gtest',
timeout : 180,
)