Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add time utility classes + UT #7452

Merged
merged 5 commits into from
Oct 14, 2020

Conversation

Nir-Az
Copy link
Collaborator

@Nir-Az Nir-Az commented Sep 30, 2020

  • Add a space for common utility classes.
  • Take timer helper functions from rendering.h , refactor + add functionality and place on timer.h utility file
  • Replace all time functions usage with new classes
  • Add unit tests for 3 new classes

common/utilities/timer.h Outdated Show resolved Hide resolved
common/utilities/timer.h Outdated Show resolved Hide resolved
common/utilities/timer.h Outdated Show resolved Hide resolved
common/utilities/timer.h Outdated Show resolved Hide resolved
common/utilities/timer.h Outdated Show resolved Hide resolved
common/utilities/timer.h Outdated Show resolved Hide resolved
common/utilities/timer.h Outdated Show resolved Hide resolved
@Nir-Az Nir-Az force-pushed the Add_timer_class_to_new_file branch from e224d4e to 97fda0e Compare October 5, 2020 06:35
@Nir-Az Nir-Az force-pushed the Add_timer_class_to_new_file branch from 97fda0e to 8cd5215 Compare October 5, 2020 07:24
@Nir-Az Nir-Az changed the title Add timer utility class + UT Add time utility classes + UT Oct 7, 2020
common/utilities/timer.h Outdated Show resolved Hide resolved
@Nir-Az Nir-Az force-pushed the Add_timer_class_to_new_file branch from 9ad2133 to c2e641c Compare October 13, 2020 12:42
@@ -31,20 +34,25 @@ TEST_CASE( "timer", "[Timer]" )
t.start();
CHECK_FALSE(t.has_expired());

std::this_thread::sleep_for(std::chrono::milliseconds(500));
std::this_thread::sleep_for(TEST_DELTA_TIME - std::chrono::milliseconds(400));
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

May not work if TEST_DELTA_TIME is < 400ms

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Replaced with TEST_DELTA_TIME / 2

@maloel maloel merged commit 405772c into IntelRealSense:development Oct 14, 2020
@Nir-Az Nir-Az deleted the Add_timer_class_to_new_file branch July 27, 2021 12:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants