Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-78912

Add operator== for SBE tag val pair for ASSERT_EQ

    • Type: Icon: Improvement Improvement
    • Resolution: Won't Fix
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: None
    • Component/s: None
    • None
    • Query Integration
    • QI 2023-07-24
    • None
    • 3
    • None
    • None
    • None
    • None
    • None
    • None

      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.

            Assignee:
            yoonsoo.kim@mongodb.com Yoon Soo Kim (Inactive)
            Reporter:
            yoonsoo.kim@mongodb.com Yoon Soo Kim (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: