From 2ce94ea6324216fcded8c6c9f47d65db0179aca2 Mon Sep 17 00:00:00 2001 From: Jordan Welch Date: Wed, 4 Feb 2026 08:31:34 +0100 Subject: [PATCH 1/4] test: add type workflow --- .github/workflows/automated-tests.yaml | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/.github/workflows/automated-tests.yaml b/.github/workflows/automated-tests.yaml index 56bf6292..248fc815 100644 --- a/.github/workflows/automated-tests.yaml +++ b/.github/workflows/automated-tests.yaml @@ -31,3 +31,19 @@ jobs: - name: Check linting run: node --run lint - run: echo "🍏 This job's status is ${{ job.status }}." + + unit-tests: + runs-on: ubuntu-slim + timeout-minutes: 10 + steps: + - name: Check out repository code + uses: actions/checkout@v6 + - name: Use Node.js + uses: actions/setup-node@v6 + with: + node-version: lts/* + cache: npm + - name: Install dependencies + run: npm ci + - name: Run Unit Tests + run: npm run test:unit From 912d7a9bf7d555f03920161653feda31fb78687a Mon Sep 17 00:00:00 2001 From: Jordan Welch Date: Wed, 4 Feb 2026 08:31:34 +0100 Subject: [PATCH 2/4] test: fix test assertion for `webp` default --- scripts/shared/__tests__/deterministic-output.test.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/shared/__tests__/deterministic-output.test.js b/scripts/shared/__tests__/deterministic-output.test.js index 7a2f5128..a4841e67 100644 --- a/scripts/shared/__tests__/deterministic-output.test.js +++ b/scripts/shared/__tests__/deterministic-output.test.js @@ -118,10 +118,10 @@ describe("deterministic-output", () => { assert.strictEqual(name, "MMM-Test---example.png"); }); - it("should use default jpg extension", () => { + it("should use default webp extension", () => { const name = createDeterministicImageName("MMM-Test", "example"); - assert.strictEqual(name, "MMM-Test---example.jpg"); + assert.strictEqual(name, "MMM-Test---example.webp"); }); it("should be human-readable", () => { From ef8389c17f9ee40a23c0acf3070f16047fcff708 Mon Sep 17 00:00:00 2001 From: Jordan Welch Date: Wed, 4 Feb 2026 08:31:35 +0100 Subject: [PATCH 3/4] test: run all tests --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index 70bf55d9..510dbe5a 100644 --- a/package.json +++ b/package.json @@ -46,7 +46,7 @@ "lint:fix": "eslint --fix && prettier . --write", "prepare": "simple-git-hooks", "test": "node --run test:fixtures && node --run lint && node --run golden:check && node --run schemas:check && node --run test:unit && node --run test:spelling", - "test:unit": "node --test scripts/shared/__tests__/**/*.test.js && node --test scripts/check-modules/__tests__/**/*.test.js && node --test scripts/check-modules/compare/__tests__/**/*.test.js", + "test:unit": "node --test scripts/**/__tests__/**/*.test.js", "test:spelling": "cspell .", "leaveMenu": "echo 'Leaving menu...'" }, From 998127e320af78162818e40e2dda70c6b67f9e6b Mon Sep 17 00:00:00 2001 From: Kristjan ESPERANTO <35647502+KristjanESPERANTO@users.noreply.github.com> Date: Wed, 4 Feb 2026 14:51:33 +0100 Subject: [PATCH 4/4] chore: run all steps in one job Removed unit tests job and integrated code-style checks into CI job. --- .github/workflows/automated-tests.yaml | 18 ++---------------- 1 file changed, 2 insertions(+), 16 deletions(-) diff --git a/.github/workflows/automated-tests.yaml b/.github/workflows/automated-tests.yaml index 248fc815..423034e9 100644 --- a/.github/workflows/automated-tests.yaml +++ b/.github/workflows/automated-tests.yaml @@ -9,7 +9,7 @@ permissions: contents: read jobs: - code-style-check: + ci: runs-on: ubuntu-slim timeout-minutes: 10 steps: @@ -30,20 +30,6 @@ jobs: run: node --run test:spelling - name: Check linting run: node --run lint - - run: echo "🍏 This job's status is ${{ job.status }}." - - unit-tests: - runs-on: ubuntu-slim - timeout-minutes: 10 - steps: - - name: Check out repository code - uses: actions/checkout@v6 - - name: Use Node.js - uses: actions/setup-node@v6 - with: - node-version: lts/* - cache: npm - - name: Install dependencies - run: npm ci - name: Run Unit Tests run: npm run test:unit + - run: echo "🍏 This job's status is ${{ job.status }}."