RequestMethodMappingTest   A
last analyzed

Complexity

Total Complexity 1

Size/Duplication

Total Lines 13
Duplicated Lines 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
wmc 1
eloc 6
c 1
b 0
f 0
dl 0
loc 13
rs 10

1 Method

Rating   Name   Duplication   Size   Complexity  
A testIsValidMethod() 0 8 1
1
<?php
2
3
/*
4
 * This file is part of the SF Forward Bundle.
5
 *
6
 * (c) DAOUDI Soufian <[email protected]>
7
 *
8
 * For the full copyright and license information, please view the LICENSE
9
 * file that was distributed with this source code.
10
 */
11
12
namespace SfForward\Tests\Util;
13
14
use PHPUnit\Framework\TestCase;
15
use SfForward\Util\RequestMethodMapping;
16
17
class RequestMethodMappingTest extends TestCase
18
{
19
    /**
20
     * isValidMethod test.
21
     */
22
    public function testIsValidMethod()
23
    {
24
        $this->assertTrue(RequestMethodMapping::isValidMethod('post'));
25
        $this->assertTrue(RequestMethodMapping::isValidMethod('get'));
26
27
        $this->assertNotTrue(RequestMethodMapping::isValidMethod('put'));
28
        $this->assertNotTrue(RequestMethodMapping::isValidMethod('delete'));
29
        $this->assertNotTrue(RequestMethodMapping::isValidMethod('update'));
30
    }
31
}
32