Merge branch 'dev' into 8824-showCreditGrade
gitea/salix-front/pipeline/pr-dev This commit looks good
Details
gitea/salix-front/pipeline/pr-dev This commit looks good
Details
This commit is contained in:
commit
7325b68bd9
|
@ -44,7 +44,7 @@ export async function findImports(targetFile, visited = new Set(), identation =
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
|
|
||||||
return getUniques(fullTree); // Remove duplicates
|
return getUniques([...fullTree, targetFile]); // Remove duplicates
|
||||||
}
|
}
|
||||||
|
|
||||||
function getUniques(array) {
|
function getUniques(array) {
|
||||||
|
|
|
@ -25,7 +25,7 @@ async function getChangedModules() {
|
||||||
if (change.startsWith(E2E_PATH)) changedArray.push(change);
|
if (change.startsWith(E2E_PATH)) changedArray.push(change);
|
||||||
changedModules = new Set(changedArray);
|
changedModules = new Set(changedArray);
|
||||||
}
|
}
|
||||||
return [...changedModules].join('\n');
|
return cleanSpecs(changedModules).join('\n');
|
||||||
}
|
}
|
||||||
|
|
||||||
getChangedModules()
|
getChangedModules()
|
||||||
|
@ -34,3 +34,20 @@ getChangedModules()
|
||||||
console.error(e);
|
console.error(e);
|
||||||
process.exit(1);
|
process.exit(1);
|
||||||
});
|
});
|
||||||
|
|
||||||
|
function cleanSpecs(changedModules) {
|
||||||
|
let specifics = [];
|
||||||
|
const modules = [];
|
||||||
|
for (const changed of changedModules) {
|
||||||
|
if (changed.endsWith('*.spec.js')) {
|
||||||
|
modules.push(changed);
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
specifics.push(changed);
|
||||||
|
}
|
||||||
|
specifics = specifics.filter(
|
||||||
|
(spec) => !modules.some((module) => spec.startsWith(module.split('**')[0])),
|
||||||
|
);
|
||||||
|
|
||||||
|
return [...modules, ...specifics];
|
||||||
|
}
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
describe('InvoiceInList', () => {
|
describe('InvoiceInList', () => {
|
||||||
const firstRow = 'tbody.q-virtual-scroll__content tr:nth-child(1)';
|
const firstRow = 'tbody.q-virtual-scroll__content tr:nth-child(1)';
|
||||||
const firstId = `${firstRow} > td:nth-child(2) span`;
|
const firstId = `${firstRow} > td:nth-child(2) span`;
|
||||||
const firstDetailBtn = `${firstRow} .q-btn:nth-child(1)`;
|
const invoiceId = '6';
|
||||||
const summaryHeaders = (opt) => `.summaryBody > .${opt} > .q-pb-lg > .header-link`;
|
const summaryHeaders = (opt) => `.summaryBody > .${opt} > .q-pb-lg > .header-link`;
|
||||||
const mockInvoiceRef = `createMockInvoice${Math.floor(Math.random() * 100)}`;
|
const mockInvoiceRef = `createMockInvoice${Math.floor(Math.random() * 100)}`;
|
||||||
const mock = {
|
const mock = {
|
||||||
|
@ -31,7 +31,13 @@ describe('InvoiceInList', () => {
|
||||||
});
|
});
|
||||||
|
|
||||||
it('should open the details', () => {
|
it('should open the details', () => {
|
||||||
cy.get(firstDetailBtn).click();
|
cy.get('[data-col-field="id"]').then(($cells) => {
|
||||||
|
const exactMatch = [...$cells].find(
|
||||||
|
(cell) => cell.textContent.trim() === invoiceId,
|
||||||
|
);
|
||||||
|
expect(exactMatch).to.exist;
|
||||||
|
cy.wrap(exactMatch).closest('tr').find('.q-btn:nth-child(1)').click();
|
||||||
|
});
|
||||||
cy.get(summaryHeaders('max-width')).contains('Basic data');
|
cy.get(summaryHeaders('max-width')).contains('Basic data');
|
||||||
cy.get(summaryHeaders('vat')).contains('Vat');
|
cy.get(summaryHeaders('vat')).contains('Vat');
|
||||||
});
|
});
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
describe('Route extended list', () => {
|
describe.skip('Route extended list', () => {
|
||||||
const getSelector = (colField) => `tr:last-child > [data-col-field="${colField}"]`;
|
const getSelector = (colField) => `tr:last-child > [data-col-field="${colField}"]`;
|
||||||
|
|
||||||
const selectors = {
|
const selectors = {
|
||||||
|
|
Loading…
Reference in New Issue