Code Coverage
 
Lines
Functions and Methods
Classes and Traits
Total
100.00% covered (success)
100.00%
2 / 2
100.00% covered (success)
100.00%
2 / 2
CRAP
100.00% covered (success)
100.00%
1 / 1
GroupOlxCompatibilityReportData
100.00% covered (success)
100.00%
2 / 2
100.00% covered (success)
100.00%
2 / 2
3
100.00% covered (success)
100.00%
1 / 1
 __construct
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
1 / 1
1
 isFullyCompatible
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
1 / 1
2
1<?php
2
3declare(strict_types=1);
4
5namespace ImovelZapAi\Publishing\Connectors\GroupOlx\Application\Data;
6
7use Carbon\CarbonInterface;
8
9/**
10 * Relatório final da suíte de compatibilidade VRSync.
11 */
12final readonly class GroupOlxCompatibilityReportData
13{
14    /**
15     * @param  list<array{name: string, passed: bool, detail: string}>  $checks
16     */
17    public function __construct(
18        public CarbonInterface $generatedAt,
19        public array $checks,
20        public int $passedCount,
21        public int $totalCount,
22        public int $listingCount,
23        public int $xmlBytes,
24        public bool $utf8,
25    ) {}
26
27    public function isFullyCompatible(): bool
28    {
29        return $this->totalCount > 0 && $this->passedCount === $this->totalCount;
30    }
31}