@globisnv/cypress-core 1.0.0 → 1.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -15,6 +15,7 @@ export const GLO_enterConsignment = (obj, formName = defaultFormName, formNameGe
15
15
  cy.GLO_checkLoadingIndicator();
16
16
  }
17
17
  cy.GLO_addInput([formName, 'consignment_subtype'], obj.consignmentSubType);
18
+ cy.GLO_addInput([formName, 'default_consignment_description'], obj.defaultConsignmentDescription);
18
19
  cy.GLO_addInput([formName, 'relation_reference'], obj.relationReference);
19
20
  cy.GLO_addInput([formName, 'delivery_condition'], obj.deliveryCondition);
20
21
  cy.GLO_addInput([formName, 'local_invoice_relation_code'], obj.invoiceRelation);
@@ -0,0 +1,24 @@
1
+ import type { CheckState } from '../tsHelper.js';
2
+ export type objConsignmentCustoms = {
3
+ sequenceNr?: number;
4
+ customsType?: string;
5
+ customsOfficeDefinition?: string;
6
+ customsOfficeAddress?: string;
7
+ customsResponsibility?: string;
8
+ customsRelation?: string;
9
+ customerCustomsBroker?: string;
10
+ flagBlocked?: CheckState;
11
+ flagWeekendClearance?: CheckState;
12
+ remarks?: string;
13
+ outboundStopDefinition?: string;
14
+ outboundStop?: string;
15
+ outboundHandling?: string;
16
+ outboundDocumentType?: string;
17
+ flagOutboundOk?: CheckState;
18
+ inboundStopDefinition?: string;
19
+ inboundStop?: string;
20
+ inboundHandling?: string;
21
+ inboundDocumentType?: string;
22
+ flagInboundOk?: CheckState;
23
+ };
24
+ export declare const GLO_enterConsignmentCustoms: (obj: objConsignmentCustoms) => void;
@@ -0,0 +1,24 @@
1
+ export const GLO_enterConsignmentCustoms = (obj) => {
2
+ const formName = 'ng$consignment_customs_dtl';
3
+ cy.GLO_addInput([formName, 'sequence_nr'], obj.sequenceNr);
4
+ cy.GLO_addInput([formName, 'customs_type'], obj.customsType);
5
+ cy.GLO_addInput([formName, 'customs_office_definition'], obj.customsOfficeDefinition);
6
+ cy.GLO_popupWindow([formName, 'customs_office_address_id'], obj.customsOfficeAddress);
7
+ cy.GLO_addInput([formName, 'customs_responsibility'], obj.customsResponsibility);
8
+ cy.GLO_popupWindow([formName, 'customs_relation_id'], obj.customsRelation);
9
+ cy.GLO_addInput([formName, 'customer_customs_broker'], obj.customerCustomsBroker);
10
+ cy.GLO_checkbox([formName, 'flag_blocked'], obj.flagBlocked);
11
+ cy.GLO_checkbox([formName, 'flag_weekend_clearance'], obj.flagWeekendClearance);
12
+ cy.GLO_addInput([formName, 'remarks'], obj.remarks);
13
+ cy.GLO_addInput([formName, 'outbound_stop_definition'], obj.outboundStopDefinition);
14
+ // Stop and handling have no code column, so they are selector components rather than valuelists.
15
+ cy.GLO_popupWindow([formName, 'outbound_stop_id'], obj.outboundStop);
16
+ cy.GLO_popupWindow([formName, 'outbound_handling_id'], obj.outboundHandling);
17
+ cy.GLO_addInput([formName, 'outbound_document_type_id'], obj.outboundDocumentType);
18
+ cy.GLO_checkbox([formName, 'flag_outbound_ok'], obj.flagOutboundOk);
19
+ cy.GLO_addInput([formName, 'inbound_stop_definition'], obj.inboundStopDefinition);
20
+ cy.GLO_popupWindow([formName, 'inbound_stop_id'], obj.inboundStop);
21
+ cy.GLO_popupWindow([formName, 'inbound_handling_id'], obj.inboundHandling);
22
+ cy.GLO_addInput([formName, 'inbound_document_type_id'], obj.inboundDocumentType);
23
+ cy.GLO_checkbox([formName, 'flag_inbound_ok'], obj.flagInboundOk);
24
+ };
@@ -0,0 +1,11 @@
1
+ import type { CheckState } from '../tsHelper.js';
2
+ export type objConsignmentCustomsSettings = {
3
+ flagCustoms?: CheckState;
4
+ customsFlow?: string;
5
+ gmr?: string;
6
+ consignor?: string;
7
+ consignorAddress?: string;
8
+ consignee?: string;
9
+ consigneeAddress?: string;
10
+ };
11
+ export declare const GLO_enterConsignmentCustomsSettings: (obj: objConsignmentCustomsSettings) => void;
@@ -0,0 +1,11 @@
1
+ export const GLO_enterConsignmentCustomsSettings = (obj) => {
2
+ const formName = 'ng$consignment_dtl_customs';
3
+ cy.GLO_checkbox([formName, 'flag_customs'], obj.flagCustoms);
4
+ cy.GLO_addInput([formName, 'customs_flow_id'], obj.customsFlow);
5
+ cy.GLO_addInput([formName, 'gmr'], obj.gmr);
6
+ // The four party fields are selector components, so they open a selection window instead of a dropdown.
7
+ cy.GLO_popupWindow([formName, 'consignor_id'], obj.consignor);
8
+ cy.GLO_popupWindow([formName, 'consignor_address'], obj.consignorAddress);
9
+ cy.GLO_popupWindow([formName, 'consignee_id'], obj.consignee);
10
+ cy.GLO_popupWindow([formName, 'consignee_address'], obj.consigneeAddress);
11
+ };
@@ -0,0 +1,22 @@
1
+ import type { CheckState } from '../tsHelper.js';
2
+ export type objCustomsDeclaration = {
3
+ consignmentCustomsSequenceNr?: number;
4
+ customsType?: string;
5
+ transportMethod?: string;
6
+ deliveryCondition?: string;
7
+ emergencyProcedureCode?: string;
8
+ flagBlocked?: CheckState;
9
+ consignor?: string;
10
+ consignorAddress?: string;
11
+ consignee?: string;
12
+ consigneeAddress?: string;
13
+ customsReference?: string;
14
+ externalReference?: string;
15
+ traderReference?: string;
16
+ supplierReference?: string;
17
+ ensReference?: string;
18
+ customsPoao?: string;
19
+ customsCrn?: string;
20
+ sequenceNrLine?: number;
21
+ };
22
+ export declare const GLO_enterCustomsDeclaration: (obj: objCustomsDeclaration) => void;
@@ -0,0 +1,22 @@
1
+ export const GLO_enterCustomsDeclaration = (obj) => {
2
+ const formName = 'ng$customs_declaration_dtl';
3
+ cy.GLO_addInput([formName, 'consignment_customs_sequence_nr'], obj.consignmentCustomsSequenceNr);
4
+ cy.GLO_addInput([formName, 'customs_type'], obj.customsType);
5
+ cy.GLO_addInput([formName, 'transport_method_id'], obj.transportMethod);
6
+ cy.GLO_addInput([formName, 'deliverycondition_id'], obj.deliveryCondition);
7
+ cy.GLO_addInput([formName, 'emergency_procedure_code'], obj.emergencyProcedureCode);
8
+ cy.GLO_checkbox([formName, 'flag_blocked'], obj.flagBlocked);
9
+ // The four party fields are selector components, so they open a selection window instead of a dropdown.
10
+ cy.GLO_popupWindow([formName, 'consignor_id'], obj.consignor);
11
+ cy.GLO_popupWindow([formName, 'consignor_address'], obj.consignorAddress);
12
+ cy.GLO_popupWindow([formName, 'consignee_id'], obj.consignee);
13
+ cy.GLO_popupWindow([formName, 'consignee_address'], obj.consigneeAddress);
14
+ cy.GLO_addInput([formName, 'customs_reference'], obj.customsReference);
15
+ cy.GLO_addInput([formName, 'external_reference'], obj.externalReference);
16
+ cy.GLO_addInput([formName, 'trader_reference'], obj.traderReference);
17
+ cy.GLO_addInput([formName, 'supplier_reference'], obj.supplierReference);
18
+ cy.GLO_addInput([formName, 'ens_reference'], obj.ensReference);
19
+ cy.GLO_addInput([formName, 'customs_poao'], obj.customsPoao);
20
+ cy.GLO_addInput([formName, 'customs_crn'], obj.customsCrn);
21
+ cy.GLO_addInput([formName, 'sequence_nr_line'], obj.sequenceNrLine);
22
+ };
@@ -0,0 +1,20 @@
1
+ export type objCustomsDeclarationDetail = {
2
+ intrastatCode?: string;
3
+ intrastatCodeReceived?: string;
4
+ customsDescription?: string;
5
+ customsCountry?: string;
6
+ customsRegionCode?: string;
7
+ dgnUnNumber?: string;
8
+ sscc?: string;
9
+ packagingArticleUnit?: string;
10
+ customsPackagingCode?: string;
11
+ packagingQuantity?: number;
12
+ extraCustomsPackagingCode?: string;
13
+ extraPackagingQuantity?: number;
14
+ grossWeight?: number;
15
+ netWeight?: number;
16
+ weightUnit?: string;
17
+ invoiceAmount?: number;
18
+ currency?: string;
19
+ };
20
+ export declare const GLO_enterCustomsDeclarationDetail: (obj: objCustomsDeclarationDetail) => void;
@@ -0,0 +1,20 @@
1
+ export const GLO_enterCustomsDeclarationDetail = (obj) => {
2
+ const formName = 'ng$customs_declaration_detail_dtl';
3
+ cy.GLO_addInput([formName, 'intrastat_code_id'], obj.intrastatCode);
4
+ cy.GLO_addInput([formName, 'intrastat_code_received'], obj.intrastatCodeReceived);
5
+ cy.GLO_addInput([formName, 'customs_description'], obj.customsDescription);
6
+ cy.GLO_addInput([formName, 'customs_country_id'], obj.customsCountry);
7
+ cy.GLO_addInput([formName, 'customs_region_code'], obj.customsRegionCode);
8
+ cy.GLO_addInput([formName, 'dgn_un_number_id'], obj.dgnUnNumber);
9
+ cy.GLO_addInput([formName, 'sscc'], obj.sscc);
10
+ cy.GLO_addInput([formName, 'packaging_articleunit_id'], obj.packagingArticleUnit);
11
+ cy.GLO_addInput([formName, 'customs_packaging_code'], obj.customsPackagingCode);
12
+ cy.GLO_addInput([formName, 'packaging_quantity'], obj.packagingQuantity);
13
+ cy.GLO_addInput([formName, 'extra_customs_packaging_code'], obj.extraCustomsPackagingCode);
14
+ cy.GLO_addInput([formName, 'extra_packaging_quantity'], obj.extraPackagingQuantity);
15
+ cy.GLO_addInput([formName, 'gross_weight'], obj.grossWeight);
16
+ cy.GLO_addInput([formName, 'net_weight'], obj.netWeight);
17
+ cy.GLO_addInput([formName, 'weight_unit_id'], obj.weightUnit);
18
+ cy.GLO_addInput([formName, 'invoice_amount'], obj.invoiceAmount);
19
+ cy.GLO_addInput([formName, 'currency_id'], obj.currency);
20
+ };
@@ -0,0 +1,9 @@
1
+ export type objCustomsDeclarationDocument = {
2
+ documentType?: string;
3
+ customsType?: string;
4
+ customsOfficeDestinationAddress?: string;
5
+ customsMrn?: string;
6
+ customsUcr?: string;
7
+ customsLrn?: string;
8
+ };
9
+ export declare const GLO_enterCustomsDeclarationDocument: (obj: objCustomsDeclarationDocument) => void;
@@ -0,0 +1,9 @@
1
+ export const GLO_enterCustomsDeclarationDocument = (obj) => {
2
+ const formName = 'ng$customs_declaration_document_dtl';
3
+ cy.GLO_addInput([formName, 'document_type_id'], obj.documentType);
4
+ cy.GLO_addInput([formName, 'customs_type'], obj.customsType);
5
+ cy.GLO_popupWindow([formName, 'customs_office_destination_address_id'], obj.customsOfficeDestinationAddress);
6
+ cy.GLO_addInput([formName, 'customs_mrn'], obj.customsMrn);
7
+ cy.GLO_addInput([formName, 'customs_ucr'], obj.customsUcr);
8
+ cy.GLO_addInput([formName, 'customs_lrn'], obj.customsLrn);
9
+ };
@@ -0,0 +1,22 @@
1
+ import type { CheckState } from '../tsHelper.js';
2
+ export type objLogisticContractCustomsDefinition = {
3
+ sequenceNr?: number;
4
+ customsType?: string;
5
+ customsResponsibility?: string;
6
+ customsRelation?: string;
7
+ customerCustomsBroker?: string;
8
+ customsOfficeDefinition?: string;
9
+ customsOfficeAddress?: string;
10
+ transportScenario?: string;
11
+ outboundStopDefinition?: string;
12
+ outboundStop?: string;
13
+ outboundHandling?: string;
14
+ outboundDocumentType?: string;
15
+ inboundStopDefinition?: string;
16
+ inboundStop?: string;
17
+ inboundHandling?: string;
18
+ inboundDocumentType?: string;
19
+ flagWeekendClearance?: CheckState;
20
+ remarks?: string;
21
+ };
22
+ export declare const GLO_enterLogisticContractCustomsDefinition: (obj: objLogisticContractCustomsDefinition) => void;
@@ -0,0 +1,22 @@
1
+ export const GLO_enterLogisticContractCustomsDefinition = (obj) => {
2
+ const formName = 'ng$logistic_contract_customs_definition_dtl';
3
+ cy.GLO_addInput([formName, 'sequence_nr'], obj.sequenceNr);
4
+ cy.GLO_addInput([formName, 'customs_type'], obj.customsType);
5
+ cy.GLO_addInput([formName, 'customs_responsibility'], obj.customsResponsibility);
6
+ cy.GLO_popupWindow([formName, 'customs_relation_id'], obj.customsRelation);
7
+ cy.GLO_addInput([formName, 'customer_customs_broker'], obj.customerCustomsBroker);
8
+ cy.GLO_addInput([formName, 'customs_office_definition'], obj.customsOfficeDefinition);
9
+ cy.GLO_popupWindow([formName, 'customs_office_address_id'], obj.customsOfficeAddress);
10
+ cy.GLO_addInput([formName, 'lcd_tpt_scenario_execution_id'], obj.transportScenario);
11
+ cy.GLO_addInput([formName, 'outbound_stop_definition'], obj.outboundStopDefinition);
12
+ // Stop and handling have no code column, so they are selector components rather than valuelists.
13
+ cy.GLO_popupWindow([formName, 'outbound_stop_id'], obj.outboundStop);
14
+ cy.GLO_popupWindow([formName, 'outbound_handling_id'], obj.outboundHandling);
15
+ cy.GLO_addInput([formName, 'outbound_document_type_id'], obj.outboundDocumentType);
16
+ cy.GLO_addInput([formName, 'inbound_stop_definition'], obj.inboundStopDefinition);
17
+ cy.GLO_popupWindow([formName, 'inbound_stop_id'], obj.inboundStop);
18
+ cy.GLO_popupWindow([formName, 'inbound_handling_id'], obj.inboundHandling);
19
+ cy.GLO_addInput([formName, 'inbound_document_type_id'], obj.inboundDocumentType);
20
+ cy.GLO_checkbox([formName, 'flag_weekend_clearance'], obj.flagWeekendClearance);
21
+ cy.GLO_addInput([formName, 'remarks'], obj.remarks);
22
+ };
@@ -0,0 +1,11 @@
1
+ import type { CheckState } from '../tsHelper.js';
2
+ export type objLogisticContractDetailCustoms = {
3
+ flagCustoms?: CheckState;
4
+ customsFlow?: string;
5
+ eoriEidr?: string;
6
+ consignor?: string;
7
+ consignorAddress?: string;
8
+ consignee?: string;
9
+ consigneeAddress?: string;
10
+ };
11
+ export declare const GLO_enterLogisticContractDetailCustoms: (obj: objLogisticContractDetailCustoms) => void;
@@ -0,0 +1,11 @@
1
+ export const GLO_enterLogisticContractDetailCustoms = (obj) => {
2
+ const formName = 'ng$logistic_contract_detail_dtl_customs';
3
+ cy.GLO_checkbox([formName, 'flag_customs'], obj.flagCustoms);
4
+ cy.GLO_addInput([formName, 'customs_flow_id'], obj.customsFlow);
5
+ cy.GLO_addInput([formName, 'eori_eidr'], obj.eoriEidr);
6
+ // The four party fields are selector components, so they open a selection window instead of a dropdown.
7
+ cy.GLO_popupWindow([formName, 'consignor_id'], obj.consignor);
8
+ cy.GLO_popupWindow([formName, 'consignor_address'], obj.consignorAddress);
9
+ cy.GLO_popupWindow([formName, 'consignee_id'], obj.consignee);
10
+ cy.GLO_popupWindow([formName, 'consignee_address'], obj.consigneeAddress);
11
+ };
@@ -14,8 +14,8 @@ export const GLO_enterRelation = (obj, formName = formNameString) => {
14
14
  cy.GLO_addInput([formName, 'postal_code_general'], obj.postalCodeGeneral);
15
15
  cy.GLO_checkLoadingIndicator();
16
16
  cy.get('body').then(($body) => {
17
- if ($body.find('.svy-dialog').length > 0) {
18
- if ($body.find('.svy-dialog [row-index]').length === 0) {
17
+ if ($body.find('.svy-dialog.active').length > 0) {
18
+ if ($body.find('.svy-dialog.active [row-index]').length === 0) {
19
19
  cy.GLO_log('No cities found for this postal code, allowing manual input');
20
20
  cy.GLO_clickButton(['ng$svy_nav_selection', 'btn_cancel']);
21
21
  return;
@@ -43,8 +43,8 @@ export const GLO_enterRelation = (obj, formName = formNameString) => {
43
43
  cy.GLO_addInput([formName, 'city_general'], obj.cityGeneral);
44
44
  cy.GLO_checkLoadingIndicator();
45
45
  cy.get('body').then(($body) => {
46
- if ($body.find('.svy-dialog').length > 0) {
47
- if ($body.find('.svy-dialog [row-index]').length === 0)
46
+ if ($body.find('.svy-dialog.active').length > 0) {
47
+ if ($body.find('.svy-dialog.active [row-index]').length === 0)
48
48
  cy.GLO_clickButton(['ng$svy_nav_selection', 'btn_cancel']);
49
49
  else
50
50
  cy.GLO_dblClickRowInGrid(span, ['ng$postalcode_sel', 'grid'], obj.cityGeneral, undefined, skipCheck);
@@ -115,7 +115,7 @@ Cypress.Commands.add('GLO_defaultlogin', (company, usernameENV = 'username', pas
115
115
  }
116
116
  cy.GLO_checkLoadingIndicator();
117
117
  cy.get('body').then(($body) => {
118
- if ($body.find('.svy-message-dialog .window-title').text() === 'Locked record') {
118
+ if ($body.find('.svy-message-dialog.active .window-title').text() === 'Locked record') {
119
119
  // biome-ignore plugin: wait for locked record dialog choice to register
120
120
  cy.wait(15000);
121
121
  cy.GLO_dialogChoice('!globis.label.yes!');
@@ -693,12 +693,12 @@ Cypress.Commands.add('GLO_closeDashboard', () => {
693
693
  if (testFailed)
694
694
  return;
695
695
  cy.get('.navigation-item-close', { timeout: 10000 }).click();
696
- cy.GLO_getVisible('.svy-message-dialog', 30000).should('exist');
697
- cy.get('.svy-message-dialog').should(($dialog) => {
696
+ cy.GLO_getVisible('.svy-message-dialog.active', 30000).should('exist');
697
+ cy.get('.svy-message-dialog.active').should(($dialog) => {
698
698
  expect($dialog.find('.window-title').text().trim()).to.match(/^(Confirm|Bevestigen)$/);
699
699
  expect($dialog.find('.window-body').text().trim()).to.match(/^(Close all programs\?|Sluit alle programma's\?)$/);
700
700
  });
701
- cy.get('.svy-message-dialog')
701
+ cy.get('.svy-message-dialog.active')
702
702
  .find('.svy-btn-primary')
703
703
  .contains(/^(Yes|Ja)$/)
704
704
  .should('exist')
@@ -774,22 +774,23 @@ Cypress.Commands.add('GLO_dialogChoice', (confirmation) => {
774
774
  cy.wait(500);
775
775
  cy.get('body').then(($body) => {
776
776
  let CSSSearchStr;
777
- if ($body.find('.svy-message-dialog').length > 0) {
778
- CSSSearchStr = '.svy-message-dialog button';
777
+ if ($body.find('.svy-message-dialog.active').length > 0) {
778
+ CSSSearchStr = '.svy-message-dialog.active button';
779
779
  }
780
780
  else if ($body.find('.servoycore-dialog-body').length > 0) {
781
781
  // Previous version
782
782
  CSSSearchStr = '.servoycore-dialog-body button';
783
783
  }
784
- else if ($body.find('.svy-dialog.window').length > 0) {
784
+ else if ($body.find('.svy-dialog.window.active').length > 0) {
785
785
  // Another variant
786
- CSSSearchStr = '.svy-dialog.window globiscomponents-button';
786
+ CSSSearchStr = '.svy-dialog.window.active globiscomponents-button';
787
787
  }
788
788
  else {
789
789
  cy.GLO_log('Popup not found, skipping dialog option');
790
790
  return;
791
791
  }
792
- if ($body.find('.window-title.type-error').length > 0 && $body.find('.window-title.type-error').is(':visible')) {
792
+ const $errorTitle = $body.find('.svy-message-dialog.active .window-title.type-error, .svy-dialog.window.active .window-title.type-error');
793
+ if ($errorTitle.length > 0 && $errorTitle.is(':visible')) {
793
794
  cy.GLO_log('Error dialog, failing test. use GLO_dialogRequiredCheck.');
794
795
  cy.wrap(null).should(() => {
795
796
  throw new Error('Error dialog, failing test. use GLO_dialogRequiredCheck.');
@@ -816,7 +817,7 @@ Cypress.Commands.add('GLO_dialogChoice', (confirmation) => {
816
817
  });
817
818
  });
818
819
  Cypress.Commands.add('GLO_addInputDialog', (text) => {
819
- cy.get('.svy-message-dialog .window-body form', { timeout: 15000 }).then(($form) => {
820
+ cy.get('.svy-message-dialog.active .window-body form', { timeout: 15000 }).then(($form) => {
820
821
  const inputType = $form.children().first().prop('tagName').toLowerCase();
821
822
  if (inputType === 'input') {
822
823
  cy.wrap($form).find('input').clear().type(text);
@@ -1000,7 +1001,7 @@ Cypress.Commands.add('GLO_switchCompany', (companyName) => {
1000
1001
  cy.GLO_getElement(['ng$main_form2', 'navbar_top']).find('#userroles-dropdown').click();
1001
1002
  cy.get('.dx-submenu').find(span).contains('Switch company').click();
1002
1003
  cy.GLO_checkLoadingIndicator();
1003
- cy.get('.svy-dialog').find('.dx-dropdowneditor-icon').click();
1004
+ cy.get('.svy-dialog.active').find('.dx-dropdowneditor-icon').click();
1004
1005
  cy.GLO_getVisible('.dx-scrollview-content').contains(companyName).click();
1005
1006
  cy.GLO_clickButton(['ng$login_companies_dlg', 'btn_save']);
1006
1007
  });
@@ -1210,12 +1211,12 @@ const selectFromPopupWindow = (value, columnId, equals = noEqualBool) => {
1210
1211
  const loadingColumnId = () => columnId
1211
1212
  ? cy.wrap(columnId)
1212
1213
  : cy
1213
- .get('.window-body:visible .ag-center-cols-container [row-index="0"] [role="gridcell"]', { timeout: 30000 })
1214
+ .get('.svy-dialog.active .window-body .ag-center-cols-container [row-index="0"] [role="gridcell"]', { timeout: 30000 })
1214
1215
  .filter((_, el) => Cypress.$(el).text().trim().length > 0)
1215
1216
  .first()
1216
1217
  .invoke('attr', 'col-id');
1217
1218
  // So we dont have to repeat the whole command everywhere, just looks better in code below.
1218
- const searchData = () => loadingColumnId().then((colId) => cy.get(`.window-body [row-index] [col-id="${colId}"]`, { timeout: loadTimeout }).should(($els) => {
1219
+ const searchData = () => loadingColumnId().then((colId) => cy.get(`.svy-dialog.active .window-body [row-index] [col-id="${colId}"]`, { timeout: loadTimeout }).should(($els) => {
1219
1220
  assert.equal($els.toArray().filter((item) => (item.textContent || '').trim() === '').length, 0, 'Grid cells should not have empty values');
1220
1221
  assert.isTrue(Cypress.$('.ag-loading').length === 0 && Cypress.$('loading-indicator').length === 0, '(Grid) loadingindicator is not visible');
1221
1222
  }));
@@ -1249,7 +1250,7 @@ const selectFromPopupWindow = (value, columnId, equals = noEqualBool) => {
1249
1250
  searchData()
1250
1251
  .then(($els) => Array.from($els, (el) => el.textContent.trim()))
1251
1252
  .as('beforeSearch');
1252
- cy.GLO_getVisible('.window-body').within(() => {
1253
+ cy.GLO_getVisible('.svy-dialog.active .window-body').within(() => {
1253
1254
  cy.GLO_getVisible(`.ag-header-cell[col-id="${columnId}"]`)
1254
1255
  .invoke('attr', 'aria-colindex')
1255
1256
  .then((ariaColIndex) => {
@@ -1268,13 +1269,13 @@ const selectFromPopupWindow = (value, columnId, equals = noEqualBool) => {
1268
1269
  }
1269
1270
  });
1270
1271
  }
1271
- cy.GLO_getVisible('.window-body').within(() => {
1272
+ cy.GLO_getVisible('.svy-dialog.active .window-body').within(() => {
1272
1273
  dblClickRowInGrid(span, value, columnId, equals);
1273
1274
  });
1274
1275
  }
1275
1276
  else {
1276
1277
  cy.log('Value already exists in the grid, skipping search.');
1277
- cy.GLO_getVisible('.window-body').within(() => {
1278
+ cy.GLO_getVisible('.svy-dialog.active .window-body').within(() => {
1278
1279
  dblClickRowInGrid(span, value, columnId, equals);
1279
1280
  });
1280
1281
  }
@@ -1302,7 +1303,7 @@ Cypress.Commands.add('GLO_popupWindow', (selector, value, columnId, equals = noE
1302
1303
  cy.GLO_checkLoadingIndicator();
1303
1304
  }
1304
1305
  cy.get('body').then(($body) => {
1305
- if ($body.find('.window-body').filter(':visible').length > 0) {
1306
+ if ($body.find('.svy-dialog.active .window-body').length > 0) {
1306
1307
  selectFromPopupWindow(value, columnId, equals);
1307
1308
  }
1308
1309
  else {
@@ -40,7 +40,7 @@ Cypress.Commands.add('GLT_goHome', (formname) => {
40
40
  cy.GLO_checkLoadingIndicator();
41
41
  });
42
42
  Cypress.Commands.add('GLT_closePopup', () => {
43
- cy.get('.svy-dialog .window-header .svy-dialog-close').click();
43
+ cy.get('.svy-dialog.active .window-header .svy-dialog-close').click();
44
44
  cy.get('.svy-dialog', { timeout: 60000 }).should('not.exist');
45
45
  });
46
46
  Cypress.Commands.add('GLT_clickButtonInButtonBar', (formName, title) => {
@@ -130,7 +130,7 @@ Cypress.Commands.add('GLT_getTreeListRows', (formName, elementName, filters) =>
130
130
  return processLevel(null, 0);
131
131
  });
132
132
  Cypress.Commands.add('GLT_addInputDialog', (text) => {
133
- cy.get('.svy-dialog .window-body, .svy-message-dialog .window-body', { timeout: 15000 })
133
+ cy.get('.svy-dialog.active .window-body, .svy-message-dialog.active .window-body', { timeout: 15000 })
134
134
  .should(($el) => {
135
135
  expect($el.find('input').length + $el.find('select').length, 'input or select present').to.be.greaterThan(0);
136
136
  })
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@globisnv/cypress-core",
3
- "version": "1.0.0",
3
+ "version": "1.1.0",
4
4
  "description": "Core building blocks for Globis Cypress E2E tests",
5
5
  "license": "UNLICENSED",
6
6
  "type": "module",