File tree Expand file tree Collapse file tree 4 files changed +12
-11
lines changed Expand file tree Collapse file tree 4 files changed +12
-11
lines changed Original file line number Diff line number Diff line change 1616matrix :
1717 include :
1818 - php : 5.6
19+ env :
20+ - COMPOSER_FLAGS="--prefer-lowest --prefer-stable"
1921 - php : 7.0
2022 - php : 7.1
2123 env : COVERAGE="--coverage-clover build/logs/clover.xml"
@@ -25,7 +27,7 @@ before_install:
2527 - travis_retry composer self-update
2628
2729install :
28- - travis_retry composer update --no-interaction --prefer-dist
30+ - travis_retry composer update ${COMPOSER_FLAGS} --no-interaction --prefer-dist
2931
3032script :
3133 - vendor/bin/phpunit $COVERAGE
Original file line number Diff line number Diff line change 44 "require" : {
55 "php" : " ^5.6 || ^7.0" ,
66 "nette/di" : " ^2.3" ,
7- "nette/robot-loader" : " ^2.3 "
7+ "nette/robot-loader" : " ^2.4.2|^3.0 "
88 },
99 "require-dev" : {
1010 "phpunit/phpunit" : " ^5.7" ,
2424 "Fmasa\\ " : " src/"
2525 }
2626 },
27+ "autoload-dev" : {
28+ "classmap" : [
29+ " tests/fixtures/"
30+ ]
31+ },
2732 "minimum-stability" : " stable"
2833}
Original file line number Diff line number Diff line change @@ -15,17 +15,20 @@ class AutoDIExtension extends CompilerExtension
1515 '%appDir% ' ,
1616 ],
1717 'defaults ' => [],
18+ 'tempDir ' => '%tempDir% ' ,
1819 ];
1920
2021 public function beforeCompile ()
2122 {
2223 $ config = $ this ->getConfig ($ this ->defaults );
2324
2425 $ robotLoader = new RobotLoader ();
26+
2527 foreach ($ config ['directories ' ] as $ directory ) {
2628 $ robotLoader ->addDirectory ($ directory );
2729 }
2830
31+ $ robotLoader ->setTempDirectory ($ config ['tempDir ' ]);
2932 $ robotLoader ->rebuild ();
3033
3134 $ classes = new ClassList (
Original file line number Diff line number Diff line change 22
33namespace Fmasa \AutoDI ;
44
5- use Nette \Loaders \RobotLoader ;
65use PHPUnit \Framework \TestCase ;
76use Fmasa \AutoDI \Tests ;
87
@@ -16,14 +15,6 @@ class ClassListTest extends TestCase
1615 Tests \Dir01 \SimpleService \AnotherService::class,
1716 ];
1817
19- protected function setUp ()
20- {
21- $ loader = new RobotLoader ();
22- $ loader ->addDirectory (__DIR__ . '/fixtures ' );
23- $ loader ->setTempDirectory (__DIR__ . '/temp ' );
24- $ loader ->register ();
25- }
26-
2718 public function testClassFilterWithDirectoryWildcard ()
2819 {
2920 $ filter = new ClassList (self ::CLASSES );
You can’t perform that action at this time.
0 commit comments