Exemplo n.º 1
0
 protected function verifyMockObjects()
 {
     parent::verifyMockObjects();
     if (null === $this->prophet) {
         return;
     }
     try {
         $this->prophet->checkPredictions();
     } catch (\Exception $e) {
         /** Intentionally left empty */
     }
     $this->countProphecyAssertions();
     if (isset($e)) {
         throw $e;
     }
 }
 /**
  * {@inheritdoc}
  */
 protected function verifyMockObjects()
 {
     parent::verifyMockObjects();
     if ($this->prophet !== null) {
         try {
             $this->prophet->checkPredictions();
         } catch (\Exception $e) {
             /** Intentionally left empty */
         }
         foreach ($this->prophet->getProphecies() as $objectProphecy) {
             foreach ($objectProphecy->getMethodProphecies() as $methodProphecies) {
                 foreach ($methodProphecies as $methodProphecy) {
                     $this->addToAssertionCount(count($methodProphecy->getCheckedPredictions()));
                 }
             }
         }
         if (isset($e)) {
             throw $e;
         }
     }
 }
Exemplo n.º 3
0
 protected function verifyMockObjects()
 {
     $container = Mockery::getContainer();
     if (isset($container)) {
         $reflected_container = new ReflectionClass($container);
         $reflected_mocks = $reflected_container->getProperty('_mocks');
         $reflected_mocks->setAccessible(true);
         $mocks = $reflected_mocks->getValue($container);
         foreach ($mocks as $mock) {
             $reflected_mock = new ReflectionClass($mock);
             $reflected_expectations = $reflected_mock->getProperty('_mockery_expectations');
             $reflected_expectations->setAccessible(true);
             $expectations = $reflected_expectations->getValue($mock);
             foreach ($expectations as $director) {
                 $this->addToAssertionCount(count($director->getExpectations()));
             }
         }
         Mockery::close();
     }
     parent::verifyMockObjects();
 }
Exemplo n.º 4
0
 protected function verifyMockObjects()
 {
     parent::verifyMockObjects();
     $this->dumper->verifyCalls();
 }
Exemplo n.º 5
0
 public function verifyMockObjects()
 {
     parent::verifyMockObjects();
     WpOptions::verify();
 }