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

PMM-12219: Unable to add MongoDB due to "+" in password pmm v2 #903

Merged
merged 6 commits into from
Dec 4, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 12 additions & 3 deletions tests/metrics/verifyMongoDB_test.js
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,16 @@ const telemetry = {

BeforeSuite(async ({ I }) => {
await I.mongoConnect(connection);
await I.mongoAddUser(mongo_test_user.username, mongo_test_user.password);
await I.mongoAddUser(mongo_test_user.username, mongo_test_user.password, [
{ role: 'explainRole', db: 'admin' },
{ role: 'clusterMonitor', db: 'admin' },
{ role: 'read', db: 'local' },
{ db: 'admin', role: 'readWrite', collection: '' },
{ db: 'admin', role: 'backup' },
{ db: 'admin', role: 'clusterMonitor' },
{ db: 'admin', role: 'restore' },
{ db: 'admin', role: 'pbmAnyAction' },
]);

// check that rs101 docker container exists
const dockerCheck = await I.verifyCommand('docker ps | grep rs101');
Expand All @@ -47,11 +56,11 @@ AfterSuite(async ({ I }) => {
await I.mongoDisconnect();
});

Scenario.skip(
Scenario(
'PMM-T1241 - Verify add mongoDB service with "+" in user password @not-ui-pipeline @mongodb-exporter',
async ({ I, grafanaAPI }) => {
await I.say(
await I.verifyCommand(`pmm-admin add mongodb --port=${connection.port} --password=${mongo_test_user.password} --username='${mongo_test_user.username}' --service-name=${mongodb_service_name}`),
await I.verifyCommand(`pmm-admin add mongodb --port=${connection.port} --password="${mongo_test_user.password}" --username="${mongo_test_user.username}" --service-name=${mongodb_service_name}`),
);

await grafanaAPI.waitForMetric('mongodb_up', { type: 'service_name', value: mongodb_service_name }, 65);
Expand Down
Loading