Ocean
Loading...
Searching...
No Matches
testbase/TestUtilities.h
Go to the documentation of this file.
1/*
2 * Copyright (c) Meta Platforms, Inc. and affiliates.
3 *
4 * This source code is licensed under the MIT license found in the
5 * LICENSE file in the root directory of this source tree.
6 */
7
8#ifndef META_OCEAN_TEST_TESTBASE_TEST_UTILITIES_H
9#define META_OCEAN_TEST_TESTBASE_TEST_UTILITIES_H
10
13
15
16namespace Ocean
17{
18
19namespace Test
20{
21
22namespace TestBase
23{
24
25/**
26 * This class implements utilities tests.
27 * @ingroup testbase
28 */
29class OCEAN_TEST_BASE_EXPORT TestUtilities
30{
31 public:
32
33 /**
34 * Tests the entire utilities functionality.
35 * @param testDuration Number of seconds for each test, with range (0, infinity)
36 * @param selector The selector to filter individual test cases
37 * @return True, if succeeded
38 */
39 static bool test(const double testDuration, const TestSelector& selector = TestSelector());
40
41 /**
42 * Tests the min max function.
43 * @param testDuration Number of seconds for each test, with range (0, infinity)
44 * @return True, if succeeded
45 */
46 static bool testMinmax(const double testDuration);
47
48 /**
49 * Tests the modulo function.
50 * @param testDuration Number of seconds for each test, with range (0, infinity)
51 * @return True, if succeeded
52 */
53 static bool testModulo(const double testDuration);
54
55 /**
56 * Tests the ring distance function.
57 * @param testDuration Number of seconds for each test, with range (0, infinity)
58 * @return True, if succeeded
59 */
60 static bool testRingDistance(const double testDuration);
61
62 /**
63 * Tests the index mirror function.
64 * @param testDuration Number of seconds for each test, with range (0, infinity)
65 * @return True, if succeeded
66 */
67 static bool testMirrorValue(const double testDuration);
68
69 /**
70 * Tests the division by two function.
71 * @param testDuration Number of seconds for each test, with range (0, infinity)
72 * @return True, if succeeded
73 */
74 static bool testDivisionBy2(const double testDuration);
75
76 /**
77 * Tests the power of two function.
78 * @param testDuration Number of seconds for each test, with range (0, infinity)
79 * @return True, if succeeded
80 */
81 static bool testIsPowerOfTwo(const double testDuration);
82};
83
84}
85
86}
87
88}
89
90#endif // META_OCEAN_TEST_TESTBASE_TEST_UTILITIES_H
This class implements utilities tests.
Definition testbase/TestUtilities.h:30
static bool testMirrorValue(const double testDuration)
Tests the index mirror function.
static bool testModulo(const double testDuration)
Tests the modulo function.
static bool testIsPowerOfTwo(const double testDuration)
Tests the power of two function.
static bool testMinmax(const double testDuration)
Tests the min max function.
static bool test(const double testDuration, const TestSelector &selector=TestSelector())
Tests the entire utilities functionality.
static bool testDivisionBy2(const double testDuration)
Tests the division by two function.
static bool testRingDistance(const double testDuration)
Tests the ring distance function.
This class implements a test selector that parses test function strings and determines which tests sh...
Definition TestSelector.h:51
The namespace covering the entire Ocean framework.
Definition Accessor.h:15