File tree Expand file tree Collapse file tree 1 file changed +10
-7
lines changed Expand file tree Collapse file tree 1 file changed +10
-7
lines changed Original file line number Diff line number Diff line change 1919
2020sfConfig::set ('sf_symfony_lib_dir ' , realpath ($ _test_dir .'/../lib ' ));
2121
22+ // setup cache
23+ $ temp = tempnam ('/tmp/cache_dir ' , 'tmp ' );
24+ unlink ($ temp );
25+ mkdir ($ temp );
26+
2227$ plan = 8 ;
2328$ t = new lime_test ($ plan );
2429
25- if (!ini_get ('apc.enable_cli ' ))
26- {
27- $ t ->skip ('APC must be enable on CLI to run these tests ' , $ plan );
28- return ;
29- }
30-
3130// initialize the storage
3231try
3332{
4039}
4140
4241
43- $ storage = new sfCacheSessionStorage (array ('cache ' => array ('class ' => 'sfAPCCache ' , 'param ' => array ())));
42+ $ storage = new sfCacheSessionStorage (array ('cache ' => array ('class ' => 'sfFileCache ' , 'param ' => array (' cache_dir ' => $ temp ))));
4443$ t ->ok ($ storage instanceof sfStorage, '->__construct() is an instance of sfStorage ' );
4544
4645$ storage ->write ('test ' , 123 );
6665
6766// shutdown the storage
6867$ storage ->shutdown ();
68+
69+ // clean up cache
70+ sfToolkit::clearDirectory ($ temp );
71+ rmdir ($ temp );
You can’t perform that action at this time.
0 commit comments