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

Test duration values ​​are now presented in seconds with six digits of precision. Tests without time measurements have been edited. #4435

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

KaganCanSit
Copy link
Contributor

Pull Request: Systematically Time All Test Suites (#4417) - Test duration values ​​are now presented in seconds with six digits of precision. Tests without time measurements have been edited.

Summary

  • Enhanced Time Precision:
    Adjusted the printing of time values to display with 6 digits of precision in seconds. This improvement ensures more accurate and consistent timing information across all tests.

  • Added Time Measurement
    Implemented timing calls for tests that previously did not measure execution time. This update affected several files to achieve full coverage of time measurements across all test
    While considering where to set these timing calls, I explored alternatives like placing the time measurement in the Result object's constructor and destructor. However, given that the Result objects are stored in a vector and altering the existing structure might have unforeseen side effects, I opted to integrate the timing calls in a way that preserves the current architecture.

  • Additional Considerations
    During testing, I observed that time values are not always printed due to the if (m_ns_taken > 0) condition in the std::string Test::Result::result_string() function located in "test.cpp." After careful consideration, I decided to retain this condition, as it appears to function as expected and aligns with the intended logic.

Best regards

Note: I am aware that this change affects a lot of files and their content. However, I have tried to make the impact minimal while remaining true to the existing architecture. If you have any content that you would like to see edited, I would be happy to help you out as much as I can.

@KaganCanSit KaganCanSit changed the title #4417 - Test duration values ​​are now presented in seconds with six digits of precision. Tests without time measurements have been edited. Test duration values ​​are now presented in seconds with six digits of precision. Tests without time measurements have been edited. Nov 14, 2024
@coveralls
Copy link

coveralls commented Nov 14, 2024

Coverage Status

coverage: 91.178% (+0.1%) from 91.072%
when pulling 0972b91 on KaganCanSit:feature_test
into e430f15 on randombit:master.

@KaganCanSit
Copy link
Contributor Author

Even though I checked, I think there are some points I missed. I will review why the checks failed and edit to fix it.

…f precision. Tests without time measurements have been edited.
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