Skip to content

Commit 8b9454e

Browse files
hchonanDavertMik
authored andcommitted
Redis module default configuration must be more foolproof. (#4229)
* Minor (language) corrections (#4224) * Make redis module configuration more foolproof.
1 parent c7a6273 commit 8b9454e

File tree

1 file changed

+5
-6
lines changed

1 file changed

+5
-6
lines changed

src/Codeception/Module/Redis.php

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -20,8 +20,8 @@
2020
*
2121
* * **`host`** (`string`, default `'127.0.0.1'`) - The Redis host
2222
* * **`port`** (`int`, default `6379`) - The Redis port
23-
* * **`database`** (`int`, no default) - The Redis database. Needs to be explicitly specified.
24-
* * **`cleanupBefore`**: (`string`, default `'suite'`) - Whether/when to flush the database:
23+
* * **`database`** (`int`, no default) - The Redis database. Needs to be specified.
24+
* * **`cleanupBefore`**: (`string`, default `'never'`) - Whether/when to flush the database:
2525
* * `suite`: at the beginning of every suite
2626
* * `test`: at the beginning of every test
2727
* * Any other value: never
@@ -34,7 +34,7 @@
3434
* host: '127.0.0.1'
3535
* port: 6379
3636
* database: 0
37-
* cleanupBefore: 'test'
37+
* cleanupBefore: 'never'
3838
* ```
3939
*
4040
* ## Public Properties
@@ -48,13 +48,12 @@ class Redis extends CodeceptionModule implements RequiresPackage
4848
/**
4949
* {@inheritdoc}
5050
*
51-
* No default value is set for the database, as this module will delete
52-
* every data in it. The user is required to explicitly set this parameter.
51+
* No default value is set for the database, using this parameter.
5352
*/
5453
protected $config = [
5554
'host' => '127.0.0.1',
5655
'port' => 6379,
57-
'cleanupBefore' => 'test'
56+
'cleanupBefore' => 'never'
5857
];
5958

6059
/**

0 commit comments

Comments
 (0)