Code Duplication    Length = 13-15 lines in 2 locations

Tests/Features/Context/VictoireContext.php 2 locations

@@ 198-210 (lines=13) @@
195
    /**
196
     * @When I open the widget mode drop for entity :entity
197
     */
198
    public function iOpenTheWidgetModeDrop($entity)
199
    {
200
        $element = $this->findOrRetry(
201
            $this->getSession()->getPage(),
202
            'css',
203
            '[id^="picker-'.strtolower($entity).'"] .v-mode-trigger'
204
        );
205
        if (null === $element) {
206
            $message = sprintf('Element not found in the page after 10 seconds"');
207
            throw new \Behat\Mink\Exception\ResponseTextException($message, $this->getSession());
208
        }
209
        $element->click();
210
    }
211
212
    /**
213
     * @When I open the widget style tab :key
@@ 249-263 (lines=15) @@
246
    /**
247
     * @When I open the widget quantum collapse for entity :entity
248
     */
249
    public function iOpenTheWidgetQuantumCollapse($entity)
250
    {
251
        $element = $this->findOrRetry(
252
            $this->getSession()->getPage(),
253
            'css',
254
            '[id^="picker-'.strtolower($entity).'"][data-state="visible"] [id^="picker-'.strtolower($entity).'"][data-state="visible"] .v-widget-form__quantum-btn'
255
        );
256
257
        if (null === $element) {
258
            $message = sprintf('Element not found in the page after 10 seconds"');
259
            throw new \Behat\Mink\Exception\ResponseTextException($message, $this->getSession());
260
        }
261
        $element->click();
262
    }
263
264
    /**
265
     * @When I open the widget quantum collapse when static
266
     */