Skip to content
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

chore: bump the major version we run unit tests on in ci #6378

Merged
merged 1 commit into from
Oct 18, 2024

Conversation

lerouxb
Copy link
Contributor

@lerouxb lerouxb commented Oct 18, 2024

We were running unit tests on 6.0.x in CI and whatever mongodb-runner uses by default locally.

@lerouxb lerouxb force-pushed the bump-unit-test-mongodb-version branch from 5ee7063 to fc55a01 Compare October 18, 2024 10:20
@@ -2,7 +2,7 @@

set -e

export MONGODB_DEFAULT_VERSION=6.0.x
export MONGODB_DEFAULT_VERSION=7.0.x
Copy link
Contributor Author

@lerouxb lerouxb Oct 18, 2024

Choose a reason for hiding this comment

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

I'm thinking we should probably not set this here and use it in print-compass-env.js and then somehow rather fill in a default if nothing is set in the compass tests. That would be the only way to have a consistent default locally and in CI because we don't use this file when just doing npm test locally.

@@ -252,8 +252,10 @@ describe('connectMongoClient', function () {
expect(error).to.be.instanceOf(Error);

// propagates the tunnel error
expect(error.message).to.match(
/(All configured authentication methods failed|ENOTFOUND compass-tests\.fakehost\.localhost)/
// NOTE: this heavily depends on which server version we're running on
Copy link
Contributor

Choose a reason for hiding this comment

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

do we have to test for a specific message? can't we just confirm an error?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I don't know. I didn't write the original test and I don't want to unnecessarily change the intention.

Copy link
Contributor

@paula-stacho paula-stacho Oct 18, 2024

Choose a reason for hiding this comment

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

or, if we want to test the propagation, is there a way to mock the server error?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yes, but this file is an integration test, not a unit test.

@lerouxb lerouxb merged commit 7d6b939 into main Oct 18, 2024
22 of 23 checks passed
@lerouxb lerouxb deleted the bump-unit-test-mongodb-version branch October 18, 2024 14:17
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