PHP Classes

File: tests/org/majkel/tcpdfwarper/MissingMethodExceptionTest.php

Recommend this page to a friend!
  Classes of Michal Kowalik   TCPDF Warper   tests/org/majkel/tcpdfwarper/MissingMethodExceptionTest.php   Download  
File: tests/org/majkel/tcpdfwarper/MissingMethodExceptionTest.php
Role: Unit test script
Content type: text/plain
Description: tests
Class: TCPDF Warper
Create PDF documents using TCPDF fluent interface
Author: By
Last change: Update of tests/org/majkel/tcpdfwarper/MissingMethodExceptionTest.php
Date: 11 months ago
Size: 937 bytes
 

Contents

Class file image Download
<?php
/**
 * Created by PhpStorm.
 * Package: org\majkel\tcpdfwarper
 * User: Micha? (majkel) Kowalik <maf.michal@gmail.com>
 * Date: 12/28/2014
 * Time: 22:36
 */

namespace org\majkel\tcpdfwarper;

/**
 * Class MissingMethodExceptionTest
 * @package org\majkel\tcpdfwarper
 * @coversDefaultClass \org\majkel\tcpdfwarper\MissingMethodException
 */
class MissingMethodExceptionTest extends \PHPUnit_Framework_TestCase {

    public function
testException() {
       
$previous = new \Exception();
       
$code = 123;
       
$method = 'method';
       
$args = array(1, 2, 3);
       
$message = sprintf(MissingMethodException::MESSAGE, $method, $args);

       
$e = new MissingMethodException($method, $args, $code, $previous);

       
self::assertSame($previous, $e->getPrevious());
       
self::assertSame($code, $e->getCode());
       
self::assertSame($method, $e->getMethodName());
       
self::assertSame($args, $e->getArguments());
       
self::assertSame($message, $e->getMessage());
    }

}