Magento 2 Documentation  2.3
Documentation for Magento 2 CMS v2.3 (December 2018)
MethodInvokedAtIndexTest.php
Go to the documentation of this file.
1 <?php
7 
9 
10 class MethodInvokedAtIndexTest extends \PHPUnit\Framework\TestCase
11 {
12  public function testMatches()
13  {
14  $invocationObject = new \PHPUnit\Framework\MockObject\Invocation\ObjectInvocation(
15  'ClassName',
16  'ValidMethodName',
17  [],
18  'void',
19  new \StdClass()
20  );
21  $matcher = new MethodInvokedAtIndex(0);
22  $this->assertTrue($matcher->matches($invocationObject));
23 
24  $matcher = new MethodInvokedAtIndex(1);
25  $matcher->matches($invocationObject);
26  $this->assertTrue($matcher->matches($invocationObject));
27  }
28 }