go-grpc-middleware icon indicating copy to clipboard operation
go-grpc-middleware copied to clipboard

Introduce Mocking of time dependent tests

Open yashrsharma44 opened this issue 4 years ago • 1 comments

Currently, some tests such as retry logic use real-time based tests, in which the tests pass/fails, depending on the time taken by the local computer to run that logic, and then check if the time-bound is valid or not. However, on configuring the tests on Github Actions, it is seen that the tests take much longer to execute which creates unnecessary long time to execute, resulting in some tests failing due to the machine taking a long time to execute.

A Solution would be to mock the time clock used in the tests with a mocked time clock, which would make sure that the tests don't fail due to the differences in time taken for execution.

yashrsharma44 avatar Oct 03 '20 14:10 yashrsharma44

Do you have any specific tests in mind?

aboryslawski avatar Oct 06 '23 08:10 aboryslawski