classAnalyzer
final class Analyzer
Selects every declared scope, resolves every evidence entry and records which units the specifications claim.
Source extensions report retrieval failures and unsupported syntax by throwing, so each scope and each evidence entry is read on its own and any failure becomes an error of the analysis. An item with invalid evidence claims nothing, and neither do specifications refining it.
Methods§
Analyzes the sources and evidence of a project.
Parameters
$project | Project | The loaded project |
$live | bool | Whether to read the current source URIs instead of pinned snapshots |
Returns
Analysis The units, scopes, errors and resolved evidenceTest cases 21
MarkdownDocumentTest::testReadAcceptsTheProposedSelectorCommentAndReasonSpellingcallsMarkdownDocumentTest::testReadMatchesTheYamlModelAndRenderShowsOnlyReaderFacingInformationcallsMarkdownDocumentTest::testReadResolvesCitationsFromTheMarkdownFileAndKeepsQuotationsSeparatecallsMarkdownDocumentTest::testRenderAddsTextFragmentNavigationForAComplexCssSelectorcallsAnalyzerTest::testAnalyzeContinuesAfterAFailingScopecallsAnalyzerTest::testAnalyzeCountsUnitsSharedByScopesOncecallsAnalyzerTest::testAnalyzeFailsClosedOnInvalidEvidencecallsAnalyzerTest::testAnalyzeKeepsTheValidEvidenceOfAnItemThatClaimsNothingcallsAnalyzerTest::testAnalyzeNeedsASpecificationToClaimARequirementSharedAcrossDefinitionscallsAnalyzerTest::testAnalyzeReadsPinnedSnapshotsUnlessLivecallsAnalyzerTest::testAnalyzeRecordsScopesEvidenceAndClaimscallsAnalyzerTest::testAnalyzeRejectsEvidenceQuotingRepeatedUnitsAndCountsThemUncoveredcallsAnalyzerTest::testAnalyzeReportsAFailingSourceExtensionForTheScopeAndEveryEvidenceEntrycallsAnalyzerTest::testAnalyzeReportsAnEmptyScopeAsAnErrorAndNotAsFullCoveragecallsAnalyzerTest::testAnalyzeResolvesTheEvidenceOfItemsAfterAnItemWithoutSourcecallsAnalyzerTest::testAnalyzeUsesIndependentScopeAndReasonedDispositioncallsCoverageTest::testReportFailsTheDifferentialGateForANewUncoveredUnitcallsSnapshotTest::testCompareDetectsChangedClaimsNewUnitsAndRemovedScopecallsSnapshotTest::testCreateListsOnlyFingerprintsAndCompareDetectsDriftcallsSnapshotTest::testReadRejectsACoverageReportcallsVerifierTest::testVerifyRunsCustomSourcesAndRunnersThroughTheSamePipelineAndDeduplicatesTestscalls
Called from 1
Calls 10
- new Registry line 31
- new UnitCollector line 32
- method-call UnitCollector::open() line 35
- method-call UnitCollector::collect() line 37
- method-call Registry::get() line 37
- new EvidenceMatcher line 42
- method-call EvidenceMatcher::match() line 53
- method-call Claims::assign() line 60
- new Claims line 60
- new Analysis line 61
Test cases 24§
Test cases that cover or call this symbol, from the coverage report and from the analyzed test sources.
Dedicated tests 12
AnalyzerTest::testAnalyzeContinuesAfterAFailingScopecallsAnalyzerTest::testAnalyzeCountsUnitsSharedByScopesOncecallsAnalyzerTest::testAnalyzeFailsClosedOnInvalidEvidencecallsAnalyzerTest::testAnalyzeKeepsTheValidEvidenceOfAnItemThatClaimsNothingcallsAnalyzerTest::testAnalyzeNeedsASpecificationToClaimARequirementSharedAcrossDefinitionscallsAnalyzerTest::testAnalyzeReadsPinnedSnapshotsUnlessLivecallsAnalyzerTest::testAnalyzeRecordsScopesEvidenceAndClaimscallsAnalyzerTest::testAnalyzeRejectsEvidenceQuotingRepeatedUnitsAndCountsThemUncoveredcallsAnalyzerTest::testAnalyzeReportsAFailingSourceExtensionForTheScopeAndEveryEvidenceEntrycallsAnalyzerTest::testAnalyzeReportsAnEmptyScopeAsAnErrorAndNotAsFullCoveragecallsAnalyzerTest::testAnalyzeResolvesTheEvidenceOfItemsAfterAnItemWithoutSourcecallsAnalyzerTest::testAnalyzeUsesIndependentScopeAndReasonedDispositioncalls
Other tests reaching this symbol 12
MarkdownDocumentTest::testReadAcceptsTheProposedSelectorCommentAndReasonSpellingcallsMarkdownDocumentTest::testReadMatchesTheYamlModelAndRenderShowsOnlyReaderFacingInformationcallsMarkdownDocumentTest::testReadResolvesCitationsFromTheMarkdownFileAndKeepsQuotationsSeparatecallsMarkdownDocumentTest::testRenderAddsTextFragmentNavigationForAComplexCssSelectorcallsApplicationTestcallsCommandHandlerTestcallsExecutorTestcallsCoverageTest::testReportFailsTheDifferentialGateForANewUncoveredUnitcallsSnapshotTest::testCompareDetectsChangedClaimsNewUnitsAndRemovedScopecallsSnapshotTest::testCreateListsOnlyFingerprintsAndCompareDetectsDriftcallsSnapshotTest::testReadRejectsACoverageReportcallsVerifierTest::testVerifyRunsCustomSourcesAndRunnersThroughTheSamePipelineAndDeduplicatesTestscalls