未验证 提交 c79a4c15 编写于 作者: D Dmitry Kruchinin 提交者: GitHub

Cypress. Update case 105. Add check "Google cloud storage" provider fields. (#3980)

* Update case 105. Add "Check "Google cloud storage" provider fields" step

* Fix eslint issue
Co-authored-by: Ndvkruchinin <dvkruchinin@gmail.com>
上级 6351df07
......@@ -20,7 +20,9 @@ context('Cloud storage.', () => {
manifest: 'manifest.jsonl',
resource: 'container',
display_name: 'Demonstration container',
}
prefix: 'GCS_prefix',
projectID: 'Some ID',
};
before(() => {
cy.visit('auth/login');
......@@ -82,7 +84,7 @@ context('Cloud storage.', () => {
.get('.cvat-cloud-storage-region-creator')
.should('be.visible')
.within(() => {
cy.contains('button', 'Add region').click()
cy.contains('button', 'Add region').click();
});
cy.get('.cvat-incorrect-add-region-notification').should('exist');
cy.closeNotification('.cvat-incorrect-add-region-notification');
......@@ -109,6 +111,40 @@ context('Cloud storage.', () => {
.click();
cy.get('#account_name').should('exist');
cy.get('#SAS_token').should('not.exist');
});
it('Check "Google cloud storage" provider fields.', () => {
cy.contains('.cvat-cloud-storage-select-provider', 'Azure').click();
cy.contains('.cvat-cloud-storage-select-provider', 'Google').click();
cy.get('#resource')
.should('exist')
.should('have.attr', 'value', dummyData.resource);
cy.get('#credentials_type').should('exist').click();
cy.get('.ant-select-dropdown')
.not('.ant-select-dropdown-hidden')
.get('[title="Key file"]')
.should('be.visible')
.click();
cy.get('.cvat-cloud-storage-form-item-key-file').should('be.visible');
cy.get('[title="Key file"]').first().click();
cy.get('.ant-select-dropdown')
.not('.ant-select-dropdown-hidden')
.get('[title="Anonymous access"]')
.should('be.visible')
.click();
cy.get('.cvat-cloud-storage-form-item-key-file').should('not.exist');
cy.get('#prefix').should('exist').type(dummyData.prefix).should('have.value', dummyData.prefix);
cy.get('#project_id').should('exist').type(dummyData.projectID).should('have.value', dummyData.projectID);
cy.get('#location').should('exist').click();
cy.get('.ant-select-dropdown')
.not('.ant-select-dropdown-hidden')
.get('.cvat-cloud-storage-region-creator')
.should('be.visible')
.within(() => {
cy.contains('button', 'Add region').click();
});
cy.get('.cvat-incorrect-add-region-notification').should('exist');
cy.closeNotification('.cvat-incorrect-add-region-notification');
cy.get('.cvat-cloud-storage-reset-button').click();
cy.get('.cvat-cloud-storage-form').should('not.exist');
});
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册