Skip to content

Commit b66541b

Browse files
Merge pull request #861 from datacite/raid-registry
Implements raidRegistry type for Repositories
2 parents 670f34a + 1163f56 commit b66541b

3 files changed

Lines changed: 27 additions & 4 deletions

File tree

app/models/repository.js

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,10 @@ export const clientTypeList = [
2323
{
2424
label: 'IGSN ID Catalog',
2525
value: 'igsnCatalog'
26+
},
27+
{
28+
label: 'RAiD Registry',
29+
value: 'raidRegistry'
2630
}
2731
];
2832

cypress/e2e/client_admin/info.test.ts

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -141,6 +141,16 @@ describe('ACCEPTANCE: CLIENT_ADMIN | INFO', () => {
141141
})
142142
});
143143

144+
// Set client_type to RAiD Registry
145+
cy.get('div#client-type div[role="button"]').click({ waitForAnimations: true }).then(() => {
146+
cy.get('ul.ember-power-select-options li').contains('RAiD Registry').click({ waitForAnimations: true }).then(() => {
147+
// RAiD Registry client_type divs should be visible
148+
cy.get('#repository-issn').should('not.exist');
149+
cy.get('#repository-type').should('be.visible');
150+
cy.get('#certificate').should('be.visible');
151+
})
152+
});
153+
144154
// Set client_type back to Repository
145155
cy.get('div#client-type div[role="button"]').click({ waitForAnimations: true, force: true }).then(($dropdown) => {
146156
cy.get('ul.ember-power-select-options li').contains('Repository').click({ waitForAnimations: true })
@@ -177,7 +187,7 @@ describe('ACCEPTANCE: CLIENT_ADMIN | INFO', () => {
177187
});
178188
});
179189

180-
it.only('can see info when using capitalized identifier URL subdirectory', () => {
190+
it('can see info when using capitalized identifier URL subdirectory', () => {
181191
cy.visit('/repositories/DATACITE.TEST');
182192
cy.url().should('include', '/repositories/DATACITE.TEST').then(() => {
183193

cypress/e2e/organization_admin/repositories.test.ts

Lines changed: 12 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,8 @@ describe('ACCEPTANCE: ORGANIZATION_ADMIN | REPOSITORIES', () => {
99
const waitTime = 1000;
1010
const waitTime2 = 2000;
1111
const waitTime3 = 3000;
12+
const waitTime4 = 4000;
13+
const waitTime5 = 5000;
1214
let prefix = '';
1315
let suffix = '';
1416
const min = 500000;
@@ -106,7 +108,7 @@ describe('ACCEPTANCE: ORGANIZATION_ADMIN | REPOSITORIES', () => {
106108
cy.visit('/providers/' + provider_id + '/repositories/new');
107109
cy.url().should('include', '/providers/' + provider_id + '/repositories/new').then(() => {
108110

109-
cy.wait(waitTime2);
111+
cy.wait(waitTime5);
110112
cy.get('h2.work').contains('DataCite');
111113
cy.get('a#account_menu_link').should('contain', Cypress.env('organization_admin_username').toUpperCase());
112114

@@ -116,7 +118,6 @@ describe('ACCEPTANCE: ORGANIZATION_ADMIN | REPOSITORIES', () => {
116118
cy.get('#client-type').should('be.visible');
117119
cy.get('#client-type .ember-power-select-selected-item').should('contain', 'Repository');
118120

119-
/* - TEMPORARILY SKIP THIS
120121
// Set client_type to Periodical
121122
cy.get('div#client-type div[role="button"]').click({ waitForAnimations: true }).then(() => {
122123
cy.get('ul.ember-power-select-options li').contains('Periodical').click({ waitForAnimations: true }).then(() => {
@@ -138,13 +139,21 @@ describe('ACCEPTANCE: ORGANIZATION_ADMIN | REPOSITORIES', () => {
138139
})
139140
});
140141

142+
// Set client_type to RAiD Registry
143+
cy.get('div#client-type div[role="button"]').click({ waitForAnimations: true }).then(() => {
144+
cy.get('ul.ember-power-select-options li').contains('RAiD Registry').click({ waitForAnimations: true }).then(() => {
145+
// RAiD Registry client_type divs should be visible
146+
cy.get('#repository-issn').should('not.exist');
147+
cy.get('#repository-type').should('be.visible');
148+
cy.get('#certificate').should('be.visible');
149+
})
150+
});
141151

142152
// Set client_type back to Repository
143153
cy.get('div#client-type div[role="button"]').click({ waitForAnimations: true }).then(() => {
144154
cy.get('ul.ember-power-select-options li').contains('Repository').click({ waitForAnimations: true })
145155
});
146156
cy.get('#client-type .ember-power-select-selected-item').should('contain', 'Repository');
147-
*/
148157

149158
cy.get('#re3data').should('be.visible');
150159
cy.get('#name').should('be.visible');

0 commit comments

Comments
 (0)