Cleanup runTime.ts

This commit is contained in:
Sidharth Vinod
2024-01-26 02:07:55 +05:30
parent dc476233ba
commit 781945325d
2 changed files with 10 additions and 17 deletions

View File

@@ -69,9 +69,6 @@ jobs:
start: pnpm run dev start: pnpm run dev
wait-on: 'http://localhost:9000' wait-on: 'http://localhost:9000'
browser: chrome browser: chrome
spec: |
cypress/integration/rendering/classDiagram.spec.js
cypress/integration/rendering/flowchart-v2.spec.js
- name: Move runtime data - name: Move runtime data
if: ${{ steps.cache-snapshot.outputs.cache-hit != 'true' }} if: ${{ steps.cache-snapshot.outputs.cache-hit != 'true' }}
@@ -148,9 +145,6 @@ jobs:
# e.g. if this action was run from a fork # e.g. if this action was run from a fork
record: ${{ secrets.CYPRESS_RECORD_KEY != '' }} record: ${{ secrets.CYPRESS_RECORD_KEY != '' }}
parallel: ${{ secrets.CYPRESS_RECORD_KEY != '' }} parallel: ${{ secrets.CYPRESS_RECORD_KEY != '' }}
spec: |
cypress/integration/rendering/classDiagram.spec.js
cypress/integration/rendering/flowchart-v2.spec.js
env: env:
CYPRESS_RECORD_KEY: ${{ secrets.CYPRESS_RECORD_KEY }} CYPRESS_RECORD_KEY: ${{ secrets.CYPRESS_RECORD_KEY }}
VITEST_COVERAGE: true VITEST_COVERAGE: true

View File

@@ -114,19 +114,18 @@ const htmlTable = (data: string[][]): string => {
let table = `<table border='1' style="border-collapse: collapse">`; let table = `<table border='1' style="border-collapse: collapse">`;
// Generate table header // Generate table header
table += '<tr>'; table += `<tr>
for (const header of data[0]) { ${data
table += `<th>${header}</th>`; .shift()!
} .map((header) => `<th>${header}</th>`)
table += '</tr>'; .join('')}
</tr>`;
// Generate table rows // Generate table rows
for (let i = 1; i < data.length; i++) { for (const row of data) {
table += '<tr>'; table += `<tr>
for (let j = 0; j < data[i].length; j++) { ${row.map((cell) => `<td>${cell}</td>`).join('')}
table += `<td>${data[i][j]}</td>`; </tr>`;
}
table += '</tr>';
} }
table += '</table>'; table += '</table>';