summaryrefslogtreecommitdiff
path: root/src/util
diff options
context:
space:
mode:
authorDylan Baker <dylan@pnwbakers.com>2017-12-11 16:13:31 -0800
committerDylan Baker <dylan@pnwbakers.com>2018-01-11 15:40:02 -0800
commit4ccb9816737945159289527322e759d92bf7a4d6 (patch)
tree5f4cc22fa3d962cfde826599e5a95e26904bdc8d /src/util
parent8e981eb2b7099849c7b74d855afb0c65f92227e8 (diff)
meson: Use consistent style for tests
Don't use intermediate variables, use consistent whitespace. Acked-by: Eric Engestrom <eric.engestrom@imgtec.com> Signed-off-by: Dylan Baker <dylan.c.baker@intel.com>
Diffstat (limited to 'src/util')
-rw-r--r--src/util/meson.build49
-rw-r--r--src/util/tests/hash_table/meson.build16
-rw-r--r--src/util/tests/string_buffer/meson.build17
3 files changed, 45 insertions, 37 deletions
diff --git a/src/util/meson.build b/src/util/meson.build
index 225593f5d3..fa591c92e5 100644
--- a/src/util/meson.build
+++ b/src/util/meson.build
@@ -118,34 +118,39 @@ libxmlconfig = static_library(
)
if with_tests
- u_atomic_test = executable(
- 'u_atomic_test',
- files('u_atomic_test.c'),
- include_directories : inc_common,
- link_with : libmesa_util,
- c_args : [c_msvc_compat_args],
+ test(
+ 'u_atomic',
+ executable(
+ 'u_atomic_test',
+ files('u_atomic_test.c'),
+ include_directories : inc_common,
+ link_with : libmesa_util,
+ c_args : [c_msvc_compat_args],
+ )
)
- roundeven_test = executable(
- 'roundeven_test',
- files('roundeven_test.c'),
- include_directories : inc_common,
- c_args : [c_msvc_compat_args],
- dependencies : [dep_m],
+ test(
+ 'roundeven',
+ executable(
+ 'roundeven_test',
+ files('roundeven_test.c'),
+ include_directories : inc_common,
+ c_args : [c_msvc_compat_args],
+ dependencies : [dep_m],
+ )
)
- mesa_sha1_test = executable(
- 'mesa-sha1_test',
- files('mesa-sha1_test.c'),
- include_directories : inc_common,
- link_with : libmesa_util,
- c_args : [c_msvc_compat_args],
+ test(
+ 'mesa-sha1',
+ executable(
+ 'mesa-sha1_test',
+ files('mesa-sha1_test.c'),
+ include_directories : inc_common,
+ link_with : libmesa_util,
+ c_args : [c_msvc_compat_args],
+ )
)
- test('u_atomic', u_atomic_test)
- test('roundeven', roundeven_test)
- test('mesa-sha1', mesa_sha1_test)
-
subdir('tests/hash_table')
subdir('tests/string_buffer')
endif
diff --git a/src/util/tests/hash_table/meson.build b/src/util/tests/hash_table/meson.build
index 43d8f43a83..4bbc5100ea 100644
--- a/src/util/tests/hash_table/meson.build
+++ b/src/util/tests/hash_table/meson.build
@@ -21,12 +21,14 @@
foreach t : ['clear', 'collision', 'delete_and_lookup', 'delete_management',
'destroy_callback', 'insert_and_lookup', 'insert_many',
'null_destroy', 'random_entry', 'remove_null', 'replacement']
- _test = executable(
- '@0@_test'.format(t),
- files('@0@.c'.format(t)),
- dependencies : [dep_thread, dep_dl],
- include_directories : [inc_include, inc_util],
- link_with : libmesa_util,
+ test(
+ t,
+ executable(
+ '@0@_test'.format(t),
+ files('@0@.c'.format(t)),
+ dependencies : [dep_thread, dep_dl],
+ include_directories : [inc_include, inc_util],
+ link_with : libmesa_util,
+ )
)
- test(t, _test)
endforeach
diff --git a/src/util/tests/string_buffer/meson.build b/src/util/tests/string_buffer/meson.build
index 14dbebca7d..9f42e3550a 100644
--- a/src/util/tests/string_buffer/meson.build
+++ b/src/util/tests/string_buffer/meson.build
@@ -18,12 +18,13 @@
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
# SOFTWARE.
-string_buffer_test = executable(
- 'string_buffer_test',
- 'string_buffer_test.cpp',
- dependencies : [dep_thread, dep_dl, idep_gtest],
- include_directories : inc_common,
- link_with : [libmesa_util],
+test(
+ 'string_buffer',
+ executable(
+ 'string_buffer_test',
+ 'string_buffer_test.cpp',
+ dependencies : [dep_thread, dep_dl, idep_gtest],
+ include_directories : inc_common,
+ link_with : [libmesa_util],
+ )
)
-
-test('string_buffer', string_buffer_test)