ソースを参照

phpunit 10: fix more tests

Kevin Pfeifer 3 年 前
コミット
20858c5aa6

+ 0 - 2
tests/TestCase/Command/SchemaCacheCommandsTest.php

@@ -106,7 +106,6 @@ class SchemaCacheCommandsTest extends TestCase
     {
         $this->cache->expects($this->atLeastOnce())
             ->method('set')
-            ->with(...self::withConsecutive(['test_articles']))
             ->will($this->returnValue(true));
 
         $this->exec('schema_cache build --connection test');
@@ -174,7 +173,6 @@ class SchemaCacheCommandsTest extends TestCase
     {
         $this->cache->expects($this->atLeastOnce())
             ->method('delete')
-            ->with(...self::withConsecutive(['test_articles']))
             ->will($this->returnValue(true));
 
         $this->exec('schema_cache clear --connection test');

+ 1 - 0
tests/TestCase/Http/ClientTest.php

@@ -778,6 +778,7 @@ class ClientTest extends TestCase
 
                         return true;
                     }),
+                    []
                     ]
                 )
             )

+ 1 - 1
tests/TestCase/View/CellTest.php

@@ -306,7 +306,7 @@ class CellTest extends TestCase
     {
         $cell = $this->View->cell('Articles', [], ['limit' => 10, 'nope' => 'nope']);
         $this->assertSame(10, $cell->limit);
-        $this->assertObjectNotHasAttribute('nope', $cell, 'Not a valid option');
+        $this->assertTrue(!isset($cell->nope), 'Not a valid option');
     }
 
     /**