Uploaded image for project: 'Drivers'
  1. Drivers
  2. DRIVERS-2382

Update CSE unified tests expectResult: null

    • Type: Icon: Improvement Improvement
    • Resolution: Unresolved
    • Priority: Icon: Unknown Unknown
    • None
    • Component/s: Client Side Encryption
    • None
    • $i18n.getText("admin.common.words.hide")
      Key Status/Resolution FixVersion
      CDRIVER-4423 Fixed 1.23.0
      CXX-2541 Backlog
      CSHARP-4243 Fixed 2.17.0
      GODRIVER-2485 Fixed 1.11.0
      JAVA-4670 Done
      NODE-4390 Fixed 4.9.0
      MOTOR-990 Duplicate
      PYTHON-3344 Duplicate
      PHPLIB-907 Fixed 1.15.0
      RUBY-3045 Fixed 2.19.0
      RUST-1397 Duplicate
      SWIFT-1596 Duplicate
      $i18n.getText("admin.common.words.show")
      #scriptField, #scriptField *{ border: 1px solid black; } #scriptField{ border-collapse: collapse; } #scriptField td { text-align: center; /* Center-align text in table cells */ } #scriptField td.key { text-align: left; /* Left-align text in the Key column */ } #scriptField a { text-decoration: none; /* Remove underlines from links */ border: none; /* Remove border from links */ } /* Add green background color to cells with FixVersion */ #scriptField td.hasFixVersion { background-color: #00FF00; /* Green color code */ } /* Center-align the first row headers */ #scriptField th { text-align: center; } Key Status/Resolution FixVersion CDRIVER-4423 Fixed 1.23.0 CXX-2541 Backlog CSHARP-4243 Fixed 2.17.0 GODRIVER-2485 Fixed 1.11.0 JAVA-4670 Done NODE-4390 Fixed 4.9.0 MOTOR-990 Duplicate PYTHON-3344 Duplicate PHPLIB-907 Fixed 1.15.0 RUBY-3045 Fixed 2.19.0 RUST-1397 Duplicate SWIFT-1596 Duplicate

      Summary

      The current tests users expectResult: null however, it should use {"$$unsetOrMatches": null}.

      $$unsetOrMatches:

      This operator can be used anywhere a matched value is expected (including expectResult), excluding an array element because Arrays Must Contain the Same Number of Elements. The test runner MUST assert that the actual value either does not exist or matches the expected value. Matching the expected value MUST use the standard rules in Evaluating Matches, which means that it may contain special operators.

      This is because its testing the absence of a result and comparing against a Bson Null.

      Motivation

      Keeps the test runner to spec.

      Is this ticket only for tests?

      Yes

            Assignee:
            ross@mongodb.com Ross Lawley
            Reporter:
            ross@mongodb.com Ross Lawley
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated: