From 1a4996d52efaef19aac3b839432425f778ae1c01 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ph=C3=A9na=20Proxima?= <adam@phenaproxima.net> Date: Thu, 27 Apr 2023 10:29:40 -0400 Subject: [PATCH] Add a comment --- .../tests/src/Kernel/ComposerPluginsValidatorTest.php | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/package_manager/tests/src/Kernel/ComposerPluginsValidatorTest.php b/package_manager/tests/src/Kernel/ComposerPluginsValidatorTest.php index 9a20576a60..30f78859c3 100644 --- a/package_manager/tests/src/Kernel/ComposerPluginsValidatorTest.php +++ b/package_manager/tests/src/Kernel/ComposerPluginsValidatorTest.php @@ -104,6 +104,16 @@ class ComposerPluginsValidatorTest extends PackageManagerKernelTestBase { /** * Tests adding a plugin that's not allowed by the allow-plugins config. + * + * The exception that this test looks for is not necessarily triggered by + * ComposerPluginsValidator; Composer will exit with an error if there is an + * installed plugin that is not allowed by the `allow-plugins` config. In + * practice, this means that whichever validator is the first one to do a + * Composer operation (via ComposerInspector) will get the exception -- it + * may or may not be ComposerPluginsValidator. + * + * This test is here to ensure that Composer's behavior remains consistent, + * even if we're not explicitly testing ComposerPluginsValidator here. */ public function testAddDisallowedPlugin(): void { $this->getStageFixtureManipulator() -- GitLab