Debian Codegraph @

offload/unittests/Conformance/include/mathtest/TestConfig.hpp

raw
1 //===----------------------------------------------------------------------===//
2 //
3 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4 // See https://llvm.org/LICENSE.txt for license information.
5 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6 //
7 //===----------------------------------------------------------------------===//
8 ///
9 /// \file
10 /// This file contains the definition of the TestConfig struct and declares the
11 /// functions for retrieving the set of all and default test configurations.
12 ///
13 //===----------------------------------------------------------------------===//
14
15 #ifndef MATHTEST_TESTCONFIG_HPP
16 #define MATHTEST_TESTCONFIG_HPP
17
18 #include "llvm/ADT/SmallVector.h"
19
20 #include <string>
21
22 namespace mathtest {
23
24 struct TestConfig {
25 std::string Provider;
26 std::string Platform;
27
28 [[nodiscard]] bool operator==(const TestConfig &RHS) const noexcept {
29 return Provider == RHS.Provider && Platform == RHS.Platform;
30 }
31 };
32
33 [[nodiscard]] const llvm::SmallVector<TestConfig, 4> &getAllTestConfigs();
34
35 [[nodiscard]] const llvm::SmallVector<TestConfig, 4> &getDefaultTestConfigs();
36 } // namespace mathtest
37
38 #endif // MATHTEST_TESTCONFIG_HPP