Skip to content

Commit 08fc3da

Browse files
lapistanoadri
authored andcommitted
Refactored: moved white- and blacklist definition to configuration
1 parent d2d5c16 commit 08fc3da

File tree

1 file changed

+12
-10
lines changed

1 file changed

+12
-10
lines changed

soap/test/bootstrap.php

Lines changed: 12 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,20 @@
11
<?php
22

3+
if (!file_exists(__DIR__ . "/../../vendor/autoload.php")) {
4+
die(
5+
"\n[ERROR] You need to run composer before running the test suite.\n".
6+
"To do so run the following commands:\n".
7+
" curl -s http://getcomposer.org/installer | php\n".
8+
" php composer.phar install\n\n"
9+
);
10+
}
11+
312
require_once __DIR__ . '/../../vendor/autoload.php';
413

514
\VCR\VCR::configure()
615
->setCassettePath('test/fixtures')
716
->enableLibraryHooks(array('soap'))
8-
->setWhitelist(['vendor/guzzle', 'vendor/willdurand', 'vendor/ruflin'])
9-
->setBlacklist(['vendor/adri/']);
10-
11-
12-
13-
// soap, curl
14-
\VCR\LibraryHooks\Wrapper::interceptIncludes(
15-
whitelist: ['vendor/guzzle', 'vendor/willdurand', 'vendor/ruflin'],
16-
blacklist: ['vendor/adri/']
17-
);
17+
->setWhitelist(array('vendor/guzzle', 'vendor/willdurand', 'vendor/ruflin'))
18+
->setBlacklist(array('vendor/adri/'));
1819

20+
\VCR\VCR::turnOn();

0 commit comments

Comments
 (0)