File tree Expand file tree Collapse file tree 2 files changed +10
-18
lines changed Expand file tree Collapse file tree 2 files changed +10
-18
lines changed Original file line number Diff line number Diff line change @@ -212,9 +212,7 @@ Finally, run
212
212
213
213
214
214
``` bash
215
- ddev exec BOUNCER_KEY=your-bouncer-key LAPI_URL=http://crowdsec:8080 MEMCACHED_DSN=memcached://memcached:11211
216
- REDIS_DSN=redis://redis:6379 /usr/bin/php ./my-own-modules/crowdsec-php-lib/vendor/bin/phpunit --testdox --colors
217
- --exclude-group ignore ./my-own-modules/crowdsec-php-lib/tests/Integration/IpVerificationTest.php
215
+ ddev exec BOUNCER_KEY=your-bouncer-key LAPI_URL=http://crowdsec:8080 MEMCACHED_DSN=memcached://memcached:11211 REDIS_DSN=redis://redis:6379 /usr/bin/php ./my-own-modules/crowdsec-php-lib/vendor/bin/phpunit --testdox --colors --exclude-group ignore ./my-own-modules/crowdsec-php-lib/tests/Integration/IpVerificationTest.php
218
216
```
219
217
220
218
For geolocation Unit Test, you should first put 2 free MaxMind databases in the ` tests ` folder : ` GeoLite2-City.mmdb `
@@ -363,16 +361,6 @@ ddev psalm ./my-own-modules/crowdsec-php-lib/tools/coding-standards ./my-own-mod
363
361
364
362
In order to generate a code coverage report, you have to:
365
363
366
- - Remove the old php unit version used to test on old php version:
367
- ``` bash
368
- ddev composer install --no-dev --working-dir ./my-own-modules/crowdsec-php-lib
369
- ```
370
-
371
- - Update composer dependency in the coding-standards folder:
372
- ``` bash
373
- ddev composer update --working-dir=./my-own-modules/crowdsec-php-lib/tools/coding-standards
374
- ```
375
-
376
364
- Enable ` xdebug ` :
377
365
``` bash
378
366
ddev xdebug
Original file line number Diff line number Diff line change 7
7
"squizlabs/php_codesniffer" : " @stable" ,
8
8
"vimeo/psalm" : " @stable" ,
9
9
"phpunit/phpunit" : " ^9.3" ,
10
- "phpunit/php-code-coverage" : " @stable"
10
+ "phpunit/php-code-coverage" : " @stable" ,
11
+ "crowdsec/bouncer" : " @dev"
11
12
},
12
13
"autoload" : {
13
- "files" : [" ../../vendor/autoload.php" ]
14
- },
15
- "autoload-dev" : {
16
14
"psr-4" : {
17
15
"CrowdSecBouncer\\ Tests\\ " : " ../../tests/"
18
16
}
17
+ },
18
+ "repositories" : {
19
+ "crowdsec-bouncer-lib" : {
20
+ "type" : " path" ,
21
+ "url" : " ../../"
22
+ }
19
23
}
20
- }
24
+ }
You can’t perform that action at this time.
0 commit comments