[CXX-1340] Write integration tests for client metadata handshake feature Created: 15/May/17  Updated: 27/Feb/18  Resolved: 11/Aug/17

Status: Closed
Project: C++ Driver
Component/s: Testing
Affects Version/s: None
Fix Version/s: 3.2.0-rc0

Type: Task Priority: Minor - P4
Reporter: J Rassi Assignee: Patrick Freed
Resolution: Done Votes: 0
Labels: neweng
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Gantt Dependency
has to be done after CDRIVER-2218 Only topology scanner performs MongoD... Closed
Related
is related to CXX-1268 Audit driver against Handshake Spec Closed

 Description   

The driver is currently lacking test coverage of the client metadata handshake feature (which the driver has integration logic for, albeit minimal). We should write two smoke tests for this feature, one which uses mongocxx::pool and one which uses mongocxx::client.

The test should perform the following steps:

  • Connect to the server with a URI specifying a custom app name ("mongodb://<hostname>/?appName=xyz").
  • Run the currentOp command.
  • Verify that the currentOp entry associated with the current connection has the expected client metadata. The test should validate at least 1) the correct app name, 2) the correct driver name, 3) the correct mongocxx portion of the driver version, and 4) presence of the "os.type" field.

The assertions for specific client metadata fields other than app name should be skipped on server versions 3.4 and earlier, since SERVER-29075 is not implemented for those versions.



 Comments   
Comment by Andrew Morrow (Inactive) [ 27/Feb/18 ]

This landed in commit 395b5f198eb0240ead79d0b17ccd61eabc059628

Generated at Wed Feb 07 22:02:19 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.