File tree Expand file tree Collapse file tree 6 files changed +74
-3
lines changed
Tests/Functional/Fixtures Expand file tree Collapse file tree 6 files changed +74
-3
lines changed Original file line number Diff line number Diff line change
1
+ <?php
2
+
3
+ namespace FOS \HttpCacheBundle \Tests \Functional \Fixtures \Controller ;
4
+
5
+ use Symfony \Bundle \FrameworkBundle \Controller \Controller ;
6
+ use Symfony \Component \HttpFoundation \Response ;
7
+
8
+ class TestController extends Controller
9
+ {
10
+ public function testAction ()
11
+ {
12
+ return new Response ('hello ' );
13
+ }
14
+ }
Original file line number Diff line number Diff line change
1
+ <?php
2
+
3
+ use Symfony \Component \Config \Loader \LoaderInterface ;
4
+ use Symfony \Component \HttpKernel \Kernel ;
5
+
6
+ class AppKernel extends Kernel
7
+ {
8
+ /**
9
+ * {@inheritdoc}
10
+ */
11
+ public function registerBundles ()
12
+ {
13
+ return array (
14
+ new \Symfony \Bundle \FrameworkBundle \FrameworkBundle (),
15
+ new \Symfony \Bundle \MonologBundle \MonologBundle (),
16
+ new \FOS \HttpCacheBundle \FOSHttpCacheBundle (),
17
+ );
18
+ }
19
+
20
+ /**
21
+ * {@inheritdoc}
22
+ */
23
+ public function registerContainerConfiguration (LoaderInterface $ loader )
24
+ {
25
+ $ loader ->load (__DIR__ .'/config/config.yml ' );
26
+ }
27
+
28
+ /**
29
+ * {@inheritdoc}
30
+ */
31
+ public function getCacheDir ()
32
+ {
33
+ return sys_get_temp_dir ().'/fos/cache ' ;
34
+ }
35
+
36
+ /**
37
+ * {@inheritdoc}
38
+ */
39
+ public function getLogDir ()
40
+ {
41
+ return sys_get_temp_dir ().'/fos/logs ' ;
42
+ }
43
+ }
Original file line number Diff line number Diff line change
1
+ framework :
2
+ secret : fos
3
+ router :
4
+ resource : " %kernel.root_dir%/config/routing.yml"
5
+ test : ~
6
+
7
+ fos_http_cache :
8
+ varnish :
9
+ ips : 192.168.0.1
Original file line number Diff line number Diff line change
1
+ test :
2
+ pattern : /test
3
+ defaults : { _controller: FOS\HttpCacheBundle\Tests\Functional\Fixtures\Controller\TestController::testAction }
Original file line number Diff line number Diff line change 31
31
"mockery/mockery" : " 0.8.*" ,
32
32
"monolog/monolog" : " *" ,
33
33
"sensio/framework-extra-bundle" : " ~2.3" ,
34
- "symfony/console " : " ~2.3" ,
34
+ "symfony/symfony " : " ~2.3" ,
35
35
"symfony/security" : " ~2.3" ,
36
- "symfony/expression-language" : " ~2.4"
36
+ "symfony/expression-language" : " ~2.4" ,
37
+ "symfony/monolog-bundle" : " ~2.3"
37
38
},
38
39
"suggest" : {
39
40
"guzzle/http" : " For sending invalidation requests" ,
Original file line number Diff line number Diff line change 28
28
</filter >
29
29
30
30
<listeners >
31
- <listener class =" \Mockery\Adapter\Phpunit\TestListener" ></ listener >
31
+ <listener class =" \Mockery\Adapter\Phpunit\TestListener" / >
32
32
<listener class =" \FOS\HttpCacheBundle\Tests\Functional\WebServerListener" >
33
33
<arguments >
34
34
<string >functional</string >
37
37
</listeners >
38
38
39
39
<php >
40
+ <server name =" KERNEL_DIR" value =" ./Tests/Functional/Fixtures/app" />
40
41
<const name =" WEB_SERVER_HOST" value =" localhost" />
41
42
<const name =" WEB_SERVER_PORT" value =" 8000" />
42
43
<const name =" WEB_SERVER_DOCROOT" value =" ./Tests/Functional/Fixtures/web" />
You can’t perform that action at this time.
0 commit comments