File tree Expand file tree Collapse file tree 5 files changed +11
-10
lines changed Expand file tree Collapse file tree 5 files changed +11
-10
lines changed Original file line number Diff line number Diff line change @@ -11,6 +11,7 @@ See also the [GitHub releases page](https://github.com/FriendsOfSymfony/FOSHttpC
11
11
calling ` setPurgeLocation() ` .
12
12
* In ProxyTestCase, ` getHttpClient() ` has been replaced with ` getHttpAdapter() ` ;
13
13
added HTTP method parameter to ` getResponse() ` .
14
+ * Changed default Varnish version to 4.
14
15
15
16
1.4.0
16
17
-----
Original file line number Diff line number Diff line change @@ -80,7 +80,7 @@ Constant Getter Default
80
80
``VARNISH_PORT `` ``getCachingProxyPort() `` ``6181 `` port Varnish listens on
81
81
``VARNISH_MGMT_PORT `` ``getVarnishMgmtPort() `` ``6182 `` Varnish management port
82
82
``VARNISH_CACHE_DIR `` ``getCacheDir() `` ``sys_get_temp_dir() `` + ``/foshttpcache-varnish `` directory to use for cache
83
- ``VARNISH_VERSION `` ``getVarnishVersion() `` ``3 `` installed varnish application version
83
+ ``VARNISH_VERSION `` ``getVarnishVersion() `` ``4 `` installed varnish application version
84
84
``WEB_SERVER_HOSTNAME `` ``getHostName() `` hostname your application can be reached at
85
85
======================= ========================= ================================================== ===========================================
86
86
Original file line number Diff line number Diff line change 35
35
* VARNISH_MGMT_PORT Varnish management port (default 6182)
36
36
* VARNISH_CACHE_DIR directory to use for cache
37
37
* (default sys_get_temp_dir() + '/foshttpcache-varnish')
38
- * VARNISH_VERSION Version of varnish: 3 or 4, defaults to 3 .
38
+ * VARNISH_VERSION Version of varnish: 3 or 4, defaults to 4 .
39
39
* WEB_SERVER_HOSTNAME hostname/IP your application can be reached at (required)
40
40
*/
41
41
abstract class VarnishTestCase extends ProxyTestCase
@@ -107,13 +107,13 @@ protected function getCacheDir()
107
107
}
108
108
109
109
/**
110
- * Defaults to 3
110
+ * Defaults to 4
111
111
*
112
112
* @return int
113
113
*/
114
114
protected function getVarnishVersion ()
115
115
{
116
- return getenv ('VARNISH_VERSION ' ) ?: 3 ;
116
+ return getenv ('VARNISH_VERSION ' ) ?: 4 ;
117
117
}
118
118
119
119
/**
Original file line number Diff line number Diff line change @@ -90,10 +90,10 @@ public function testHashRequestFailure()
90
90
protected function getConfigFile ()
91
91
{
92
92
switch ($ this ->getVarnishVersion ()) {
93
- case '4.0 ' :
94
- return sprintf ('./tests/Functional/Fixtures/varnish-4/user_context_%s.vcl ' , $ this ->mode );
95
- default :
93
+ case 3 :
96
94
return sprintf ('./tests/Functional/Fixtures/varnish-3/user_context_%s.vcl ' , $ this ->mode );
95
+ default :
96
+ return sprintf ('./tests/Functional/Fixtures/varnish-4/user_context_%s.vcl ' , $ this ->mode );
97
97
}
98
98
}
99
99
}
Original file line number Diff line number Diff line change 16
16
17
17
if (!defined ('VARNISH_FILE ' )) {
18
18
if (getenv ('VARNISH_VERSION ' )
19
- && (0 === strncmp ('4 . ' , getenv ('VARNISH_VERSION ' ), 2 ))
19
+ && (0 === strncmp ('3 . ' , getenv ('VARNISH_VERSION ' ), 2 ))
20
20
) {
21
- define ('VARNISH_FILE ' , './tests/Functional/Fixtures/varnish-4/fos.vcl ' );
22
- } else {
23
21
define ('VARNISH_FILE ' , './tests/Functional/Fixtures/varnish-3/fos.vcl ' );
22
+ } else {
23
+ define ('VARNISH_FILE ' , './tests/Functional/Fixtures/varnish-4/fos.vcl ' );
24
24
}
25
25
}
26
26
You can’t perform that action at this time.
0 commit comments