Code Duplication    Length = 12-12 lines in 2 locations

tests/PluginTest.php 2 locations

@@ 347-358 (lines=12) @@
344
        $this->assertContains('string(4) "test"', $twigTemplate->render([]));
345
    }
346
347
    public function testConfigFunction()
348
    {
349
        $twig = $this->getTwig();
350
351
        $key = 'app.custom.key';
352
        $value = 'test value';
353
        Config::set($key, $value);
354
        $template = "{{ config('" . $key . "') }}";
355
356
        $twigTemplate = $twig->createTemplate($template);
357
        $this->assertEquals($twigTemplate->render([]), $value);
358
    }
359
360
    public function testEnvFunction()
361
    {
@@ 360-371 (lines=12) @@
357
        $this->assertEquals($twigTemplate->render([]), $value);
358
    }
359
360
    public function testEnvFunction()
361
    {
362
        $twig = $this->getTwig();
363
364
        $key = 'env.custom.key';
365
        $value = 'test value';
366
        putenv($key.'='.$value);
367
        $template = "{{ env('" . $key . "') }}";
368
369
        $twigTemplate = $twig->createTemplate($template);
370
        $this->assertEquals($twigTemplate->render([]), $value);
371
    }
372
373
    public function testSessionFunction()
374
    {