diff --git a/services/web/test/acceptance/src/helpers/Subscription.js b/services/web/test/acceptance/src/helpers/Subscription.js index e656dba856..76544a07f6 100644 --- a/services/web/test/acceptance/src/helpers/Subscription.js +++ b/services/web/test/acceptance/src/helpers/Subscription.js @@ -91,6 +91,21 @@ class Subscription { ) } + setValidatedSSO(callback) { + db.subscriptions.findOne({ _id: new ObjectId(this._id) }, (error, doc) => { + if (error) { + return callback(error) + } + const ssoConfigId = doc.ssoConfig + + db.ssoConfigs.findOneAndUpdate( + { _id: ssoConfigId }, + { $set: { validated: true } }, + callback + ) + }) + } + setValidatedAndEnabledSSO(callback) { db.subscriptions.findOne({ _id: new ObjectId(this._id) }, (error, doc) => { if (error) {