From f7ca30085b2472c3a925ab25747a8a82e51ff1ed Mon Sep 17 00:00:00 2001
From: Matthias Greuter <matthias.greuter@bmw.de>
Date: Mon, 13 Dec 2021 10:11:01 +0100
Subject: [PATCH] Cleanup bazel target(s)

- Remove testing-suppressions dependency from mantle api test target
- Do not use glob when not needed
- Rename bazel target to test file name (keep it in sync)
---
 MantleAPI/BUILD.bazel | 40 ++++++++++------------------------------
 1 file changed, 10 insertions(+), 30 deletions(-)

diff --git a/MantleAPI/BUILD.bazel b/MantleAPI/BUILD.bazel
index 54b5d534..bad69507 100644
--- a/MantleAPI/BUILD.bazel
+++ b/MantleAPI/BUILD.bazel
@@ -10,31 +10,17 @@
 
 cc_library(
     name = "mantle_api",
-    hdrs = glob([
-        "include/**/*.h",
-    ]),
-    includes = [
-        "include",
-    ],
-    visibility = [
-        "//visibility:public",
-    ],
-    deps = [
-        "@units",
-    ],
+    hdrs = glob(["include/**/*.h"]),
+    includes = ["include"],
+    visibility = ["//visibility:public"],
+    deps = ["@units"],
 )
 
 cc_library(
-    name = "mantle_api_test_utils",
-    hdrs = glob([
-        "test/**/*.h",
-    ]),
-    includes = [
-        "test",
-    ],
-    visibility = [
-        "//visibility:public",
-    ],
+    name = "test_utils",
+    hdrs = ["test/MantleAPI/Test/test_utils.h"],
+    includes = ["test"],
+    visibility = ["//visibility:public"],
     deps = [
         ":mantle_api",
         "@googletest//:gtest_main",
@@ -42,14 +28,8 @@ cc_library(
 )
 
 cc_test(
-    name = "mantle_api_test",
+    name = "interface_test",
     timeout = "short",
     srcs = ["test/interface_test.cpp"],
-    data = [
-        "//Core/Service/Testing:sanitizer-suppressions",
-    ],
-    tags = ["test"],
-    deps = [
-        ":mantle_api_test_utils",
-    ],
+    deps = [":test_utils"],
 )
-- 
GitLab