Completed
Push — V6 ( 8414d9...768f69 )
by Georges
02:19
created
tests/ReadWriteOperations.test.php 3 patches
Indentation   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -23,9 +23,9 @@
 block discarded – undo
23 23
 $keys = [];
24 24
 
25 25
 $dirs = [
26
-  __DIR__ . '/../var/cache/IO-',
27
-  sys_get_temp_dir() . '/phpfastcache/IO-1',
28
-  sys_get_temp_dir() . '/phpfastcache/IO-2'
26
+    __DIR__ . '/../var/cache/IO-',
27
+    sys_get_temp_dir() . '/phpfastcache/IO-1',
28
+    sys_get_temp_dir() . '/phpfastcache/IO-2'
29 29
 ];
30 30
 
31 31
 
Please login to merge, or discard this patch.
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -39,9 +39,9 @@  discard block
 block discarded – undo
39 39
     {
40 40
         $cacheInstanceName = 'cacheInstance' . $i;
41 41
 
42
-        $instances[$dirIndex][$cacheInstanceName] = CacheManager::getInstance('Files',array('path' => $dir . str_pad($i, 3, '0', STR_PAD_LEFT)));
42
+        $instances[$dirIndex][$cacheInstanceName] = CacheManager::getInstance('Files', array('path' => $dir . str_pad($i, 3, '0', STR_PAD_LEFT)));
43 43
 
44
-        foreach($keys[$dirIndex] as $index => $key)
44
+        foreach ($keys[$dirIndex] as $index => $key)
45 45
         {
46 46
             $items[$dirIndex][$index] = $instances[$dirIndex][$cacheInstanceName]->getItem($key);
47 47
             $items[$dirIndex][$index]->set("test-$dirIndex-$index")->expiresAfter(600);
@@ -51,11 +51,11 @@  discard block
 block discarded – undo
51 51
         $instances[$dirIndex][$cacheInstanceName]->detachAllItems();
52 52
     }
53 53
 
54
-    foreach($instances[$dirIndex] as $cacheInstanceName => $instance)
54
+    foreach ($instances[$dirIndex] as $cacheInstanceName => $instance)
55 55
     {
56
-        foreach($keys[$dirIndex] as $index => $key)
56
+        foreach ($keys[$dirIndex] as $index => $key)
57 57
         {
58
-            if($instances[$dirIndex][$cacheInstanceName]->getItem($key)->get() === "test-$dirIndex-$index")
58
+            if ($instances[$dirIndex][$cacheInstanceName]->getItem($key)->get() === "test-$dirIndex-$index")
59 59
             {
60 60
                 echo "[PASS] Item #{$key} of instance #{$cacheInstanceName} of dir #{$dirIndex} has returned the expected value (" . gettype("test-$dirIndex-$index") . ":'" . "test-$dirIndex-$index" . "')\n";
61 61
             }
Please login to merge, or discard this patch.
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -58,8 +58,7 @@
 block discarded – undo
58 58
             if($instances[$dirIndex][$cacheInstanceName]->getItem($key)->get() === "test-$dirIndex-$index")
59 59
             {
60 60
                 echo "[PASS] Item #{$key} of instance #{$cacheInstanceName} of dir #{$dirIndex} has returned the expected value (" . gettype("test-$dirIndex-$index") . ":'" . "test-$dirIndex-$index" . "')\n";
61
-            }
62
-            else
61
+            } else
63 62
             {
64 63
                 echo "[FAIL] Item #{$key} of instance #{$cacheInstanceName} of dir #{$dirIndex} returned an unexpected value (" . gettype($instances[$dirIndex][$cacheInstanceName]->getItem($key)->get()) . ":'" . $instances[$dirIndex][$cacheInstanceName]->getItem($key)->get() . "') expected (" . gettype("test-$dirIndex-$index") . ":'" . "test-$dirIndex-$index" . "') \n";
65 64
                 $status = 255;
Please login to merge, or discard this patch.