Code Duplication    Length = 14-15 lines in 2 locations

src/Kunstmaan/NodeBundle/Tests/unit/Helper/Menu/ActionsMenuBuilderTest.php 2 locations

@@ 74-88 (lines=15) @@
71
        return $emMock;
72
    }
73
74
    public function testCreateSubActionsMenu()
75
    {
76
        $nodeTranslation = new NodeTranslation();
77
        $nodeTranslation->setNode(new Node());
78
79
        $nodeVersion = new NodeVersion();
80
        $nodeVersion->setNodeTranslation($nodeTranslation);
81
82
        $this->builder->setActiveNodeVersion($nodeVersion);
83
84
        $menu = $this->builder->createSubActionsMenu();
85
        $this->assertNotNull($menu->getChild('subaction.versions'));
86
87
        $this->assertEquals('page-sub-actions', $menu->getChildrenAttribute('class'));
88
    }
89
90
    public function testCreateActionsMenuDraft()
91
    {
@@ 182-195 (lines=14) @@
179
        $this->assertEquals('page-main-actions js-auto-collapse-buttons', $menu->getChildrenAttribute('class'));
180
    }
181
182
    public function testCreateTopActionsMenu()
183
    {
184
        $nodeTranslation = new NodeTranslation();
185
        $nodeTranslation->setNode(new Node());
186
187
        $nodeVersion = new NodeVersion();
188
        $nodeVersion->setNodeTranslation($nodeTranslation);
189
190
        $this->builder->setActiveNodeVersion($nodeVersion);
191
192
        $menu = $this->builder->createTopActionsMenu();
193
        $this->assertEquals('page-main-actions page-main-actions--top', $menu->getChildrenAttribute('class'));
194
        $this->assertEquals('page-main-actions-top', $menu->getChildrenAttribute('id'));
195
    }
196
197
    public function testSetGetActiveNodeVersion()
198
    {