final iteration

This commit is contained in:
Matthew Rathbone
2024-04-12 21:44:15 -05:00
parent 221536346c
commit 78df9085b2
2 changed files with 18 additions and 9 deletions

View File

@@ -59,7 +59,7 @@ jobs:
integration:
name: test - ${{ split(matrix.chunk)[-1] }}
name: test - ${{ matrix.chunk[0] }}
runs-on: ubuntu-latest
needs:
- setup
@@ -76,10 +76,18 @@ jobs:
node-version-file: '.nvmrc'
cache: yarn
- name: Install dependencies
run: yarn install --frozen-lockfile
- name: yarn install (with retry)
uses: nick-fields/retry@v2
with:
timeout_minutes: 20
max_attempts: 3
command: "yarn install --frozen-lockfile --network-timeout 100000"
- name: Integration Tests
run: yarn workspace beekeeper-studio run test:integration --runInBand --ci --silent ${{ matrix.chunk }}
- name: Test
uses: nick-fields/retry@v2
with:
timeout_minutes: 20
max_attempts: 3
command: yarn workspace beekeeper-studio run test:integration --runInBand --ci --silent ${{ matrix.chunk[1] }}
env:
TESTCONTAINERS_RYUK_DISABLED: true

View File

@@ -1,8 +1,9 @@
#!/bin/bash
# Use $(...) for command substitution
# Use $(...) for command substitution to capture output of find command
FILES=$(find apps/studio/tests/integration/lib/db -name "*spec.js")
# Convert to JSON array directly
JSON=$(echo "$FILES" | jq -Rsc 'split("\n") | if last == "" then .[:-1] else . end')
echo "$JSON"
# Convert output to a JSON array of arrays with filename and full path
JSON=$(echo "$FILES" | jq -Rsc 'split("\n") | map(select(. != "") | [(. | split("/") | last), .])')
echo "$JSON"