[SERVER-78912] Add operator== for SBE tag val pair for ASSERT_EQ Created: 12/Jul/23  Updated: 18/Jul/23  Resolved: 18/Jul/23

Status: Closed
Project: Core Server
Component/s: None
Affects Version/s: None
Fix Version/s: None

Type: Improvement Priority: Major - P3
Reporter: Yoon Soo Kim Assignee: Yoon Soo Kim
Resolution: Won't Fix Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Assigned Teams:
Query Integration
Sprint: QI 2023-07-24
Participants:

 Description   

ASSERT_EQ macro function has the capability to print out additional message when assertion fails like...

ASSERT_EQ(...) << "message";

The current implementation of assertValuesEqual makes it hard to print out additional information and in result, it's a bit hard to debug using log messages and it would take longer time to debug.

It would be beneficial to have assertValuesEqual's failure log print out additional info to help unittest debugging more quickly. For example, we could do

ASSERT_SBE_VALUES_EQUAL(...) << "message";

And also ASSERT_SBE_VALUES_LT, ASSERT_SBE_VALUES_GT and etc.

It would be great to modify existing test cases using the new functionality so that we can make good examples of unittests.


Generated at Thu Feb 08 06:39:36 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.