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

tempestphp / tempest-framework / 14024978163

23 Mar 2025 05:55PM UTC coverage: 79.391% (-0.05%) from 79.441%
14024978163

push

github

web-flow
feat(view): cache Blade and Twig templates in internal storage (#1061)

2 of 2 new or added lines in 2 files covered. (100.0%)

912 existing lines in 110 files now uncovered.

10478 of 13198 relevant lines covered (79.39%)

91.09 hits per line

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

71.43
/src/Tempest/Reflection/src/functions.php
1
<?php
2

3
declare(strict_types=1);
4

5
namespace Tempest {
6
    use ReflectionClass as PHPReflectionClass;
7
    use ReflectionProperty as PHPReflectionProperty;
8
    use Tempest\Reflection\ClassReflector;
9
    use Tempest\Reflection\PropertyReflector;
10

11
    /**
12
     * Creates a new {@see Reflector} instance based on the given `$classOrProperty`.
13
     */
14
    function reflect(mixed $classOrProperty, ?string $propertyName = null): ClassReflector|PropertyReflector
15
    {
16
        if ($classOrProperty instanceof PHPReflectionClass) {
62✔
UNCOV
17
            return new ClassReflector($classOrProperty);
×
18
        }
19

20
        if ($classOrProperty instanceof PHPReflectionProperty) {
62✔
UNCOV
21
            return new PropertyReflector($classOrProperty);
×
22
        }
23

24
        if ($propertyName !== null) {
62✔
25
            return new PropertyReflector(new PHPReflectionProperty($classOrProperty, $propertyName));
49✔
26
        }
27

28
        return new ClassReflector($classOrProperty);
62✔
29
    }
30
}
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