Code Duplication    Length = 11-12 lines in 2 locations

eZ/Publish/Core/REST/Server/Tests/Input/Parser/SortClause/FieldTest.php 1 location

@@ 60-71 (lines=12) @@
57
     * @expectedException \eZ\Publish\Core\REST\Common\Exceptions\Parser
58
     * @expectedExceptionMessage Invalid direction format in <Field> sort clause
59
     */
60
    public function testParseExceptionOnInvalidDirectionFormat()
61
    {
62
        $inputArray = [
63
            'Field' => [
64
                'identifier' => 'content/field',
65
                'direction' => 'mock',
66
            ],
67
        ];
68
69
        $fieldParser = $this->getParser();
70
        $fieldParser->parse($inputArray, $this->getParsingDispatcherMock());
71
    }
72
73
    /**
74
     * Returns the Field parser.

eZ/Publish/Core/REST/Server/Tests/Input/Parser/ContentTypeGroupInputTest.php 1 location

@@ 64-74 (lines=11) @@
61
     * @expectedException \eZ\Publish\Core\REST\Common\Exceptions\Parser
62
     * @expectedExceptionMessage Missing '_href' attribute for User element in ContentTypeGroupInput.
63
     */
64
    public function testParseExceptionOnInvalidUser()
65
    {
66
        $inputArray = array(
67
            'identifier' => 'Identifier Bar',
68
            'User' => array(),
69
            'modificationDate' => '2012-12-31T12:00:00',
70
        );
71
72
        $contentTypeGroupInput = $this->getParser();
73
        $contentTypeGroupInput->parse($inputArray, $this->getParsingDispatcherMock());
74
    }
75
76
    /**
77
     * Returns the content type group input parser.