Skip to content

PHPLIB-1194: Test log message for non-genuine hosts #1173

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Sep 26, 2023

Conversation

jmikola
Copy link
Member

@jmikola jmikola commented Sep 25, 2023

@jmikola jmikola requested review from GromNaN and alcaeus September 25, 2023 01:24
use function MongoDB\removeLogger;

/** @see https://jira.mongodb.org/browse/DRIVERS-2583 */
class LogNonGenuineHostTest extends TestCase
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is the only relevant class in the PR. Everything else is from #1158.

['mongodb://a.MONGO.COSMOS.AZURE.COM:19555/'],
['mongodb+srv://a.mongo.cosmos.azure.com/'],
['mongodb+srv://A.MONGO.COSMOS.AZURE.COM/'],
// Mixing genuine and nongenuine hosts (unlikely in practice)
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Note: not using named data providers was intentional, since it would have involved a lot of redundancy. I only added comments to notable test cases from my original libmongoc tests.

Copy link
Member

@GromNaN GromNaN left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do these tests run in CI with a CosmoDB server?

@jmikola
Copy link
Member Author

jmikola commented Sep 25, 2023

Do these tests run in CI with a CosmoDB server?

No. These aren't integration tests, as the logic for emitting these log messages is entirely client-side.

@jmikola jmikola force-pushed the phplib-1194 branch 2 times, most recently from ead89cd to 2208186 Compare September 25, 2023 18:57
@jmikola jmikola merged commit 28bcd68 into mongodb:master Sep 26, 2023
@jmikola jmikola deleted the phplib-1194 branch September 26, 2023 13:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants