diff --git a/tests/metrics/verifyMongoDB_test.js b/tests/metrics/verifyMongoDB_test.js index 7a2384af5..ec5de6b81 100644 --- a/tests/metrics/verifyMongoDB_test.js +++ b/tests/metrics/verifyMongoDB_test.js @@ -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'); @@ -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);