Skip to content

Commit a16f9ad

Browse files
committed
ACP2E-1451: Non-default configurations added as env variables break config import
1 parent d0c0165 commit a16f9ad

File tree

1 file changed

+21
-0
lines changed
  • dev/tests/integration/testsuite/Magento/Config/App/Config/Type

1 file changed

+21
-0
lines changed

dev/tests/integration/testsuite/Magento/Config/App/Config/Type/SystemTest.php

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -47,4 +47,25 @@ public function testGetValueDefaultScope()
4747
$this->system->get('stores/default/web/test/test_value_1')
4848
);
4949
}
50+
51+
/**
52+
* Tests that configurations added as env variables don't cause the error 'Recursion detected'
53+
* after cleaning the cache.
54+
*
55+
* @return void
56+
*/
57+
public function testEnvGetValueStoreScope()
58+
{
59+
$this->system->clean();
60+
$_ENV['CONFIG__STORES__DEFAULT__ABC__QRS__XYZ'] = 'test_env_value';
61+
62+
$this->assertEquals(
63+
'value1.db.default.test',
64+
$this->system->get('default/web/test/test_value_1')
65+
);
66+
$this->assertEquals(
67+
'test_env_value',
68+
$this->system->get('stores/default/abc/qrs/xyz')
69+
);
70+
}
5071
}

0 commit comments

Comments
 (0)