Passed
Push — moreTests ( 25cdd4...5c9253 )
by Matias
08:06 queued 06:02
created

Requirements   A

Complexity

Total Complexity 2

Size/Duplication

Total Lines 9
Duplicated Lines 0 %

Test Coverage

Coverage 100%

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 4
c 1
b 0
f 0
dl 0
loc 9
ccs 5
cts 5
cp 1
rs 10
wmc 2

2 Methods

Rating   Name   Duplication   Size   Complexity  
A pdlibLoaded() 0 2 1
A hasEnoughMemory() 0 3 1
1
<?php
2
namespace OCA\FaceRecognition\Helper;
3
4
use OCA\FaceRecognition\Helper\MemoryLimits;
5
6
use OCA\FaceRecognition\Service\SettingsService;
7
8
class Requirements
9
{
10 1
	public static function hasEnoughMemory(): bool {
11 1
		$memory = MemoryLimits::getSystemMemory();
12 1
		return ($memory > SettingsService::MINIMUM_SYSTEM_MEMORY_REQUIREMENTS);
13
	}
14
15 1
	public static function pdlibLoaded(): bool {
16 1
		return extension_loaded('pdlib');
17
	}
18
19
}
20