From f0d2ac0b5cb4a047da22f6701b3a3827b86a1bc7 Mon Sep 17 00:00:00 2001 From: Damien Retzinger Date: Sat, 2 May 2026 10:56:29 -0400 Subject: [PATCH] test(supported-version): assert single-element matrix shape for `latest` and `nightly` --- .../src/matrix/get-matrix-for-kind.spec.ts | 30 ++++++++++++++++++- .../magento-open-source/composite.json | 2 +- 2 files changed, 30 insertions(+), 2 deletions(-) diff --git a/supported-version/src/matrix/get-matrix-for-kind.spec.ts b/supported-version/src/matrix/get-matrix-for-kind.spec.ts index 7482ccf..a105022 100644 --- a/supported-version/src/matrix/get-matrix-for-kind.spec.ts +++ b/supported-version/src/matrix/get-matrix-for-kind.spec.ts @@ -11,6 +11,13 @@ describe('getMatrixForKind for mage-os', () => { expect(result.include).toBeDefined(); }); + it('returns a single-element matrix for with a matrix "magento" for `latest`', () => { + const result = getMatrixForKind("latest", project); + expect(result.magento.length).toEqual(1); + expect(result.include.length).toEqual(1); + expect(result.magento[0]).toEqual(result.include[0].magento); + }); + it('returns a matrix for `currently-supported`', () => { const result = getMatrixForKind("currently-supported", project); @@ -46,7 +53,14 @@ describe('getMatrixForKind for mage-os', () => { expect(result.magento).toBeDefined(); expect(result.include).toBeDefined(); }); - + + it('returns a single-element matrix for with a matrix "magento" for `nightly`', () => { + const result = getMatrixForKind("nightly", project); + expect(result.magento.length).toEqual(1); + expect(result.include.length).toEqual(1); + expect(result.magento[0]).toEqual(result.include[0].magento); + }); + it('errors for invalid `custom``', () => { expect(() => getMatrixForKind("custom", project)).toThrowError(); }); @@ -69,6 +83,13 @@ describe('getMatrixForKind for magento-open-source', () => { expect(result.include).toBeDefined(); }); + it('returns a single-element matrix for with a matrix "magento" for `latest`', () => { + const result = getMatrixForKind("latest", project); + expect(result.magento.length).toEqual(1); + expect(result.include.length).toEqual(1); + expect(result.magento[0]).toEqual(result.include[0].magento); + }); + it('returns a matrix for `currently-supported`', () => { const result = getMatrixForKind("currently-supported", project); @@ -97,6 +118,13 @@ describe('getMatrixForKind for magento-open-source', () => { expect(result.include).toBeDefined(); }); + it('returns a single-element matrix for with a matrix "magento" for `nightly`', () => { + const result = getMatrixForKind("nightly", project); + expect(result.magento.length).toEqual(1); + expect(result.include.length).toEqual(1); + expect(result.magento[0]).toEqual(result.include[0].magento); + }); + it('returns a matrix for valid multiple `custom`', () => { const result = getMatrixForKind("custom", project, "magento/project-community-edition:2.4.2,magento/project-community-edition:2.4.3"); diff --git a/supported-version/src/versions/magento-open-source/composite.json b/supported-version/src/versions/magento-open-source/composite.json index cb4eb0b..8c3382f 100644 --- a/supported-version/src/versions/magento-open-source/composite.json +++ b/supported-version/src/versions/magento-open-source/composite.json @@ -140,7 +140,7 @@ "eol": "2028-04-09T00:00:00+0000" }, "magento/project-community-edition": { - "magento": "magento/project-community-edition:>=2.4.8 <2.4.9", + "magento": "magento/project-community-edition", "php": 8.4, "composer": "2.8.12", "mysql": "mysql:8.4",