Ocean
Loading...
Searching...
No Matches
TestTransitionHistory.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#pragma once
9
11
13
14namespace Ocean
15{
16
17namespace Test
18{
19
20namespace TestCV
21{
22
23namespace TestDetector
24{
25
26namespace TestBullseyes
27{
28
29/**
30 * This class implements tests for the TransitionHistory class.
31 * @ingroup testcvdetectorbullseyes
32 */
33class OCEAN_TEST_CV_DETECTOR_BULLSEYES_EXPORT TestTransitionHistory
34{
35 public:
36
37 /**
38 * Tests the TransitionHistory functions.
39 * @param testDuration Number of seconds for each test, with range (0, infinity)
40 * @return True, if succeeded
41 */
42 static bool test(const double testDuration);
43
44 /**
45 * Test for TransitionHistory::history1(), history2(), history3(), and push()
46 * @param testDuration The duration in seconds for which this test will be run, must be > 0.0
47 * @param randomGenerator A random generator that will be used to generate test data
48 * @return True, if succeeded
49 */
50 static bool testHistoryAndPush(const double testDuration, RandomGenerator& randomGenerator);
51
52 /**
53 * Test for TransitionHistory::reset()
54 * @param testDuration The duration in seconds for which this test will be run, must be > 0.0
55 * @param randomGenerator A random generator that will be used to generate test data
56 * @return True, if succeeded
57 */
58 static bool testReset(const double testDuration, RandomGenerator& randomGenerator);
59
60 /**
61 * Test for TransitionHistory::isTransitionToBlack()
62 * @param testDuration The duration in seconds for which this test will be run, must be > 0.0
63 * @param randomGenerator A random generator that will be used to generate test data
64 * @return True, if succeeded
65 */
66 static bool testIsTransitionToBlack(const double testDuration, RandomGenerator& randomGenerator);
67
68 /**
69 * Test for TransitionHistory::isTransitionToWhite()
70 * @param testDuration The duration in seconds for which this test will be run, must be > 0.0
71 * @param randomGenerator A random generator that will be used to generate test data
72 * @return True, if succeeded
73 */
74 static bool testIsTransitionToWhite(const double testDuration, RandomGenerator& randomGenerator);
75};
76
77} // namespace TestBullseyes
78
79} // namespace TestDetector
80
81} // namespace TestCV
82
83} // namespace Test
84
85} // namespace Ocean
This class implements a generator for random numbers.
Definition RandomGenerator.h:42
This class implements tests for the TransitionHistory class.
Definition TestTransitionHistory.h:34
static bool testReset(const double testDuration, RandomGenerator &randomGenerator)
Test for TransitionHistory::reset()
static bool test(const double testDuration)
Tests the TransitionHistory functions.
static bool testIsTransitionToWhite(const double testDuration, RandomGenerator &randomGenerator)
Test for TransitionHistory::isTransitionToWhite()
static bool testIsTransitionToBlack(const double testDuration, RandomGenerator &randomGenerator)
Test for TransitionHistory::isTransitionToBlack()
static bool testHistoryAndPush(const double testDuration, RandomGenerator &randomGenerator)
Test for TransitionHistory::history1(), history2(), history3(), and push()
The namespace covering the entire Ocean framework.
Definition Accessor.h:15