mirror of
https://github.com/DSpace/dspace-angular.git
synced 2025-10-07 10:04:11 +00:00
Ensure Item Edit page tab is visible before & after clicking it.
This commit is contained in:
@@ -13,9 +13,11 @@ beforeEach(() => {
|
|||||||
|
|
||||||
describe('Edit Item > Edit Metadata tab', () => {
|
describe('Edit Item > Edit Metadata tab', () => {
|
||||||
it('should pass accessibility tests', () => {
|
it('should pass accessibility tests', () => {
|
||||||
|
cy.get('a[data-test="metadata"]').should('be.visible');
|
||||||
cy.get('a[data-test="metadata"]').click();
|
cy.get('a[data-test="metadata"]').click();
|
||||||
|
|
||||||
// Our selected tab should be active
|
// Our selected tab should be both visible & active
|
||||||
|
cy.get('a[data-test="metadata"]').should('be.visible');
|
||||||
cy.get('a[data-test="metadata"]').should('have.class', 'active');
|
cy.get('a[data-test="metadata"]').should('have.class', 'active');
|
||||||
|
|
||||||
// <ds-edit-item-page> tag must be loaded
|
// <ds-edit-item-page> tag must be loaded
|
||||||
@@ -34,9 +36,11 @@ describe('Edit Item > Edit Metadata tab', () => {
|
|||||||
describe('Edit Item > Status tab', () => {
|
describe('Edit Item > Status tab', () => {
|
||||||
|
|
||||||
it('should pass accessibility tests', () => {
|
it('should pass accessibility tests', () => {
|
||||||
|
cy.get('a[data-test="status"]').should('be.visible');
|
||||||
cy.get('a[data-test="status"]').click();
|
cy.get('a[data-test="status"]').click();
|
||||||
|
|
||||||
// Our selected tab should be active
|
// Our selected tab should be both visible & active
|
||||||
|
cy.get('a[data-test="status"]').should('be.visible');
|
||||||
cy.get('a[data-test="status"]').should('have.class', 'active');
|
cy.get('a[data-test="status"]').should('have.class', 'active');
|
||||||
|
|
||||||
// <ds-item-status> tag must be loaded
|
// <ds-item-status> tag must be loaded
|
||||||
@@ -50,9 +54,11 @@ describe('Edit Item > Status tab', () => {
|
|||||||
describe('Edit Item > Bitstreams tab', () => {
|
describe('Edit Item > Bitstreams tab', () => {
|
||||||
|
|
||||||
it('should pass accessibility tests', () => {
|
it('should pass accessibility tests', () => {
|
||||||
|
cy.get('a[data-test="bitstreams"]').should('be.visible');
|
||||||
cy.get('a[data-test="bitstreams"]').click();
|
cy.get('a[data-test="bitstreams"]').click();
|
||||||
|
|
||||||
// Our selected tab should be active
|
// Our selected tab should be both visible & active
|
||||||
|
cy.get('a[data-test="bitstreams"]').should('be.visible');
|
||||||
cy.get('a[data-test="bitstreams"]').should('have.class', 'active');
|
cy.get('a[data-test="bitstreams"]').should('have.class', 'active');
|
||||||
|
|
||||||
// <ds-item-bitstreams> tag must be loaded
|
// <ds-item-bitstreams> tag must be loaded
|
||||||
@@ -77,9 +83,11 @@ describe('Edit Item > Bitstreams tab', () => {
|
|||||||
describe('Edit Item > Curate tab', () => {
|
describe('Edit Item > Curate tab', () => {
|
||||||
|
|
||||||
it('should pass accessibility tests', () => {
|
it('should pass accessibility tests', () => {
|
||||||
|
cy.get('a[data-test="curate"]').should('be.visible');
|
||||||
cy.get('a[data-test="curate"]').click();
|
cy.get('a[data-test="curate"]').click();
|
||||||
|
|
||||||
// Our selected tab should be active
|
// Our selected tab should be both visible & active
|
||||||
|
cy.get('a[data-test="curate"]').should('be.visible');
|
||||||
cy.get('a[data-test="curate"]').should('have.class', 'active');
|
cy.get('a[data-test="curate"]').should('have.class', 'active');
|
||||||
|
|
||||||
// <ds-item-curate> tag must be loaded
|
// <ds-item-curate> tag must be loaded
|
||||||
@@ -93,9 +101,11 @@ describe('Edit Item > Curate tab', () => {
|
|||||||
describe('Edit Item > Relationships tab', () => {
|
describe('Edit Item > Relationships tab', () => {
|
||||||
|
|
||||||
it('should pass accessibility tests', () => {
|
it('should pass accessibility tests', () => {
|
||||||
|
cy.get('a[data-test="relationships"]').should('be.visible');
|
||||||
cy.get('a[data-test="relationships"]').click();
|
cy.get('a[data-test="relationships"]').click();
|
||||||
|
|
||||||
// Our selected tab should be active
|
// Our selected tab should be both visible & active
|
||||||
|
cy.get('a[data-test="relationships"]').should('be.visible');
|
||||||
cy.get('a[data-test="relationships"]').should('have.class', 'active');
|
cy.get('a[data-test="relationships"]').should('have.class', 'active');
|
||||||
|
|
||||||
// <ds-item-relationships> tag must be loaded
|
// <ds-item-relationships> tag must be loaded
|
||||||
@@ -109,9 +119,11 @@ describe('Edit Item > Relationships tab', () => {
|
|||||||
describe('Edit Item > Version History tab', () => {
|
describe('Edit Item > Version History tab', () => {
|
||||||
|
|
||||||
it('should pass accessibility tests', () => {
|
it('should pass accessibility tests', () => {
|
||||||
|
cy.get('a[data-test="versionhistory"]').should('be.visible');
|
||||||
cy.get('a[data-test="versionhistory"]').click();
|
cy.get('a[data-test="versionhistory"]').click();
|
||||||
|
|
||||||
// Our selected tab should be active
|
// Our selected tab should be both visible & active
|
||||||
|
cy.get('a[data-test="versionhistory"]').should('be.visible');
|
||||||
cy.get('a[data-test="versionhistory"]').should('have.class', 'active');
|
cy.get('a[data-test="versionhistory"]').should('have.class', 'active');
|
||||||
|
|
||||||
// <ds-item-version-history> tag must be loaded
|
// <ds-item-version-history> tag must be loaded
|
||||||
@@ -125,9 +137,11 @@ describe('Edit Item > Version History tab', () => {
|
|||||||
describe('Edit Item > Access Control tab', () => {
|
describe('Edit Item > Access Control tab', () => {
|
||||||
|
|
||||||
it('should pass accessibility tests', () => {
|
it('should pass accessibility tests', () => {
|
||||||
|
cy.get('a[data-test="access-control"]').should('be.visible');
|
||||||
cy.get('a[data-test="access-control"]').click();
|
cy.get('a[data-test="access-control"]').click();
|
||||||
|
|
||||||
// Our selected tab should be active
|
// Our selected tab should be both visible & active
|
||||||
|
cy.get('a[data-test="access-control"]').should('be.visible');
|
||||||
cy.get('a[data-test="access-control"]').should('have.class', 'active');
|
cy.get('a[data-test="access-control"]').should('have.class', 'active');
|
||||||
|
|
||||||
// <ds-item-access-control> tag must be loaded
|
// <ds-item-access-control> tag must be loaded
|
||||||
@@ -141,9 +155,11 @@ describe('Edit Item > Access Control tab', () => {
|
|||||||
describe('Edit Item > Collection Mapper tab', () => {
|
describe('Edit Item > Collection Mapper tab', () => {
|
||||||
|
|
||||||
it('should pass accessibility tests', () => {
|
it('should pass accessibility tests', () => {
|
||||||
|
cy.get('a[data-test="mapper"]').should('be.visible');
|
||||||
cy.get('a[data-test="mapper"]').click();
|
cy.get('a[data-test="mapper"]').click();
|
||||||
|
|
||||||
// Our selected tab should be active
|
// Our selected tab should be both visible & active
|
||||||
|
cy.get('a[data-test="mapper"]').should('be.visible');
|
||||||
cy.get('a[data-test="mapper"]').should('have.class', 'active');
|
cy.get('a[data-test="mapper"]').should('have.class', 'active');
|
||||||
|
|
||||||
// <ds-item-collection-mapper> tag must be loaded
|
// <ds-item-collection-mapper> tag must be loaded
|
||||||
|
Reference in New Issue
Block a user