Skip to content

Commit

Permalink
Merge branch 'eureka-test-rbugfest' of https://github.com/folio-org/s…
Browse files Browse the repository at this point in the history
…tripes-testing into FAT-17824
  • Loading branch information
TetianaParanich committed Dec 27, 2024
2 parents 36ef8db + e437b92 commit e57970f
Show file tree
Hide file tree
Showing 8 changed files with 25 additions and 11 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ describe('bulk-edit', () => {
describe('logs', () => {
describe('csv approach', () => {
before('create test data', () => {
cy.clearLocalStorage();
cy.createTempUser([]).then((userProperties) => {
userWithoutPermissions = userProperties;
});
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,11 @@ describe('bulk-edit', () => {
BulkEditLogs.checkHoldingsCheckbox();
BulkEditLogs.checkUsersCheckbox();
BulkEditLogs.checkItemsCheckbox();
// steps have been added to stabilize the test case on the bugfest environment because there are many records there that are no longer available for download
cy.wait(5000);
BulkEditLogs.sortLogsTableByColumnHeader('Started');
BulkEditLogs.sortLogsTableByColumnHeader('Started');
cy.wait(5000);
BulkEditLogs.clickActionsOnTheRow();
BulkEditLogs.verifyTriggerLogsAction();
},
Expand Down
4 changes: 2 additions & 2 deletions cypress/e2e/bulk-edit/query/bulk-edit-query-enum.cy.js
Original file line number Diff line number Diff line change
Expand Up @@ -74,9 +74,9 @@ describe('bulk-edit', () => {
QueryModal.testQueryDisabled();
QueryModal.runQueryDisabled();
QueryModal.chooseFromValueMultiselect(ITEM_STATUS_NAMES.AVAILABLE);
QueryModal.chooseFromValueMultiselect(ITEM_STATUS_NAMES.MISSING);
QueryModal.chooseFromValueMultiselect(ITEM_STATUS_NAMES.ON_ORDER);
QueryModal.verifyQueryAreaContent(
`(items.status_name not in ("${ITEM_STATUS_NAMES.AVAILABLE}","${ITEM_STATUS_NAMES.MISSING}"))`,
`(items.status_name not in ("${ITEM_STATUS_NAMES.AVAILABLE}","${ITEM_STATUS_NAMES.ON_ORDER}"))`,
);
QueryModal.testQueryDisabled(false);
QueryModal.runQueryDisabled();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ describe('MARC', () => {
QuickMarcEditor.checkPaneheaderContains(testData.sharedPaneheaderText);
QuickMarcEditor.updateExistingField(testData.tag245, testData.tag245UpdatedValue);
QuickMarcEditor.updateExistingField(testData.tag500, testData.tag500UpdatedValue);
QuickMarcEditor.moveFieldUp(18);
QuickMarcEditor.moveFieldUp(17);
QuickMarcEditor.pressSaveAndClose();
cy.wait(1500);
QuickMarcEditor.pressSaveAndClose();
Expand All @@ -119,10 +119,7 @@ describe('MARC', () => {
InventoryInstances.searchByTitle(createdInstanceID);
InventoryInstances.selectInstance();
InventoryInstance.checkInstanceTitle(testData.updatedTitle);
InventoryInstance.verifyLastUpdatedSource(
users.userAProperties.firstName,
users.userAProperties.lastName,
);
InventoryInstance.verifyLastUpdatedSourceByUnknownUser();
InventoryInstance.viewSource();
InventoryViewSource.verifyFieldInMARCBibSource(
testData.tag245,
Expand All @@ -140,8 +137,8 @@ describe('MARC', () => {
users.userAProperties.firstName,
users.userAProperties.lastName,
);
QuickMarcEditor.verifyTagValue(17, testData.tag504);
QuickMarcEditor.verifyTagValue(18, testData.tag500);
QuickMarcEditor.verifyTagValue(16, testData.tag504);
QuickMarcEditor.verifyTagValue(17, testData.tag500);
},
);
});
Expand Down
5 changes: 3 additions & 2 deletions cypress/e2e/settings/tenant/service-points.cy.js
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
import permissions from '../../../support/dictionary/permissions';
import ServicePoints from '../../../support/fragments/settings/tenant/servicePoints/servicePoints';
import TopMenu from '../../../support/fragments/topMenu';
import Users from '../../../support/fragments/users/users';
import getRandomPostfix from '../../../support/utils/stringTools';
import TopMenuNavigation from '../../../support/fragments/topMenuNavigation';
import { APPLICATION_NAMES } from '../../../support/constants';

let user;
const newServicePoint = {
Expand All @@ -19,7 +20,7 @@ describe('Settings: Tenant', () => {
user = userProperties;
cy.login(user.username, user.password);
cy.wait(2000);
cy.visit(TopMenu.settingsPath);
TopMenuNavigation.navigateToApp(APPLICATION_NAMES.SETTINGS);
ServicePoints.goToServicePointsTab();
},
);
Expand Down
4 changes: 4 additions & 0 deletions cypress/support/fragments/bulk-edit/bulk-edit-logs.js
Original file line number Diff line number Diff line change
Expand Up @@ -501,6 +501,10 @@ export default {
]);
},

sortLogsTableByColumnHeader(columnHeader) {
cy.do(MultiColumnListHeader(columnHeader).click());
},

fillLogsDate(accordion, dataPicker, value) {
cy.do(Accordion(accordion).find(TextField(dataPicker)).fillIn(value));
},
Expand Down
5 changes: 5 additions & 0 deletions cypress/support/fragments/inventory/inventoryInstance.js
Original file line number Diff line number Diff line change
Expand Up @@ -1618,6 +1618,11 @@ export default {
.should('include.text', `${userLastName}, ${userFirsttName}`);
},

verifyLastUpdatedSourceByUnknownUser: () => {
cy.do(Accordion('Administrative data').click());
cy.get('div[data-test-updated-by="true"]').should('include.text', 'Unknown user');
},

verifyRecordCreatedSource: (userFirsttName, userLastName) => {
cy.get('div[data-test-created-by="true"]')
.find('a')
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -133,6 +133,7 @@ export default {
]);
if (newCode) cy.do(TextField({ name: 'code' }).fillIn(newCode));
if (newDisplayName) cy.do(TextField({ name: 'discoveryDisplayName' }).fillIn(newDisplayName));
cy.wait(3000);
cy.do(saveAndCloseButton.click());
},

Expand Down

0 comments on commit e57970f

Please sign in to comment.