• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

heimrichhannot / contao-encore-bundle / 24667931129

20 Apr 2026 01:00PM UTC coverage: 73.04% (-0.8%) from 73.813%
24667931129

push

github

web-flow
Support contao twig slot layouts (#34)

112 of 150 new or added lines in 11 files covered. (74.67%)

7 existing lines in 2 files now uncovered.

531 of 727 relevant lines covered (73.04%)

2.03 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

4.76
/src/Event/EncoreEnabledEvent.php
1
<?php
2

3
/*
4
 * Copyright (c) 2023 Heimrich & Hannot GmbH
5
 *
6
 * @license LGPL-3.0-or-later
7
 */
8

9
namespace HeimrichHannot\EncoreBundle\Event;
10

11
use Contao\LayoutModel;
12
use Contao\PageModel;
13
use Symfony\Component\HttpFoundation\Request;
14
use Symfony\Contracts\EventDispatcher\Event;
15

16
class EncoreEnabledEvent extends Event
17
{
18
    public function __construct(
19
        public bool $enabled,
20
        public readonly Request $request,
21
        public readonly ?PageModel $pageModel = null,
22
        public readonly ?LayoutModel $layoutModel = null,
23
    ) {
24
    }
1✔
25

26
    /**
27
     * @deprecated
28
     */
29
    public function isEnabled(): bool
30
    {
NEW
31
        trigger_deprecation(
×
NEW
32
            'heimrichhannot/contao-encore-bundle',
×
NEW
33
            '2.2.0',
×
NEW
34
            'Use class properties instead.'
×
NEW
35
        );
×
36

UNCOV
37
        return $this->enabled;
×
38
    }
39

40
    public function setEnabled(bool $enabled): self
41
    {
42
        $this->enabled = $enabled;
×
43

44
        return $this;
×
45
    }
46

47
    /**
48
     * @deprecated
49
     */
50
    public function getRequest(): Request
51
    {
NEW
52
        trigger_deprecation(
×
NEW
53
            'heimrichhannot/contao-encore-bundle',
×
NEW
54
            '2.2.0',
×
NEW
55
            'Use class properties instead.'
×
NEW
56
        );
×
57

UNCOV
58
        return $this->request;
×
59
    }
60

61
    /**
62
     * @deprecated
63
     */
64
    public function getPageModel(): ?PageModel
65
    {
NEW
66
        trigger_deprecation(
×
NEW
67
            'heimrichhannot/contao-encore-bundle',
×
NEW
68
            '2.2.0',
×
NEW
69
            'Use class properties instead.'
×
NEW
70
        );
×
71

UNCOV
72
        return $this->pageModel;
×
73
    }
74
}
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc