mirror of
https://github.com/overleaf/overleaf.git
synced 2024-11-14 20:40:17 -05:00
Merge pull request #20062 from overleaf/ab-saas-authentication-module-renaming
[web] Rename overleaf-integration module to saas-authentication GitOrigin-RevId: 7d69e06a19da9855fa9a0962114ad97b45ad8875
This commit is contained in:
parent
0e71084600
commit
4997b7f1ee
11 changed files with 16 additions and 19 deletions
|
@ -28,7 +28,7 @@ make test
|
|||
|
||||
To run both unit and acceptance tests for a module run:
|
||||
```
|
||||
make test_module MODULE=overleaf-integration
|
||||
make test_module MODULE=saas-authentication
|
||||
```
|
||||
|
||||
### Unit Tests
|
||||
|
@ -51,12 +51,12 @@ make test_unit MOCHA_GREP='AuthorizationManager'
|
|||
|
||||
To run only the unit tests for a single module do:
|
||||
```
|
||||
make test_unit_module MODULE=overleaf-integration
|
||||
make test_unit_module MODULE=saas-authentication
|
||||
```
|
||||
|
||||
Module tests can also use a MOCHA_GREP argument:
|
||||
```
|
||||
make test_unit_module MODULE=overleaf-integration MOCHA_GREP=SSO
|
||||
make test_unit_module MODULE=saas-authentication MOCHA_GREP=SSO
|
||||
```
|
||||
|
||||
### Acceptance Tests
|
||||
|
@ -87,12 +87,12 @@ make test_acceptance_run MOCHA_GREP='AuthorizationManager'
|
|||
|
||||
To run only the acceptance tests for a single module do:
|
||||
```
|
||||
make test_acceptance_module MODULE=overleaf-integration
|
||||
make test_acceptance_module MODULE=saas-authentication
|
||||
```
|
||||
|
||||
Module tests can also use a MOCHA_GREP argument:
|
||||
```
|
||||
make test_acceptance_module MODULE=overleaf-integration MOCHA_GREP=SSO
|
||||
make test_acceptance_module MODULE=saas-authentication MOCHA_GREP=SSO
|
||||
```
|
||||
|
||||
Routes
|
||||
|
|
|
@ -68,7 +68,7 @@ const TokenGenerator = {
|
|||
function (cb) {
|
||||
const token = TokenGenerator.readOnlyToken()
|
||||
|
||||
if (!Features.hasFeature('overleaf-integration')) {
|
||||
if (!Features.hasFeature('saas')) {
|
||||
return cb(null, token)
|
||||
}
|
||||
|
||||
|
|
|
@ -69,8 +69,6 @@ const Features = {
|
|||
case 'affiliations':
|
||||
case 'analytics':
|
||||
return Boolean(_.get(Settings, ['apis', 'v1', 'url']))
|
||||
case 'overleaf-integration':
|
||||
return Boolean(Settings.overleaf)
|
||||
case 'references':
|
||||
return Boolean(_.get(Settings, ['apis', 'references', 'url']))
|
||||
case 'saml':
|
||||
|
|
|
@ -156,7 +156,7 @@
|
|||
@import 'modules/admin-panel.less';
|
||||
@import 'modules/git-bridge-modal.less';
|
||||
@import 'modules/group-settings.less';
|
||||
@import 'modules/overleaf-integration.less';
|
||||
@import 'modules/onboarding.less';
|
||||
@import 'modules/writefull.less';
|
||||
@import 'modules/third-party-references.less';
|
||||
@import 'modules/labs.less';
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
const SAMLUserIdAttributeBatchHandler = require('../modules/overleaf-integration/app/src/SAML/SAMLUserIdAttributeBatchHandler')
|
||||
const SAMLUserIdAttributeBatchHandler = require('../modules/saas-authentication/app/src/SAML/SAMLUserIdAttributeBatchHandler')
|
||||
|
||||
const startInstitutionId = parseInt(process.argv[2])
|
||||
const endInstitutionId = parseInt(process.argv[3])
|
||||
|
|
|
@ -2,7 +2,7 @@ process.env.MONGO_SOCKET_TIMEOUT = '300000'
|
|||
// Run all the mongo queries on secondaries
|
||||
process.env.MONGO_CONNECTION_STRING =
|
||||
process.env.READ_ONLY_MONGO_CONNECTION_STRING
|
||||
const SAMLEmailBatchCheck = require('../modules/overleaf-integration/app/src/SAML/SAMLEmailBatchCheck')
|
||||
const SAMLEmailBatchCheck = require('../modules/saas-authentication/app/src/SAML/SAMLEmailBatchCheck')
|
||||
|
||||
const startInstitutionId = parseInt(process.argv[2])
|
||||
const emitDetailedData = process.argv.includes('--detailed-data')
|
||||
|
|
|
@ -3,7 +3,7 @@ process.env.MONGO_CONNECTION_STRING =
|
|||
process.env.READ_ONLY_MONGO_CONNECTION_STRING
|
||||
|
||||
const { waitForDb } = require('../app/src/infrastructure/mongodb')
|
||||
const SAMLUserIdMigrationHandler = require('../modules/overleaf-integration/app/src/SAML/SAMLUserIdMigrationHandler')
|
||||
const SAMLUserIdMigrationHandler = require('../modules/saas-authentication/app/src/SAML/SAMLUserIdMigrationHandler')
|
||||
|
||||
const institutionId = parseInt(process.argv[2])
|
||||
if (isNaN(institutionId)) throw new Error('No institution id')
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
process.env.MONGO_SOCKET_TIMEOUT = '300000'
|
||||
const { waitForDb } = require('../app/src/infrastructure/mongodb')
|
||||
const SAMLUserIdMigrationHandler = require('../modules/overleaf-integration/app/src/SAML/SAMLUserIdMigrationHandler')
|
||||
const SAMLUserIdMigrationHandler = require('../modules/saas-authentication/app/src/SAML/SAMLUserIdMigrationHandler')
|
||||
|
||||
const institutionId = parseInt(process.argv[2])
|
||||
if (isNaN(institutionId)) throw new Error('No institution id')
|
||||
|
|
|
@ -362,7 +362,7 @@ describe('ProjectListController', function () {
|
|||
this.institutionName = 'Overleaf'
|
||||
this.Features.hasFeature.withArgs('saml').returns(true)
|
||||
this.Features.hasFeature.withArgs('affiliations').returns(true)
|
||||
this.Features.hasFeature.withArgs('overleaf-integration').returns(true)
|
||||
this.Features.hasFeature.withArgs('saas').returns(true)
|
||||
done()
|
||||
})
|
||||
it('should show institution SSO available notification for confirmed domains', function () {
|
||||
|
|
|
@ -59,7 +59,7 @@ describe('Features', function () {
|
|||
expect(this.Features.hasFeature('homepage')).to.be.false
|
||||
expect(this.Features.hasFeature('link-url')).to.be.false
|
||||
expect(this.Features.hasFeature('oauth')).to.be.false
|
||||
expect(this.Features.hasFeature('overleaf-integration')).to.be.false
|
||||
expect(this.Features.hasFeature('saas')).to.be.false
|
||||
expect(this.Features.hasFeature('references')).to.be.false
|
||||
expect(this.Features.hasFeature('saml')).to.be.false
|
||||
expect(this.Features.hasFeature('templates-server-pro')).to.be.false
|
||||
|
@ -72,7 +72,7 @@ describe('Features', function () {
|
|||
this.settings.apis = {}
|
||||
})
|
||||
it('should return true', function () {
|
||||
expect(this.Features.hasFeature('overleaf-integration')).to.be.true
|
||||
expect(this.Features.hasFeature('saas')).to.be.true
|
||||
expect(this.Features.hasFeature('registration')).to.be.true
|
||||
})
|
||||
it('should return false', function () {
|
||||
|
@ -104,7 +104,7 @@ describe('Features', function () {
|
|||
it('should return true', function () {
|
||||
expect(this.Features.hasFeature('affiliations')).to.be.true
|
||||
expect(this.Features.hasFeature('analytics')).to.be.true
|
||||
expect(this.Features.hasFeature('overleaf-integration')).to.be.true
|
||||
expect(this.Features.hasFeature('saas')).to.be.true
|
||||
expect(this.Features.hasFeature('references')).to.be.true
|
||||
expect(this.Features.hasFeature('registration')).to.be.true
|
||||
})
|
||||
|
@ -135,8 +135,7 @@ describe('Features', function () {
|
|||
expect(this.Features.hasFeature('homepage')).to.be.true
|
||||
expect(this.Features.hasFeature('link-url')).to.be.true
|
||||
expect(this.Features.hasFeature('oauth')).to.be.true
|
||||
expect(this.Features.hasFeature('overleaf-integration')).to.be
|
||||
.true
|
||||
expect(this.Features.hasFeature('saas')).to.be.true
|
||||
expect(this.Features.hasFeature('references')).to.be.true
|
||||
expect(this.Features.hasFeature('registration')).to.be.true
|
||||
expect(this.Features.hasFeature('saml')).to.be.true
|
||||
|
|
Loading…
Reference in a new issue