Ocean
Loading...
Searching...
No Matches
TestSegmentUnion.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_SEGMENT_UNION_H
9#define META_OCEAN_TEST_TESTBASE_TEST_SEGMENT_UNION_H
10
13
14namespace Ocean
15{
16
17namespace Test
18{
19
20namespace TestBase
21{
22
23/**
24 * This class implement a test for the SegmentUnion class.
25 * @ingroup testbase
26 */
27class OCEAN_TEST_BASE_EXPORT TestSegmentUnion
28{
29 public:
30
31 /**
32 * Invokes all test for the SegmentUnion class.
33 * @param testDuration Number of seconds for each test, with range (0, infinity)
34 * @param selector Test selector for filtering sub-tests; default runs all tests
35 * @return True, if succeeded
36 */
37 static bool test(const double testDuration, const TestSelector& selector = TestSelector());
38
39 /**
40 * Tests the function determining the size of the union.
41 * @param testDuration Number of seconds for each test, with range (0, infinity)
42 * @return True, if succeeded
43 * @tparam T The data type defining the end points
44 */
45 template <typename T>
46 static bool testUnionSize(const double testDuration);
47
48 /**
49 * Tests the function determining the intersection of the union with a segment.
50 * @param testDuration Number of seconds for each test, with range (0, infinity)
51 * @return True, if succeeded
52 * @tparam T The data type defining the end points
53 */
54 template <typename T>
55 static bool testIntersection(const double testDuration);
56
57 /**
58 * Tests the function determining the maximal gap between segments.
59 * @param testDuration Number of seconds for each test, with range (0, infinity)
60 * @return True, if succeeded
61 * @tparam T The data type defining the end points
62 */
63 template <typename T>
64 static bool testMaximalGap(const double testDuration);
65
66 /**
67 * Tests the bool cast operator.
68 * @return True, if succeeded
69 * @tparam T The data type defining the end points
70 */
71 template <typename T>
72 static bool testBoolCastOperator();
73};
74
75}
76
77}
78
79}
80
81#endif // META_OCEAN_TEST_TESTBASE_TEST_SEGMENT_UNION_H
This class implement a test for the SegmentUnion class.
Definition TestSegmentUnion.h:28
static bool testBoolCastOperator()
Tests the bool cast operator.
static bool testUnionSize(const double testDuration)
Tests the function determining the size of the union.
static bool testIntersection(const double testDuration)
Tests the function determining the intersection of the union with a segment.
static bool testMaximalGap(const double testDuration)
Tests the function determining the maximal gap between segments.
static bool test(const double testDuration, const TestSelector &selector=TestSelector())
Invokes all test for the SegmentUnion class.
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