File tree Expand file tree Collapse file tree 2 files changed +12
-0
lines changed Expand file tree Collapse file tree 2 files changed +12
-0
lines changed Original file line number Diff line number Diff line change @@ -197,6 +197,9 @@ public function testSetsDefaultValues(): void
197
197
#[RunInSeparateProcess]
198
198
public function testSetsDefaultValuesEncryptionUsingHex2Bin (): void
199
199
{
200
+ putenv ('encryption.key ' );
201
+ unset($ _ENV ['encryption.key ' ], $ _SERVER ['encryption.key ' ]); // @phpstan-ignore codeigniter.superglobalAccess
202
+
200
203
$ dotenv = new DotEnv ($ this ->fixturesFolder , 'encryption.env ' );
201
204
$ dotenv ->load ();
202
205
$ config = new Encryption ();
@@ -210,6 +213,9 @@ public function testSetsDefaultValuesEncryptionUsingHex2Bin(): void
210
213
#[RunInSeparateProcess]
211
214
public function testSetDefaultValuesEncryptionUsingBase64 (): void
212
215
{
216
+ putenv ('encryption.key ' );
217
+ unset($ _ENV ['encryption.key ' ], $ _SERVER ['encryption.key ' ]); // @phpstan-ignore codeigniter.superglobalAccess
218
+
213
219
$ dotenv = new DotEnv ($ this ->fixturesFolder , 'base64encryption.env ' );
214
220
$ dotenv ->load ();
215
221
$ config = new Encryption ('base64 ' );
Original file line number Diff line number Diff line change @@ -90,6 +90,9 @@ public static function provideLoadsVars(): iterable
90
90
#[RunInSeparateProcess]
91
91
public function testLoadsHex2Bin (): void
92
92
{
93
+ putenv ('encryption.key ' );
94
+ unset($ _ENV ['encryption.key ' ], $ _SERVER ['encryption.key ' ]); // @phpstan-ignore codeigniter.superglobalAccess
95
+
93
96
$ dotenv = new DotEnv ($ this ->fixturesFolder , 'encryption.env ' );
94
97
$ dotenv ->load ();
95
98
@@ -102,6 +105,9 @@ public function testLoadsHex2Bin(): void
102
105
#[RunInSeparateProcess]
103
106
public function testLoadsBase64 (): void
104
107
{
108
+ putenv ('encryption.key ' );
109
+ unset($ _ENV ['encryption.key ' ], $ _SERVER ['encryption.key ' ]); // @phpstan-ignore codeigniter.superglobalAccess
110
+
105
111
$ dotenv = new DotEnv ($ this ->fixturesFolder , 'base64encryption.env ' );
106
112
$ dotenv ->load ();
107
113
You can’t perform that action at this time.
0 commit comments