From a977e35e0b779f7ebf29688a3e7b29e47fa7910d Mon Sep 17 00:00:00 2001 From: Pedro Olsen Ferreira Date: Tue, 16 Apr 2024 16:53:59 +0100 Subject: [PATCH] Delete stale files (#1945) These aren't included or built anywhere. --- test_common/autotest/autotest.hpp | 38 ----------------- test_common/autotest/test_suite.hpp | 63 ----------------------------- 2 files changed, 101 deletions(-) delete mode 100644 test_common/autotest/autotest.hpp delete mode 100644 test_common/autotest/test_suite.hpp diff --git a/test_common/autotest/autotest.hpp b/test_common/autotest/autotest.hpp deleted file mode 100644 index a3d14dc0..00000000 --- a/test_common/autotest/autotest.hpp +++ /dev/null @@ -1,38 +0,0 @@ -// -// Copyright (c) 2017 The Khronos Group Inc. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// -#ifndef TEST_COMMON_AUTOTEST_AUTOTEST_HPP -#define TEST_COMMON_AUTOTEST_AUTOTEST_HPP - -#include "test_suite.hpp" - -#define STR_JOIN( X, Y ) STR_DO_JOIN( X, Y ) -#define STR_DO_JOIN( X, Y ) STR_DO_JOIN_2(X,Y) -#define STR_DO_JOIN_2( X, Y ) X##Y - - -// How to use AUTO_TEST_CASE macro: -// -// AUTO_TEST_CASE()(cl_device_id device, cl_context context, cl_command_queue queue, int n_elems) -// { -// (test case code...) -// } -// -#define AUTO_TEST_CASE(name) \ - struct name { static int run_test(cl_device_id, cl_context, cl_command_queue, int); }; \ - static autotest::detail::test_case_registration STR_JOIN(name, STR_JOIN(_registration, __LINE__)) (#name, name::run_test); \ - int name::run_test - -#endif //TEST_COMMON_AUTOTEST_AUTOTEST_HPP \ No newline at end of file diff --git a/test_common/autotest/test_suite.hpp b/test_common/autotest/test_suite.hpp deleted file mode 100644 index b831b9e6..00000000 --- a/test_common/autotest/test_suite.hpp +++ /dev/null @@ -1,63 +0,0 @@ -// -// Copyright (c) 2017 The Khronos Group Inc. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. -// -#ifndef TEST_COMMON_AUTOTEST_TEST_SUITE_HPP -#define TEST_COMMON_AUTOTEST_TEST_SUITE_HPP - -#include -#include - -namespace autotest { - -struct test_suite { - test_suite(const std::string& name) - : name(name) - { - - } - - void add(const test_definition& td) - { - test_defs.push_back(td); - } - - // List of test definitions - std::vector test_defs; - // Test suite name - const std::string name; - - static test_suite& global_test_suite() - { - static test_suite global_test_suite("global"); - return global_test_suite; - } -}; - -namespace detail { - -struct test_case_registration -{ - test_case_registration(const std::string& name, - const test_function_pointer ptr) - { - ::autotest::test_suite::global_test_suite().add( - test_definition({ ptr, strdup(name.c_str()) })); - } -}; - -} // end detail namespace -} // end autotest namespace - -#endif // TEST_COMMON_AUTOTEST_TEST_SUITE_HPP