CommonTestClass::defaultJavaFileMime()   A
last analyzed

Complexity

Conditions 2
Paths 2

Size

Total Lines 3
Code Lines 1

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
eloc 1
c 0
b 0
f 0
dl 0
loc 3
rs 10
cc 2
nc 2
nop 0
1
<?php
2
3
namespace tests;
4
5
6
use PHPUnit\Framework\TestCase;
7
8
9
/**
10
 * Class CommonTestClass
11
 * The structure for mocking and configuration seems so complicated, but it's necessary to let it be totally idiot-proof
12
 */
13
abstract class CommonTestClass extends TestCase
14
{
15
    public function defaultJavaFileMime(): string
16
    {
17
        return (PHP_VERSION_ID >= 80300) ? 'text/x-java' : 'text/x-c';
18
    }
19
}
20