From 84e3f2dd70f40496dc0c69a1d826c7ddebaff6e7 Mon Sep 17 00:00:00 2001 From: Tom Carrio Date: Tue, 28 Oct 2025 12:49:25 -0400 Subject: [PATCH 1/2] fix: incorrect arg count constructing SplitView in LocalhostSplitManager --- src/SplitIO/Sdk/Manager/LocalhostSplitManager.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/SplitIO/Sdk/Manager/LocalhostSplitManager.php b/src/SplitIO/Sdk/Manager/LocalhostSplitManager.php index 3628f95..799338b 100644 --- a/src/SplitIO/Sdk/Manager/LocalhostSplitManager.php +++ b/src/SplitIO/Sdk/Manager/LocalhostSplitManager.php @@ -66,7 +66,9 @@ public function splits() false, $this->splits[$featureFlagName]["treatments"], 0, - $configs + $configs, + null, + array() ); } } From 87e1ac5625f4b481a18fec88ab7ec596ed9d0714 Mon Sep 17 00:00:00 2001 From: Tom Carrio Date: Tue, 28 Oct 2025 13:15:28 -0400 Subject: [PATCH 2/2] test: add regression test to tests suite This provides regression coverage that the LocalhostSplitManager is providing sufficient arguments to the SplitView constructor, both validating and ensuring no regressions of issue #240. Ref: https://github.com/splitio/php-client/issues/240 --- tests/Suite/Sdk/LocalhostSplitManagerTest.php | 24 +++++++++++++++++++ 1 file changed, 24 insertions(+) create mode 100644 tests/Suite/Sdk/LocalhostSplitManagerTest.php diff --git a/tests/Suite/Sdk/LocalhostSplitManagerTest.php b/tests/Suite/Sdk/LocalhostSplitManagerTest.php new file mode 100644 index 0000000..c532f29 --- /dev/null +++ b/tests/Suite/Sdk/LocalhostSplitManagerTest.php @@ -0,0 +1,24 @@ +splits(); + $this->assertCount(0, $splitViews); + } +} \ No newline at end of file