mirror of
https://github.com/overleaf/overleaf.git
synced 2024-11-21 20:47:08 -05:00
Merge pull request #15656 from overleaf/bg-group-sso-login-acceptance-tests
add acceptance tests for group sso login GitOrigin-RevId: 046d142ab478e45619b3a76d88eac73a808dfa08
This commit is contained in:
parent
3ff156ea29
commit
3e5273144e
3 changed files with 14 additions and 0 deletions
|
@ -120,6 +120,8 @@ class SAMLInvalidSignatureError extends SAMLAuthenticationError {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
class SAMLInvalidResponseError extends SAMLAuthenticationError {}
|
||||||
|
|
||||||
class SAMLLoginFailureError extends SAMLAuthenticationError {
|
class SAMLLoginFailureError extends SAMLAuthenticationError {
|
||||||
get i18nKey() {
|
get i18nKey() {
|
||||||
return 'saml_login_failure'
|
return 'saml_login_failure'
|
||||||
|
@ -259,6 +261,7 @@ module.exports = {
|
||||||
SAMLGroupSSOLoginIdentityNotFoundError,
|
SAMLGroupSSOLoginIdentityNotFoundError,
|
||||||
SAMLGroupSSODisabledError,
|
SAMLGroupSSODisabledError,
|
||||||
SAMLInvalidSignatureError,
|
SAMLInvalidSignatureError,
|
||||||
|
SAMLInvalidResponseError,
|
||||||
SAMLLoginFailureError,
|
SAMLLoginFailureError,
|
||||||
SLInV2Error,
|
SLInV2Error,
|
||||||
ThirdPartyIdentityExistsError,
|
ThirdPartyIdentityExistsError,
|
||||||
|
|
|
@ -24,6 +24,8 @@ class Subscription {
|
||||||
this.planCode = options.planCode
|
this.planCode = options.planCode
|
||||||
this.recurlySubscription_id = options.recurlySubscription_id
|
this.recurlySubscription_id = options.recurlySubscription_id
|
||||||
this.features = options.features
|
this.features = options.features
|
||||||
|
this.ssoConfig = options.ssoConfig
|
||||||
|
this.groupPolicy = options.groupPolicy
|
||||||
}
|
}
|
||||||
|
|
||||||
ensureExists(callback) {
|
ensureExists(callback) {
|
||||||
|
|
|
@ -40,6 +40,7 @@ class User {
|
||||||
this._id = user._id.toString()
|
this._id = user._id.toString()
|
||||||
this.first_name = user.first_name
|
this.first_name = user.first_name
|
||||||
this.referal_id = user.referal_id
|
this.referal_id = user.referal_id
|
||||||
|
this.enrollment = user.enrollment
|
||||||
}
|
}
|
||||||
|
|
||||||
get(callback) {
|
get(callback) {
|
||||||
|
@ -228,6 +229,14 @@ class User {
|
||||||
UserModel.updateOne({ _id: this.id }, { emails }, callback)
|
UserModel.updateOne({ _id: this.id }, { emails }, callback)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
setEnrollment(enrollment, callback) {
|
||||||
|
UserModel.updateOne({ _id: this.id }, { enrollment }, callback)
|
||||||
|
}
|
||||||
|
|
||||||
|
setSamlIdentifiers(samlIdentifiers, callback) {
|
||||||
|
UserModel.updateOne({ _id: this.id }, { samlIdentifiers }, callback)
|
||||||
|
}
|
||||||
|
|
||||||
logout(callback) {
|
logout(callback) {
|
||||||
this.getCsrfToken(error => {
|
this.getCsrfToken(error => {
|
||||||
if (error != null) {
|
if (error != null) {
|
||||||
|
|
Loading…
Reference in a new issue