Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
sql: deflake TestStatusAPIStatements and TestStatusAPICombinedStatements
Fixes: cockroachdb#69557 As mentioned in cockroachdb#69533, we have a race condition in tests where we request statements stats with start=now. In these tests we expect to see no results, but because in-memory stats have the aggregated_ts field set on iterator return, depending on the time the test is run we might see results returned. For example, suppose we insert stats at 15:45. If we then request stats at 16:00, requesting only stats aggregated after or at the current time, i.e. start=16:00, the aggregated_ts for in-memory stats will be set to 16:00 and thus we will see results returned. To deflake these tests, we stub the aggregated_ts field to a predetermined value. Release justification: non-production code changes Release note: None
- Loading branch information