From 08122eb1d6b4f9a9dbf4292001bc83d1eaec16fe Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Connor=20B=C3=A4r?= Date: Thu, 14 Mar 2024 13:52:01 +0100 Subject: [PATCH] Extend version range for eslint-plugin-playwright (#954) --- .changeset/green-crabs-drum.md | 5 +++++ src/lib/options.spec.ts | 8 ++++---- src/lib/options.ts | 4 ++-- 3 files changed, 11 insertions(+), 6 deletions(-) create mode 100644 .changeset/green-crabs-drum.md diff --git a/.changeset/green-crabs-drum.md b/.changeset/green-crabs-drum.md new file mode 100644 index 00000000..dafde1df --- /dev/null +++ b/.changeset/green-crabs-drum.md @@ -0,0 +1,5 @@ +--- +"@sumup/foundry": minor +--- + +Extended the supported version range for `eslint-plugin-playwright` to include v1.x. diff --git a/src/lib/options.spec.ts b/src/lib/options.spec.ts index ced1ed24..67bd1909 100644 --- a/src/lib/options.spec.ts +++ b/src/lib/options.spec.ts @@ -271,7 +271,7 @@ describe('options', () => { expect(logger.warn).toHaveBeenCalledOnce(); expect(logger.warn).toHaveBeenCalledWith( - '"eslint-config-next" is installed at version "^9.0.0". Foundry has only been tested with versions ">=10.0.0". You may find that it works just fine, or you may not.', + '"eslint-config-next" is installed at version "^9.0.0". Foundry has only been tested with versions ">=10.0.0". You may find that it works just fine, or you may not. Pull requests welcome!', ); }); @@ -279,14 +279,14 @@ describe('options', () => { const packageJson = { ...basePackageJson, license: 'MIT', - dependencies: { 'eslint-plugin-playwright': '^1.0.0' }, + dependencies: { 'eslint-plugin-playwright': '^2.0.0' }, }; warnAboutUnsupportedPlugins(packageJson); expect(logger.warn).toHaveBeenCalledOnce(); expect(logger.warn).toHaveBeenCalledWith( - '"eslint-plugin-playwright" is installed at version "^1.0.0". Foundry has only been tested with versions ">=0.17.0 <1.0.0". You may find that it works just fine, or you may not.', + '"eslint-plugin-playwright" is installed at version "^2.0.0". Foundry has only been tested with versions ">=0.17.0 <2.0.0". You may find that it works just fine, or you may not. Pull requests welcome!', ); }); @@ -304,7 +304,7 @@ describe('options', () => { expect(logger.warn).toHaveBeenCalledOnce(); expect(logger.warn).toHaveBeenCalledWith( - '"@sumup/eslint-plugin-circuit-ui" is installed at version "1.0.0". Foundry has only been tested with versions ">=3.0.0 <5.0.0". You may find that it works just fine, or you may not.', + '"@sumup/eslint-plugin-circuit-ui" is installed at version "1.0.0". Foundry has only been tested with versions ">=3.0.0 <5.0.0". You may find that it works just fine, or you may not. Pull requests welcome!', ); }); diff --git a/src/lib/options.ts b/src/lib/options.ts index c14cfb2d..0d04dd1e 100644 --- a/src/lib/options.ts +++ b/src/lib/options.ts @@ -82,7 +82,7 @@ const PLUGINS = [ name: Plugin.PLAYWRIGHT, frameworkPackages: ['@playwright/test'], pluginPackage: 'eslint-plugin-playwright', - supportedRange: '>=0.17.0 <1.0.0', + supportedRange: '>=0.17.0 <2.0.0', }, { name: Plugin.STORYBOOK, @@ -202,7 +202,7 @@ export function warnAboutUnsupportedPlugins(packageJson: PackageJson): void { if (!isSupported) { logger.warn( - `"${pluginPackage}" is installed at version "${version}". Foundry has only been tested with versions "${supportedRange}". You may find that it works just fine, or you may not.`, + `"${pluginPackage}" is installed at version "${version}". Foundry has only been tested with versions "${supportedRange}". You may find that it works just fine, or you may not. Pull requests welcome!`, ); } } catch (error) {