@cucumber/react-components 24.3.0 → 24.5.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +2 -2
- package/dist/{src/CucumberQueryContext.d.ts → CucumberQueryContext.d.ts} +0 -1
- package/dist/CucumberQueryContext.js +4 -0
- package/dist/{src/GherkinQueryContext.d.ts → GherkinQueryContext.d.ts} +0 -1
- package/dist/GherkinQueryContext.js +4 -0
- package/dist/{src/SearchContext.d.ts → SearchContext.d.ts} +0 -1
- package/dist/SearchContext.js +10 -0
- package/dist/{src/ciCommitLink.d.ts → ciCommitLink.d.ts} +0 -1
- package/dist/ciCommitLink.js +12 -0
- package/dist/{src/components → components}/app/CICommitLink.d.ts +0 -1
- package/dist/components/app/CICommitLink.js +16 -0
- package/dist/{src/components → components}/app/CIJobLink.d.ts +0 -1
- package/dist/components/app/CIJobLink.js +10 -0
- package/dist/{src/components → components}/app/ControlledSearchProvider.d.ts +0 -1
- package/dist/components/app/ControlledSearchProvider.js +39 -0
- package/dist/{src/components → components}/app/CopyButton.d.ts +0 -1
- package/dist/components/app/CopyButton.js +23 -0
- package/dist/{src/components → components}/app/DocumentAccordion.d.ts +0 -1
- package/dist/components/app/DocumentAccordion.js +22 -0
- package/dist/{src/components → components}/app/EnvelopesProvider.d.ts +0 -1
- package/dist/components/app/EnvelopesProvider.js +18 -0
- package/dist/{src/components → components}/app/ExecutionSummary.d.ts +0 -1
- package/dist/components/app/ExecutionSummary.js +38 -0
- package/dist/{src/components → components}/app/FilteredDocuments.d.ts +0 -1
- package/dist/components/app/FilteredDocuments.js +15 -0
- package/dist/{src/components → components}/app/GherkinDocumentList.d.ts +0 -1
- package/dist/components/app/GherkinDocumentList.js +23 -0
- package/dist/{src/components → components}/app/Header.d.ts +0 -1
- package/dist/components/app/Header.js +12 -0
- package/dist/{src/components → components}/app/HealthChart.d.ts +0 -1
- package/dist/components/app/HealthChart.js +14 -0
- package/dist/{src/components → components}/app/HighLight.d.ts +0 -1
- package/dist/components/app/HighLight.js +38 -0
- package/dist/{src/components → components}/app/ImplementationIcon.d.ts +0 -1
- package/dist/components/app/ImplementationIcon.js +10 -0
- package/dist/{src/components → components}/app/InMemorySearchProvider.d.ts +0 -1
- package/dist/components/app/InMemorySearchProvider.js +11 -0
- package/dist/{src/components → components}/app/NavigationButton.d.ts +0 -1
- package/dist/components/app/NavigationButton.js +6 -0
- package/dist/{src/components → components}/app/OSIcon.d.ts +0 -1
- package/dist/components/app/OSIcon.js +18 -0
- package/dist/{src/components → components}/app/QueriesProvider.d.ts +0 -1
- package/dist/components/app/QueriesProvider.js +7 -0
- package/dist/{src/components → components}/app/Report.d.ts +0 -1
- package/dist/components/app/Report.js +10 -0
- package/dist/{src/components → components}/app/RuntimeIcon.d.ts +0 -1
- package/dist/components/app/RuntimeIcon.js +18 -0
- package/dist/{src/components → components}/app/SearchBar.d.ts +0 -1
- package/dist/components/app/SearchBar.js +33 -0
- package/dist/{src/components → components}/app/StatusesSummary.d.ts +0 -1
- package/dist/components/app/StatusesSummary.js +16 -0
- package/dist/{src/components → components}/app/TestRunHooks.d.ts +0 -1
- package/dist/components/app/TestRunHooks.js +14 -0
- package/dist/{src/components → components}/app/UrlSearchProvider.d.ts +0 -1
- package/dist/components/app/UrlSearchProvider.js +29 -0
- package/dist/{src/components → components}/app/findMostSevereTestStepResultStatus.d.ts +0 -1
- package/dist/components/app/findMostSevereTestStepResultStatus.js +17 -0
- package/dist/{src/components → components}/app/icons/CucumberLogo.d.ts +0 -1
- package/dist/components/app/icons/CucumberLogo.js +5 -0
- package/dist/{src/components → components}/app/icons/Jvm.d.ts +0 -1
- package/dist/components/app/icons/Jvm.js +5 -0
- package/dist/{src/components → components}/app/icons/Linux.d.ts +0 -1
- package/dist/components/app/icons/Linux.js +5 -0
- package/dist/{src/components → components}/app/icons/MacOS.d.ts +0 -1
- package/dist/components/app/icons/MacOS.js +5 -0
- package/dist/{src/components → components}/app/icons/NodeJs.d.ts +0 -1
- package/dist/components/app/icons/NodeJs.js +5 -0
- package/dist/{src/components → components}/app/icons/Ruby.d.ts +0 -1
- package/dist/components/app/icons/Ruby.js +5 -0
- package/dist/{src/components → components}/app/icons/Windows.d.ts +0 -1
- package/dist/components/app/icons/Windows.js +5 -0
- package/dist/{src/components/app/index.js → components/app/index.d.ts} +0 -1
- package/dist/components/app/index.js +15 -0
- package/dist/{src/components → components}/app/makeSetupString.d.ts +0 -1
- package/dist/components/app/makeSetupString.js +21 -0
- package/dist/{src/components → components}/app/markdownComponents.d.ts +1 -2
- package/dist/components/app/markdownComponents.js +6 -0
- package/dist/{src/components → components}/app/rehypePlugins.d.ts +0 -1
- package/dist/components/app/rehypePlugins.js +9 -0
- package/dist/{src/components → components}/app/remarkPlugins.d.ts +0 -1
- package/dist/components/app/remarkPlugins.js +4 -0
- package/dist/{src/components → components}/customise/CustomRendering.d.ts +0 -1
- package/dist/components/customise/CustomRendering.js +35 -0
- package/dist/{src/components/customise/index.js → components/customise/index.d.ts} +0 -1
- package/dist/components/customise/index.js +3 -0
- package/dist/{src/components → components}/customise/theming.d.ts +0 -1
- package/dist/components/customise/theming.js +2 -0
- package/dist/{src/components → components}/gherkin/Anchor.d.ts +0 -1
- package/dist/components/gherkin/Anchor.js +13 -0
- package/dist/{src/components → components}/gherkin/Background.d.ts +0 -1
- package/dist/components/gherkin/Background.js +18 -0
- package/dist/{src/components → components}/gherkin/Children.d.ts +0 -1
- package/dist/components/gherkin/Children.js +11 -0
- package/dist/{src/components → components}/gherkin/DataTable.d.ts +0 -1
- package/dist/components/gherkin/DataTable.js +16 -0
- package/dist/{src/components → components}/gherkin/Description.d.ts +0 -1
- package/dist/components/gherkin/Description.js +15 -0
- package/dist/{src/components → components}/gherkin/DocString.d.ts +0 -1
- package/dist/components/gherkin/DocString.js +12 -0
- package/dist/{src/components → components}/gherkin/ErrorMessage.d.ts +0 -1
- package/dist/components/gherkin/ErrorMessage.js +13 -0
- package/dist/{src/components → components}/gherkin/Examples.d.ts +0 -1
- package/dist/components/gherkin/Examples.js +31 -0
- package/dist/{src/components → components}/gherkin/Feature.d.ts +0 -1
- package/dist/components/gherkin/Feature.js +30 -0
- package/dist/{src/components → components}/gherkin/GherkinDocument.d.ts +0 -1
- package/dist/components/gherkin/GherkinDocument.js +11 -0
- package/dist/{src/components → components}/gherkin/Keyword.d.ts +0 -1
- package/dist/components/gherkin/Keyword.js +11 -0
- package/dist/{src/components → components}/gherkin/Parameter.d.ts +0 -1
- package/dist/components/gherkin/Parameter.js +11 -0
- package/dist/{src/components → components}/gherkin/Rule.d.ts +0 -1
- package/dist/components/gherkin/Rule.js +26 -0
- package/dist/{src/components → components}/gherkin/Scenario.d.ts +0 -1
- package/dist/components/gherkin/Scenario.js +22 -0
- package/dist/{src/components → components}/gherkin/StatusIcon.d.ts +0 -1
- package/dist/components/gherkin/StatusIcon.js +24 -0
- package/dist/{src/components → components}/gherkin/StepsList.d.ts +0 -1
- package/dist/components/gherkin/StepsList.js +6 -0
- package/dist/{src/components → components}/gherkin/Tags.d.ts +0 -1
- package/dist/components/gherkin/Tags.js +15 -0
- package/dist/{src/components → components}/gherkin/Title.d.ts +0 -1
- package/dist/components/gherkin/Title.js +12 -0
- package/dist/{src/components → components}/gherkin/attachment/Attachment.d.ts +0 -1
- package/dist/components/gherkin/attachment/Attachment.js +45 -0
- package/dist/{src/components → components}/gherkin/attachment/Image.d.ts +0 -1
- package/dist/components/gherkin/attachment/Image.js +16 -0
- package/dist/{src/components → components}/gherkin/attachment/Links.d.ts +0 -1
- package/dist/components/gherkin/attachment/Links.js +14 -0
- package/dist/{src/components → components}/gherkin/attachment/Log.d.ts +0 -1
- package/dist/components/gherkin/attachment/Log.js +12 -0
- package/dist/{src/components → components}/gherkin/attachment/Text.d.ts +0 -1
- package/dist/components/gherkin/attachment/Text.js +16 -0
- package/dist/{src/components → components}/gherkin/attachment/Unknown.d.ts +0 -1
- package/dist/components/gherkin/attachment/Unknown.js +61 -0
- package/dist/{src/components → components}/gherkin/attachment/Video.d.ts +0 -1
- package/dist/components/gherkin/attachment/Video.js +16 -0
- package/dist/{src/components → components}/gherkin/attachment/attachmentFilename.d.ts +0 -1
- package/dist/components/gherkin/attachment/attachmentFilename.js +12 -0
- package/dist/{src/components → components}/gherkin/attachment/base64Decode.d.ts +0 -1
- package/dist/components/gherkin/attachment/base64Decode.js +19 -0
- package/dist/{src/components/gherkin/attachment/index.js → components/gherkin/attachment/index.d.ts} +0 -1
- package/dist/components/gherkin/attachment/index.js +2 -0
- package/dist/{src/components → components}/gherkin/attachment/useText.d.ts +0 -1
- package/dist/components/gherkin/attachment/useText.js +28 -0
- package/dist/{src/components → components}/gherkin/composeHookStepTitle.d.ts +0 -1
- package/dist/components/gherkin/composeHookStepTitle.js +23 -0
- package/dist/{src/components → components}/gherkin/composePickleStepTitle.d.ts +0 -1
- package/dist/components/gherkin/composePickleStepTitle.js +36 -0
- package/dist/{src/components/gherkin/index.js → components/gherkin/index.d.ts} +0 -1
- package/dist/components/gherkin/index.js +19 -0
- package/dist/{src/components → components}/gherkin/isNumber.d.ts +0 -1
- package/dist/components/gherkin/isNumber.js +7 -0
- package/dist/components/gherkin/statusName.d.ts +3 -0
- package/dist/components/gherkin/statusName.js +4 -0
- package/dist/{src/components/index.js → components/index.d.ts} +0 -1
- package/dist/components/index.js +4 -0
- package/dist/{src/components → components}/results/AmbiguousResult.d.ts +0 -1
- package/dist/components/results/AmbiguousResult.js +11 -0
- package/dist/{src/components → components}/results/FailedResult.d.ts +0 -1
- package/dist/components/results/FailedResult.js +15 -0
- package/dist/{src/components → components}/results/PendingResult.d.ts +0 -1
- package/dist/components/results/PendingResult.js +12 -0
- package/dist/{src/components → components}/results/ResultNote.d.ts +0 -1
- package/dist/components/results/ResultNote.js +6 -0
- package/dist/{src/components → components}/results/SkippedResult.d.ts +0 -1
- package/dist/components/results/SkippedResult.js +12 -0
- package/dist/{src/components → components}/results/SourceReference.d.ts +0 -1
- package/dist/components/results/SourceReference.js +13 -0
- package/dist/{src/components → components}/results/TestCaseOutcome.d.ts +0 -1
- package/dist/components/results/TestCaseOutcome.js +32 -0
- package/dist/{src/components → components}/results/TestRunHookOutcome.d.ts +0 -1
- package/dist/components/results/TestRunHookOutcome.js +11 -0
- package/dist/{src/components → components}/results/TestStepAttachments.d.ts +0 -1
- package/dist/components/results/TestStepAttachments.js +12 -0
- package/dist/{src/components → components}/results/TestStepDuration.d.ts +0 -1
- package/dist/components/results/TestStepDuration.js +19 -0
- package/dist/{src/components → components}/results/TestStepOutcome.d.ts +0 -1
- package/dist/components/results/TestStepOutcome.js +43 -0
- package/dist/{src/components → components}/results/UndefinedResult.d.ts +0 -1
- package/dist/components/results/UndefinedResult.js +18 -0
- package/dist/{src/components/results/index.js → components/results/index.d.ts} +0 -1
- package/dist/components/results/index.js +3 -0
- package/dist/{src/hooks/helpers.d.ts → ensure.d.ts} +0 -1
- package/dist/ensure.js +7 -0
- package/dist/{src/formatExecutionDistance.d.ts → formatExecutionDistance.d.ts} +0 -1
- package/dist/formatExecutionDistance.js +7 -0
- package/dist/{src/formatExecutionDuration.d.ts → formatExecutionDuration.d.ts} +0 -1
- package/dist/formatExecutionDuration.js +12 -0
- package/dist/{src/formatPassedQuantity.d.ts → formatPassedQuantity.d.ts} +0 -1
- package/dist/formatPassedQuantity.js +4 -0
- package/dist/{src/formatStatusRate.d.ts → formatStatusRate.d.ts} +0 -1
- package/dist/formatStatusRate.js +9 -0
- package/dist/{src/hooks/index.js → hooks/index.d.ts} +0 -1
- package/dist/hooks/index.js +3 -0
- package/dist/{src/hooks → hooks}/useFilteredDocuments.d.ts +1 -2
- package/dist/hooks/useFilteredDocuments.js +67 -0
- package/dist/hooks/useFilteredTestCases.d.ts +6 -0
- package/dist/hooks/useFilteredTestCases.js +36 -0
- package/dist/{src/hooks → hooks}/useMostSevereStatusByUri.d.ts +0 -1
- package/dist/hooks/useMostSevereStatusByUri.js +25 -0
- package/dist/{src/hooks → hooks}/useQueries.d.ts +0 -1
- package/dist/hooks/useQueries.js +9 -0
- package/dist/{src/hooks → hooks}/useResultStatistics.d.ts +0 -1
- package/dist/hooks/useResultStatistics.js +24 -0
- package/dist/{src/hooks → hooks}/useSearch.d.ts +0 -1
- package/dist/hooks/useSearch.js +6 -0
- package/dist/hooks/useSearchResult.d.ts +26 -0
- package/dist/hooks/useSearchResult.js +58 -0
- package/dist/{src/hooks → hooks}/useTestCaseStarted.d.ts +0 -1
- package/dist/hooks/useTestCaseStarted.js +20 -0
- package/dist/{src/hooks → hooks}/useTestRunHooks.d.ts +0 -1
- package/dist/hooks/useTestRunHooks.js +14 -0
- package/dist/{src/index.js → index.d.ts} +0 -1
- package/dist/index.js +3 -0
- package/dist/{src/isTagExpression.d.ts → isTagExpression.d.ts} +0 -1
- package/dist/isTagExpression.js +5 -0
- package/dist/{src/search → search}/FeatureSearch.d.ts +0 -1
- package/dist/search/FeatureSearch.js +39 -0
- package/dist/{src/search → search}/ScenarioLikeSearch.d.ts +0 -1
- package/dist/search/ScenarioLikeSearch.js +37 -0
- package/dist/{src/search → search}/StepSearch.d.ts +0 -1
- package/dist/search/StepSearch.js +40 -0
- package/dist/{src/search → search}/TextSearch.d.ts +1 -2
- package/dist/search/TextSearch.js +67 -0
- package/dist/{src/search → search}/createSearchIndex.d.ts +0 -1
- package/dist/search/createSearchIndex.js +10 -0
- package/dist/{src/search → search}/deriveLineageConstraints.d.ts +0 -1
- package/dist/search/deriveLineageConstraints.js +38 -0
- package/dist/search/filterAndExpandTestCaseEvents.d.ts +20 -0
- package/dist/search/filterAndExpandTestCaseEvents.js +32 -0
- package/dist/{src/search → search}/index.d.ts +2 -1
- package/dist/search/index.js +7 -0
- package/dist/{src/search → search}/pruneGherkinDocuments.d.ts +3 -4
- package/dist/search/pruneGherkinDocuments.js +179 -0
- package/dist/search/pruneTestCaseEvents.d.ts +16 -0
- package/dist/search/pruneTestCaseEvents.js +41 -0
- package/dist/{src/search → search}/types.d.ts +5 -6
- package/dist/search/types.js +2 -0
- package/dist/{src/statuses.d.ts → statuses.d.ts} +0 -1
- package/dist/statuses.js +12 -0
- package/dist/{src/toRepositoryId.d.ts → toRepositoryId.d.ts} +0 -1
- package/dist/toRepositoryId.js +12 -0
- package/package.json +30 -32
- package/dist/src/CucumberQueryContext.d.ts.map +0 -1
- package/dist/src/CucumberQueryContext.js +0 -4
- package/dist/src/CucumberQueryContext.js.map +0 -1
- package/dist/src/GherkinQueryContext.d.ts.map +0 -1
- package/dist/src/GherkinQueryContext.js +0 -4
- package/dist/src/GherkinQueryContext.js.map +0 -1
- package/dist/src/SearchContext.d.ts.map +0 -1
- package/dist/src/SearchContext.js +0 -10
- package/dist/src/SearchContext.js.map +0 -1
- package/dist/src/ciCommitLink.d.ts.map +0 -1
- package/dist/src/ciCommitLink.js +0 -12
- package/dist/src/ciCommitLink.js.map +0 -1
- package/dist/src/components/app/CICommitLink.d.ts.map +0 -1
- package/dist/src/components/app/CICommitLink.js +0 -16
- package/dist/src/components/app/CICommitLink.js.map +0 -1
- package/dist/src/components/app/CIJobLink.d.ts.map +0 -1
- package/dist/src/components/app/CIJobLink.js +0 -10
- package/dist/src/components/app/CIJobLink.js.map +0 -1
- package/dist/src/components/app/ControlledSearchProvider.d.ts.map +0 -1
- package/dist/src/components/app/ControlledSearchProvider.js +0 -39
- package/dist/src/components/app/ControlledSearchProvider.js.map +0 -1
- package/dist/src/components/app/CopyButton.d.ts.map +0 -1
- package/dist/src/components/app/CopyButton.js +0 -23
- package/dist/src/components/app/CopyButton.js.map +0 -1
- package/dist/src/components/app/DocumentAccordion.d.ts.map +0 -1
- package/dist/src/components/app/DocumentAccordion.js +0 -22
- package/dist/src/components/app/DocumentAccordion.js.map +0 -1
- package/dist/src/components/app/EnvelopesProvider.d.ts.map +0 -1
- package/dist/src/components/app/EnvelopesProvider.js +0 -18
- package/dist/src/components/app/EnvelopesProvider.js.map +0 -1
- package/dist/src/components/app/ExecutionSummary.d.ts.map +0 -1
- package/dist/src/components/app/ExecutionSummary.js +0 -38
- package/dist/src/components/app/ExecutionSummary.js.map +0 -1
- package/dist/src/components/app/FilteredDocuments.d.ts.map +0 -1
- package/dist/src/components/app/FilteredDocuments.js +0 -15
- package/dist/src/components/app/FilteredDocuments.js.map +0 -1
- package/dist/src/components/app/GherkinDocumentList.d.ts.map +0 -1
- package/dist/src/components/app/GherkinDocumentList.js +0 -23
- package/dist/src/components/app/GherkinDocumentList.js.map +0 -1
- package/dist/src/components/app/Header.d.ts.map +0 -1
- package/dist/src/components/app/Header.js +0 -12
- package/dist/src/components/app/Header.js.map +0 -1
- package/dist/src/components/app/HealthChart.d.ts.map +0 -1
- package/dist/src/components/app/HealthChart.js +0 -14
- package/dist/src/components/app/HealthChart.js.map +0 -1
- package/dist/src/components/app/HighLight.d.ts.map +0 -1
- package/dist/src/components/app/HighLight.js +0 -38
- package/dist/src/components/app/HighLight.js.map +0 -1
- package/dist/src/components/app/ImplementationIcon.d.ts.map +0 -1
- package/dist/src/components/app/ImplementationIcon.js +0 -10
- package/dist/src/components/app/ImplementationIcon.js.map +0 -1
- package/dist/src/components/app/InMemorySearchProvider.d.ts.map +0 -1
- package/dist/src/components/app/InMemorySearchProvider.js +0 -11
- package/dist/src/components/app/InMemorySearchProvider.js.map +0 -1
- package/dist/src/components/app/NavigationButton.d.ts.map +0 -1
- package/dist/src/components/app/NavigationButton.js +0 -6
- package/dist/src/components/app/NavigationButton.js.map +0 -1
- package/dist/src/components/app/OSIcon.d.ts.map +0 -1
- package/dist/src/components/app/OSIcon.js +0 -18
- package/dist/src/components/app/OSIcon.js.map +0 -1
- package/dist/src/components/app/QueriesProvider.d.ts.map +0 -1
- package/dist/src/components/app/QueriesProvider.js +0 -7
- package/dist/src/components/app/QueriesProvider.js.map +0 -1
- package/dist/src/components/app/Report.d.ts.map +0 -1
- package/dist/src/components/app/Report.js +0 -10
- package/dist/src/components/app/Report.js.map +0 -1
- package/dist/src/components/app/RuntimeIcon.d.ts.map +0 -1
- package/dist/src/components/app/RuntimeIcon.js +0 -18
- package/dist/src/components/app/RuntimeIcon.js.map +0 -1
- package/dist/src/components/app/SearchBar.d.ts.map +0 -1
- package/dist/src/components/app/SearchBar.js +0 -33
- package/dist/src/components/app/SearchBar.js.map +0 -1
- package/dist/src/components/app/StatusesSummary.d.ts.map +0 -1
- package/dist/src/components/app/StatusesSummary.js +0 -16
- package/dist/src/components/app/StatusesSummary.js.map +0 -1
- package/dist/src/components/app/TestRunHooks.d.ts.map +0 -1
- package/dist/src/components/app/TestRunHooks.js +0 -14
- package/dist/src/components/app/TestRunHooks.js.map +0 -1
- package/dist/src/components/app/UrlSearchProvider.d.ts.map +0 -1
- package/dist/src/components/app/UrlSearchProvider.js +0 -29
- package/dist/src/components/app/UrlSearchProvider.js.map +0 -1
- package/dist/src/components/app/findMostSevereTestStepResultStatus.d.ts.map +0 -1
- package/dist/src/components/app/findMostSevereTestStepResultStatus.js +0 -17
- package/dist/src/components/app/findMostSevereTestStepResultStatus.js.map +0 -1
- package/dist/src/components/app/icons/CucumberLogo.d.ts.map +0 -1
- package/dist/src/components/app/icons/CucumberLogo.js +0 -5
- package/dist/src/components/app/icons/CucumberLogo.js.map +0 -1
- package/dist/src/components/app/icons/Jvm.d.ts.map +0 -1
- package/dist/src/components/app/icons/Jvm.js +0 -5
- package/dist/src/components/app/icons/Jvm.js.map +0 -1
- package/dist/src/components/app/icons/Linux.d.ts.map +0 -1
- package/dist/src/components/app/icons/Linux.js +0 -5
- package/dist/src/components/app/icons/Linux.js.map +0 -1
- package/dist/src/components/app/icons/MacOS.d.ts.map +0 -1
- package/dist/src/components/app/icons/MacOS.js +0 -5
- package/dist/src/components/app/icons/MacOS.js.map +0 -1
- package/dist/src/components/app/icons/NodeJs.d.ts.map +0 -1
- package/dist/src/components/app/icons/NodeJs.js +0 -5
- package/dist/src/components/app/icons/NodeJs.js.map +0 -1
- package/dist/src/components/app/icons/Ruby.d.ts.map +0 -1
- package/dist/src/components/app/icons/Ruby.js +0 -5
- package/dist/src/components/app/icons/Ruby.js.map +0 -1
- package/dist/src/components/app/icons/Windows.d.ts.map +0 -1
- package/dist/src/components/app/icons/Windows.js +0 -5
- package/dist/src/components/app/icons/Windows.js.map +0 -1
- package/dist/src/components/app/index.d.ts +0 -15
- package/dist/src/components/app/index.d.ts.map +0 -1
- package/dist/src/components/app/index.js.map +0 -1
- package/dist/src/components/app/makeSetupString.d.ts.map +0 -1
- package/dist/src/components/app/makeSetupString.js +0 -21
- package/dist/src/components/app/makeSetupString.js.map +0 -1
- package/dist/src/components/app/markdownComponents.d.ts.map +0 -1
- package/dist/src/components/app/markdownComponents.js +0 -6
- package/dist/src/components/app/markdownComponents.js.map +0 -1
- package/dist/src/components/app/rehypePlugins.d.ts.map +0 -1
- package/dist/src/components/app/rehypePlugins.js +0 -9
- package/dist/src/components/app/rehypePlugins.js.map +0 -1
- package/dist/src/components/app/remarkPlugins.d.ts.map +0 -1
- package/dist/src/components/app/remarkPlugins.js +0 -4
- package/dist/src/components/app/remarkPlugins.js.map +0 -1
- package/dist/src/components/customise/CustomRendering.d.ts.map +0 -1
- package/dist/src/components/customise/CustomRendering.js +0 -35
- package/dist/src/components/customise/CustomRendering.js.map +0 -1
- package/dist/src/components/customise/index.d.ts +0 -3
- package/dist/src/components/customise/index.d.ts.map +0 -1
- package/dist/src/components/customise/index.js.map +0 -1
- package/dist/src/components/customise/theming.d.ts.map +0 -1
- package/dist/src/components/customise/theming.js +0 -2
- package/dist/src/components/customise/theming.js.map +0 -1
- package/dist/src/components/gherkin/Anchor.d.ts.map +0 -1
- package/dist/src/components/gherkin/Anchor.js +0 -13
- package/dist/src/components/gherkin/Anchor.js.map +0 -1
- package/dist/src/components/gherkin/Background.d.ts.map +0 -1
- package/dist/src/components/gherkin/Background.js +0 -18
- package/dist/src/components/gherkin/Background.js.map +0 -1
- package/dist/src/components/gherkin/Children.d.ts.map +0 -1
- package/dist/src/components/gherkin/Children.js +0 -11
- package/dist/src/components/gherkin/Children.js.map +0 -1
- package/dist/src/components/gherkin/DataTable.d.ts.map +0 -1
- package/dist/src/components/gherkin/DataTable.js +0 -16
- package/dist/src/components/gherkin/DataTable.js.map +0 -1
- package/dist/src/components/gherkin/Description.d.ts.map +0 -1
- package/dist/src/components/gherkin/Description.js +0 -15
- package/dist/src/components/gherkin/Description.js.map +0 -1
- package/dist/src/components/gherkin/DocString.d.ts.map +0 -1
- package/dist/src/components/gherkin/DocString.js +0 -12
- package/dist/src/components/gherkin/DocString.js.map +0 -1
- package/dist/src/components/gherkin/ErrorMessage.d.ts.map +0 -1
- package/dist/src/components/gherkin/ErrorMessage.js +0 -13
- package/dist/src/components/gherkin/ErrorMessage.js.map +0 -1
- package/dist/src/components/gherkin/Examples.d.ts.map +0 -1
- package/dist/src/components/gherkin/Examples.js +0 -31
- package/dist/src/components/gherkin/Examples.js.map +0 -1
- package/dist/src/components/gherkin/Feature.d.ts.map +0 -1
- package/dist/src/components/gherkin/Feature.js +0 -30
- package/dist/src/components/gherkin/Feature.js.map +0 -1
- package/dist/src/components/gherkin/GherkinDocument.d.ts.map +0 -1
- package/dist/src/components/gherkin/GherkinDocument.js +0 -11
- package/dist/src/components/gherkin/GherkinDocument.js.map +0 -1
- package/dist/src/components/gherkin/Keyword.d.ts.map +0 -1
- package/dist/src/components/gherkin/Keyword.js +0 -11
- package/dist/src/components/gherkin/Keyword.js.map +0 -1
- package/dist/src/components/gherkin/Parameter.d.ts.map +0 -1
- package/dist/src/components/gherkin/Parameter.js +0 -11
- package/dist/src/components/gherkin/Parameter.js.map +0 -1
- package/dist/src/components/gherkin/Rule.d.ts.map +0 -1
- package/dist/src/components/gherkin/Rule.js +0 -26
- package/dist/src/components/gherkin/Rule.js.map +0 -1
- package/dist/src/components/gherkin/Scenario.d.ts.map +0 -1
- package/dist/src/components/gherkin/Scenario.js +0 -22
- package/dist/src/components/gherkin/Scenario.js.map +0 -1
- package/dist/src/components/gherkin/StatusIcon.d.ts.map +0 -1
- package/dist/src/components/gherkin/StatusIcon.js +0 -24
- package/dist/src/components/gherkin/StatusIcon.js.map +0 -1
- package/dist/src/components/gherkin/StepsList.d.ts.map +0 -1
- package/dist/src/components/gherkin/StepsList.js +0 -6
- package/dist/src/components/gherkin/StepsList.js.map +0 -1
- package/dist/src/components/gherkin/Tags.d.ts.map +0 -1
- package/dist/src/components/gherkin/Tags.js +0 -15
- package/dist/src/components/gherkin/Tags.js.map +0 -1
- package/dist/src/components/gherkin/Title.d.ts.map +0 -1
- package/dist/src/components/gherkin/Title.js +0 -12
- package/dist/src/components/gherkin/Title.js.map +0 -1
- package/dist/src/components/gherkin/attachment/Attachment.d.ts.map +0 -1
- package/dist/src/components/gherkin/attachment/Attachment.js +0 -45
- package/dist/src/components/gherkin/attachment/Attachment.js.map +0 -1
- package/dist/src/components/gherkin/attachment/Image.d.ts.map +0 -1
- package/dist/src/components/gherkin/attachment/Image.js +0 -16
- package/dist/src/components/gherkin/attachment/Image.js.map +0 -1
- package/dist/src/components/gherkin/attachment/Links.d.ts.map +0 -1
- package/dist/src/components/gherkin/attachment/Links.js +0 -14
- package/dist/src/components/gherkin/attachment/Links.js.map +0 -1
- package/dist/src/components/gherkin/attachment/Log.d.ts.map +0 -1
- package/dist/src/components/gherkin/attachment/Log.js +0 -12
- package/dist/src/components/gherkin/attachment/Log.js.map +0 -1
- package/dist/src/components/gherkin/attachment/Text.d.ts.map +0 -1
- package/dist/src/components/gherkin/attachment/Text.js +0 -16
- package/dist/src/components/gherkin/attachment/Text.js.map +0 -1
- package/dist/src/components/gherkin/attachment/Unknown.d.ts.map +0 -1
- package/dist/src/components/gherkin/attachment/Unknown.js +0 -61
- package/dist/src/components/gherkin/attachment/Unknown.js.map +0 -1
- package/dist/src/components/gherkin/attachment/Video.d.ts.map +0 -1
- package/dist/src/components/gherkin/attachment/Video.js +0 -16
- package/dist/src/components/gherkin/attachment/Video.js.map +0 -1
- package/dist/src/components/gherkin/attachment/attachmentFilename.d.ts.map +0 -1
- package/dist/src/components/gherkin/attachment/attachmentFilename.js +0 -12
- package/dist/src/components/gherkin/attachment/attachmentFilename.js.map +0 -1
- package/dist/src/components/gherkin/attachment/base64Decode.d.ts.map +0 -1
- package/dist/src/components/gherkin/attachment/base64Decode.js +0 -19
- package/dist/src/components/gherkin/attachment/base64Decode.js.map +0 -1
- package/dist/src/components/gherkin/attachment/index.d.ts +0 -2
- package/dist/src/components/gherkin/attachment/index.d.ts.map +0 -1
- package/dist/src/components/gherkin/attachment/index.js.map +0 -1
- package/dist/src/components/gherkin/attachment/useText.d.ts.map +0 -1
- package/dist/src/components/gherkin/attachment/useText.js +0 -28
- package/dist/src/components/gherkin/attachment/useText.js.map +0 -1
- package/dist/src/components/gherkin/composeHookStepTitle.d.ts.map +0 -1
- package/dist/src/components/gherkin/composeHookStepTitle.js +0 -23
- package/dist/src/components/gherkin/composeHookStepTitle.js.map +0 -1
- package/dist/src/components/gherkin/composePickleStepTitle.d.ts.map +0 -1
- package/dist/src/components/gherkin/composePickleStepTitle.js +0 -36
- package/dist/src/components/gherkin/composePickleStepTitle.js.map +0 -1
- package/dist/src/components/gherkin/index.d.ts +0 -19
- package/dist/src/components/gherkin/index.d.ts.map +0 -1
- package/dist/src/components/gherkin/index.js.map +0 -1
- package/dist/src/components/gherkin/isNumber.d.ts.map +0 -1
- package/dist/src/components/gherkin/isNumber.js +0 -7
- package/dist/src/components/gherkin/isNumber.js.map +0 -1
- package/dist/src/components/gherkin/statusName.d.ts +0 -4
- package/dist/src/components/gherkin/statusName.d.ts.map +0 -1
- package/dist/src/components/gherkin/statusName.js +0 -4
- package/dist/src/components/gherkin/statusName.js.map +0 -1
- package/dist/src/components/index.d.ts +0 -4
- package/dist/src/components/index.d.ts.map +0 -1
- package/dist/src/components/index.js.map +0 -1
- package/dist/src/components/results/AmbiguousResult.d.ts.map +0 -1
- package/dist/src/components/results/AmbiguousResult.js +0 -11
- package/dist/src/components/results/AmbiguousResult.js.map +0 -1
- package/dist/src/components/results/FailedResult.d.ts.map +0 -1
- package/dist/src/components/results/FailedResult.js +0 -15
- package/dist/src/components/results/FailedResult.js.map +0 -1
- package/dist/src/components/results/PendingResult.d.ts.map +0 -1
- package/dist/src/components/results/PendingResult.js +0 -12
- package/dist/src/components/results/PendingResult.js.map +0 -1
- package/dist/src/components/results/ResultNote.d.ts.map +0 -1
- package/dist/src/components/results/ResultNote.js +0 -6
- package/dist/src/components/results/ResultNote.js.map +0 -1
- package/dist/src/components/results/SkippedResult.d.ts.map +0 -1
- package/dist/src/components/results/SkippedResult.js +0 -12
- package/dist/src/components/results/SkippedResult.js.map +0 -1
- package/dist/src/components/results/SourceReference.d.ts.map +0 -1
- package/dist/src/components/results/SourceReference.js +0 -13
- package/dist/src/components/results/SourceReference.js.map +0 -1
- package/dist/src/components/results/TestCaseOutcome.d.ts.map +0 -1
- package/dist/src/components/results/TestCaseOutcome.js +0 -32
- package/dist/src/components/results/TestCaseOutcome.js.map +0 -1
- package/dist/src/components/results/TestRunHookOutcome.d.ts.map +0 -1
- package/dist/src/components/results/TestRunHookOutcome.js +0 -11
- package/dist/src/components/results/TestRunHookOutcome.js.map +0 -1
- package/dist/src/components/results/TestStepAttachments.d.ts.map +0 -1
- package/dist/src/components/results/TestStepAttachments.js +0 -12
- package/dist/src/components/results/TestStepAttachments.js.map +0 -1
- package/dist/src/components/results/TestStepDuration.d.ts.map +0 -1
- package/dist/src/components/results/TestStepDuration.js +0 -19
- package/dist/src/components/results/TestStepDuration.js.map +0 -1
- package/dist/src/components/results/TestStepOutcome.d.ts.map +0 -1
- package/dist/src/components/results/TestStepOutcome.js +0 -45
- package/dist/src/components/results/TestStepOutcome.js.map +0 -1
- package/dist/src/components/results/UndefinedResult.d.ts.map +0 -1
- package/dist/src/components/results/UndefinedResult.js +0 -18
- package/dist/src/components/results/UndefinedResult.js.map +0 -1
- package/dist/src/components/results/index.d.ts +0 -3
- package/dist/src/components/results/index.d.ts.map +0 -1
- package/dist/src/components/results/index.js.map +0 -1
- package/dist/src/formatExecutionDistance.d.ts.map +0 -1
- package/dist/src/formatExecutionDistance.js +0 -7
- package/dist/src/formatExecutionDistance.js.map +0 -1
- package/dist/src/formatExecutionDuration.d.ts.map +0 -1
- package/dist/src/formatExecutionDuration.js +0 -12
- package/dist/src/formatExecutionDuration.js.map +0 -1
- package/dist/src/formatPassedQuantity.d.ts.map +0 -1
- package/dist/src/formatPassedQuantity.js +0 -4
- package/dist/src/formatPassedQuantity.js.map +0 -1
- package/dist/src/formatStatusRate.d.ts.map +0 -1
- package/dist/src/formatStatusRate.js +0 -9
- package/dist/src/formatStatusRate.js.map +0 -1
- package/dist/src/hooks/helpers.d.ts.map +0 -1
- package/dist/src/hooks/helpers.js +0 -7
- package/dist/src/hooks/helpers.js.map +0 -1
- package/dist/src/hooks/index.d.ts +0 -3
- package/dist/src/hooks/index.d.ts.map +0 -1
- package/dist/src/hooks/index.js.map +0 -1
- package/dist/src/hooks/useFilteredDocuments.d.ts.map +0 -1
- package/dist/src/hooks/useFilteredDocuments.js +0 -85
- package/dist/src/hooks/useFilteredDocuments.js.map +0 -1
- package/dist/src/hooks/useMostSevereStatusByUri.d.ts.map +0 -1
- package/dist/src/hooks/useMostSevereStatusByUri.js +0 -25
- package/dist/src/hooks/useMostSevereStatusByUri.js.map +0 -1
- package/dist/src/hooks/useQueries.d.ts.map +0 -1
- package/dist/src/hooks/useQueries.js +0 -9
- package/dist/src/hooks/useQueries.js.map +0 -1
- package/dist/src/hooks/useResultStatistics.d.ts.map +0 -1
- package/dist/src/hooks/useResultStatistics.js +0 -24
- package/dist/src/hooks/useResultStatistics.js.map +0 -1
- package/dist/src/hooks/useSearch.d.ts.map +0 -1
- package/dist/src/hooks/useSearch.js +0 -6
- package/dist/src/hooks/useSearch.js.map +0 -1
- package/dist/src/hooks/useTestCaseStarted.d.ts.map +0 -1
- package/dist/src/hooks/useTestCaseStarted.js +0 -20
- package/dist/src/hooks/useTestCaseStarted.js.map +0 -1
- package/dist/src/hooks/useTestRunHooks.d.ts.map +0 -1
- package/dist/src/hooks/useTestRunHooks.js +0 -14
- package/dist/src/hooks/useTestRunHooks.js.map +0 -1
- package/dist/src/index.d.ts +0 -3
- package/dist/src/index.d.ts.map +0 -1
- package/dist/src/index.js.map +0 -1
- package/dist/src/isTagExpression.d.ts.map +0 -1
- package/dist/src/isTagExpression.js +0 -5
- package/dist/src/isTagExpression.js.map +0 -1
- package/dist/src/search/FeatureSearch.d.ts.map +0 -1
- package/dist/src/search/FeatureSearch.js +0 -37
- package/dist/src/search/FeatureSearch.js.map +0 -1
- package/dist/src/search/ScenarioLikeSearch.d.ts.map +0 -1
- package/dist/src/search/ScenarioLikeSearch.js +0 -37
- package/dist/src/search/ScenarioLikeSearch.js.map +0 -1
- package/dist/src/search/StepSearch.d.ts.map +0 -1
- package/dist/src/search/StepSearch.js +0 -40
- package/dist/src/search/StepSearch.js.map +0 -1
- package/dist/src/search/TextSearch.d.ts.map +0 -1
- package/dist/src/search/TextSearch.js +0 -70
- package/dist/src/search/TextSearch.js.map +0 -1
- package/dist/src/search/createSearchIndex.d.ts.map +0 -1
- package/dist/src/search/createSearchIndex.js +0 -10
- package/dist/src/search/createSearchIndex.js.map +0 -1
- package/dist/src/search/deriveLineageConstraints.d.ts.map +0 -1
- package/dist/src/search/deriveLineageConstraints.js +0 -38
- package/dist/src/search/deriveLineageConstraints.js.map +0 -1
- package/dist/src/search/index.d.ts.map +0 -1
- package/dist/src/search/index.js +0 -5
- package/dist/src/search/index.js.map +0 -1
- package/dist/src/search/pruneGherkinDocuments.d.ts.map +0 -1
- package/dist/src/search/pruneGherkinDocuments.js +0 -180
- package/dist/src/search/pruneGherkinDocuments.js.map +0 -1
- package/dist/src/search/types.d.ts.map +0 -1
- package/dist/src/search/types.js +0 -2
- package/dist/src/search/types.js.map +0 -1
- package/dist/src/statuses.d.ts.map +0 -1
- package/dist/src/statuses.js +0 -12
- package/dist/src/statuses.js.map +0 -1
- package/dist/src/toRepositoryId.d.ts.map +0 -1
- package/dist/src/toRepositoryId.js +0 -12
- package/dist/src/toRepositoryId.js.map +0 -1
- package/dist/tsconfig.build.tsbuildinfo +0 -1
- /package/dist/{src/components → components}/app/CopyButton.module.scss +0 -0
- /package/dist/{src/components → components}/app/DocumentAccordion.module.scss +0 -0
- /package/dist/{src/components → components}/app/ExecutionSummary.module.scss +0 -0
- /package/dist/{src/components → components}/app/FilteredDocuments.module.scss +0 -0
- /package/dist/{src/components → components}/app/Header.module.scss +0 -0
- /package/dist/{src/components → components}/app/HealthChart.module.scss +0 -0
- /package/dist/{src/components → components}/app/NavigationButton.module.scss +0 -0
- /package/dist/{src/components → components}/app/Report.module.scss +0 -0
- /package/dist/{src/components → components}/app/SearchBar.module.scss +0 -0
- /package/dist/{src/components → components}/app/StatusesSummary.module.scss +0 -0
- /package/dist/{src/components → components}/app/TestRunHooks.module.scss +0 -0
- /package/dist/{src/components → components}/customise/CustomRendering.stories.scss +0 -0
- /package/dist/{src/components → components}/gherkin/Anchor.module.scss +0 -0
- /package/dist/{src/components → components}/gherkin/Children.module.scss +0 -0
- /package/dist/{src/components → components}/gherkin/DataTable.module.scss +0 -0
- /package/dist/{src/components → components}/gherkin/Description.module.scss +0 -0
- /package/dist/{src/components → components}/gherkin/DocString.module.scss +0 -0
- /package/dist/{src/components → components}/gherkin/ErrorMessage.module.scss +0 -0
- /package/dist/{src/components → components}/gherkin/Examples.module.scss +0 -0
- /package/dist/{src/components → components}/gherkin/Keyword.module.scss +0 -0
- /package/dist/{src/components → components}/gherkin/Parameter.module.scss +0 -0
- /package/dist/{src/components → components}/gherkin/StatusIcon.module.scss +0 -0
- /package/dist/{src/components → components}/gherkin/StepsList.module.scss +0 -0
- /package/dist/{src/components → components}/gherkin/Tags.module.scss +0 -0
- /package/dist/{src/components → components}/gherkin/Title.module.scss +0 -0
- /package/dist/{src/components → components}/gherkin/attachment/Attachment.module.scss +0 -0
- /package/dist/{src/components → components}/results/AmbiguousResult.module.scss +0 -0
- /package/dist/{src/components → components}/results/ResultNote.module.scss +0 -0
- /package/dist/{src/components → components}/results/SourceReference.module.scss +0 -0
- /package/dist/{src/components → components}/results/TestCaseOutcome.module.scss +0 -0
- /package/dist/{src/components → components}/results/TestRunHookOutcome.module.scss +0 -0
- /package/dist/{src/components → components}/results/TestStepAttachments.module.scss +0 -0
- /package/dist/{src/components → components}/results/TestStepDuration.module.scss +0 -0
- /package/dist/{src/components → components}/results/TestStepOutcome.module.scss +0 -0
- /package/dist/{src/components → components}/results/UndefinedResult.module.scss +0 -0
- /package/dist/{src/styles → styles}/statuses.scss +0 -0
- /package/dist/{src/styles → styles}/tables.scss +0 -0
- /package/dist/{src/styles → styles}/theming.scss +0 -0
|
@@ -1,180 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Returns abridged copies of the given documents, with lineage constraints and search hits used
|
|
3
|
-
* to filter out nodes that shouldn't be shown
|
|
4
|
-
*
|
|
5
|
-
* @param gherkinDocuments - the original documents to prune
|
|
6
|
-
* @param constraints - the set of AST node IDs to retain, derived from pickle lineage
|
|
7
|
-
* @param searchHits - if provided, further narrows results to nodes matching a search query
|
|
8
|
-
*
|
|
9
|
-
* @remarks
|
|
10
|
-
* The two filtering mechanisms behave a little differently.
|
|
11
|
-
*
|
|
12
|
-
* `lineageConstraints` are strictly enforced at every level - any node of the covered types must
|
|
13
|
-
* have its id included otherwise it will be filtered off. This check is performed eagerly at every
|
|
14
|
-
* level so for e.g. a Rule that isn't matched, we won't even look at its child Scenarios.
|
|
15
|
-
*
|
|
16
|
-
* `searchHits` has cascading behaviour - a match at a higher level (Feature, Rule, or Background)
|
|
17
|
-
* ensures all of its descendants will be retained, and a match at a lower level (Scenario, Step)
|
|
18
|
-
* ensures all of its ascendants (but not siblings) will be retained. A `false` value means there
|
|
19
|
-
* were no hits at all, so no documents will be returned.
|
|
20
|
-
*/
|
|
21
|
-
export function pruneGherkinDocuments(gherkinDocuments, constraints, searchHits) {
|
|
22
|
-
if (searchHits === false) {
|
|
23
|
-
return [];
|
|
24
|
-
}
|
|
25
|
-
const results = [];
|
|
26
|
-
for (const gherkinDocument of gherkinDocuments) {
|
|
27
|
-
if (!gherkinDocument.uri) {
|
|
28
|
-
continue;
|
|
29
|
-
}
|
|
30
|
-
if (!constraints.gherkinDocument.has(gherkinDocument.uri)) {
|
|
31
|
-
continue;
|
|
32
|
-
}
|
|
33
|
-
const documentHits = searchHits?.get(gherkinDocument.uri);
|
|
34
|
-
if (searchHits && !documentHits) {
|
|
35
|
-
continue;
|
|
36
|
-
}
|
|
37
|
-
const pruned = pruneGherkinDocument(gherkinDocument, constraints, documentHits);
|
|
38
|
-
if (pruned) {
|
|
39
|
-
results.push(pruned);
|
|
40
|
-
}
|
|
41
|
-
}
|
|
42
|
-
return results;
|
|
43
|
-
}
|
|
44
|
-
function pruneGherkinDocument(gherkinDocument, constraints, searchHits) {
|
|
45
|
-
if (searchHits?.feature) {
|
|
46
|
-
searchHits = undefined;
|
|
47
|
-
}
|
|
48
|
-
const feature = filterFeature(gherkinDocument.feature, constraints, searchHits);
|
|
49
|
-
if (feature) {
|
|
50
|
-
return {
|
|
51
|
-
...gherkinDocument,
|
|
52
|
-
feature,
|
|
53
|
-
};
|
|
54
|
-
}
|
|
55
|
-
}
|
|
56
|
-
function filterFeature(feature, constraints, searchHits) {
|
|
57
|
-
if (!feature) {
|
|
58
|
-
return undefined;
|
|
59
|
-
}
|
|
60
|
-
if (searchHits && matchesOnBackground(feature.children, searchHits)) {
|
|
61
|
-
searchHits = undefined;
|
|
62
|
-
}
|
|
63
|
-
const children = feature.children
|
|
64
|
-
.map((child) => filterFeatureChild(child, constraints, searchHits))
|
|
65
|
-
.filter((child) => !!child);
|
|
66
|
-
if (children.some((child) => !child.background)) {
|
|
67
|
-
return {
|
|
68
|
-
...feature,
|
|
69
|
-
children,
|
|
70
|
-
};
|
|
71
|
-
}
|
|
72
|
-
}
|
|
73
|
-
function filterFeatureChild(child, constraints, searchHits) {
|
|
74
|
-
if (child.background) {
|
|
75
|
-
const background = filterBackground(child.background, constraints);
|
|
76
|
-
if (background) {
|
|
77
|
-
return {
|
|
78
|
-
background,
|
|
79
|
-
};
|
|
80
|
-
}
|
|
81
|
-
}
|
|
82
|
-
if (child.scenario) {
|
|
83
|
-
const scenario = filterScenario(child.scenario, constraints, searchHits);
|
|
84
|
-
if (scenario) {
|
|
85
|
-
return {
|
|
86
|
-
scenario,
|
|
87
|
-
};
|
|
88
|
-
}
|
|
89
|
-
}
|
|
90
|
-
if (child.rule) {
|
|
91
|
-
const rule = filterRule(child.rule, constraints, searchHits);
|
|
92
|
-
if (rule) {
|
|
93
|
-
return {
|
|
94
|
-
rule,
|
|
95
|
-
};
|
|
96
|
-
}
|
|
97
|
-
}
|
|
98
|
-
return undefined;
|
|
99
|
-
}
|
|
100
|
-
function filterBackground(background, constraints) {
|
|
101
|
-
return constraints.background.has(background.id) ? background : undefined;
|
|
102
|
-
}
|
|
103
|
-
function filterRule(rule, constraints, searchHits) {
|
|
104
|
-
if (!constraints.rule.has(rule.id)) {
|
|
105
|
-
return undefined;
|
|
106
|
-
}
|
|
107
|
-
if (searchHits &&
|
|
108
|
-
(searchHits.rule.includes(rule.id) || matchesOnBackground(rule.children, searchHits))) {
|
|
109
|
-
searchHits = undefined;
|
|
110
|
-
}
|
|
111
|
-
const children = rule.children
|
|
112
|
-
.map((child) => filterRuleChild(child, constraints, searchHits))
|
|
113
|
-
.filter((child) => !!child);
|
|
114
|
-
if (children.some((child) => !child.background)) {
|
|
115
|
-
return {
|
|
116
|
-
...rule,
|
|
117
|
-
children,
|
|
118
|
-
};
|
|
119
|
-
}
|
|
120
|
-
}
|
|
121
|
-
function filterRuleChild(child, constraints, searchHits) {
|
|
122
|
-
if (child.background) {
|
|
123
|
-
const background = filterBackground(child.background, constraints);
|
|
124
|
-
if (background) {
|
|
125
|
-
return {
|
|
126
|
-
background,
|
|
127
|
-
};
|
|
128
|
-
}
|
|
129
|
-
}
|
|
130
|
-
if (child.scenario) {
|
|
131
|
-
const scenario = filterScenario(child.scenario, constraints, searchHits);
|
|
132
|
-
if (scenario) {
|
|
133
|
-
return {
|
|
134
|
-
scenario,
|
|
135
|
-
};
|
|
136
|
-
}
|
|
137
|
-
}
|
|
138
|
-
return undefined;
|
|
139
|
-
}
|
|
140
|
-
function filterScenario(scenario, constraints, searchHits) {
|
|
141
|
-
if (!constraints.scenario.has(scenario.id)) {
|
|
142
|
-
return undefined;
|
|
143
|
-
}
|
|
144
|
-
if (searchHits &&
|
|
145
|
-
!searchHits.scenario.includes(scenario.id) &&
|
|
146
|
-
!matchesOnSteps(scenario.steps, searchHits)) {
|
|
147
|
-
return undefined;
|
|
148
|
-
}
|
|
149
|
-
return {
|
|
150
|
-
...scenario,
|
|
151
|
-
examples: scenario.examples
|
|
152
|
-
.map((examples) => filterExamplesTable(examples, constraints))
|
|
153
|
-
.filter((examples) => !!examples),
|
|
154
|
-
};
|
|
155
|
-
}
|
|
156
|
-
function filterExamplesTable(examples, constraints) {
|
|
157
|
-
if (!constraints.examples.has(examples.id)) {
|
|
158
|
-
return undefined;
|
|
159
|
-
}
|
|
160
|
-
return {
|
|
161
|
-
...examples,
|
|
162
|
-
tableBody: examples.tableBody
|
|
163
|
-
.map((row) => filterExampleRow(row, constraints))
|
|
164
|
-
.filter((row) => !!row),
|
|
165
|
-
};
|
|
166
|
-
}
|
|
167
|
-
function filterExampleRow(row, constraints) {
|
|
168
|
-
return constraints.example.has(row.id) ? row : undefined;
|
|
169
|
-
}
|
|
170
|
-
function matchesOnBackground(children, searchHits) {
|
|
171
|
-
return children
|
|
172
|
-
.map((child) => child.background)
|
|
173
|
-
.filter((background) => !!background)
|
|
174
|
-
.some((background) => searchHits.background.includes(background.id) ||
|
|
175
|
-
matchesOnSteps(background.steps, searchHits));
|
|
176
|
-
}
|
|
177
|
-
function matchesOnSteps(steps, searchHits) {
|
|
178
|
-
return steps.some((step) => searchHits.step.includes(step.id));
|
|
179
|
-
}
|
|
180
|
-
//# sourceMappingURL=pruneGherkinDocuments.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"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EAAE,CAAC,EAAE,CAAC;QAC3C,OAAO,SAAS,CAAA;IAClB,CAAC;IACD,OAAO;QACL,GAAG,QAAQ;QACX,SAAS,EAAE,QAAQ,CAAC,SAAS;aAC1B,GAAG,CAAC,CAAC,GAAG,EAAE,EAAE,CAAC,gBAAgB,CAAC,GAAG,EAAE,WAAW,CAAC,CAAC;aAChD,MAAM,CAAC,CAAC,GAAG,EAAE,EAAE,CAAC,CAAC,CAAC,GAAG,CAAC;KAC1B,CAAA;AACH,CAAC;AAED,SAAS,gBAAgB,CAAC,GAAa,EAAE,WAA+B;IACtE,OAAO,WAAW,CAAC,OAAO,CAAC,GAAG,CAAC,GAAG,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,SAAS,CAAA;AAC1D,CAAC;AAED,SAAS,mBAAmB,CAC1B,QAAkC,EAClC,UAA8B;IAE9B,OAAO,QAAQ;SACZ,GAAG,CAAC,CAAC,KAAK,EAAE,EAAE,CAAC,KAAK,CAAC,UAAU,CAAC;SAChC,MAAM,CAAC,CAAC,UAAU,EAAE,EAAE,CAAC,CAAC,CAAC,UAAU,CAAC;SACpC,IAAI,CACH,CAAC,UAAU,EAAE,EAAE,CACb,UAAU,CAAC,UAAU,CAAC,QAAQ,CAAC,UAAU,CAAC,EAAE,CAAC;QAC7C,cAAc,CAAC,UAAU,CAAC,KAAK,EAAE,UAAU,CAAC,CAC/C,CAAA;AACL,CAAC;AAED,SAAS,cAAc,CAAC,KAA0B,EAAE,UAA8B;IAChF,OAAO,KAAK,CAAC,IAAI,CAAC,CAAC,IAAI,EAAE,EAAE,CAAC,UAAU,CAAC,IAAI,CAAC,QAAQ,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC,CAAA;AAChE,CAAC","sourcesContent":["import type {\n Background,\n Examples,\n Feature,\n FeatureChild,\n GherkinDocument,\n Rule,\n RuleChild,\n Scenario,\n Step,\n TableRow,\n} from '@cucumber/messages'\nimport type { DocumentSearchHits, LineageConstraints, SearchHits } from './types.js'\n\n/**\n * Returns abridged copies of the given documents, with lineage constraints and search hits used\n * to filter out nodes that shouldn't be shown\n *\n * @param gherkinDocuments - the original documents to prune\n * @param constraints - the set of AST node IDs to retain, derived from pickle lineage\n * @param searchHits - if provided, further narrows results to nodes matching a search query\n *\n * @remarks\n * The two filtering mechanisms behave a little differently.\n *\n * `lineageConstraints` are strictly enforced at every level - any node of the covered types must\n * have its id included otherwise it will be filtered off. This check is performed eagerly at every\n * level so for e.g. a Rule that isn't matched, we won't even look at its child Scenarios.\n *\n * `searchHits` has cascading behaviour - a match at a higher level (Feature, Rule, or Background)\n * ensures all of its descendants will be retained, and a match at a lower level (Scenario, Step)\n * ensures all of its ascendants (but not siblings) will be retained. A `false` value means there\n * were no hits at all, so no documents will be returned.\n */\nexport function pruneGherkinDocuments(\n gherkinDocuments: ReadonlyArray<GherkinDocument>,\n constraints: LineageConstraints,\n searchHits?: SearchHits | false\n): ReadonlyArray<GherkinDocument> {\n if (searchHits === false) {\n return []\n }\n const results: GherkinDocument[] = []\n for (const gherkinDocument of gherkinDocuments) {\n if (!gherkinDocument.uri) {\n continue\n }\n if (!constraints.gherkinDocument.has(gherkinDocument.uri)) {\n continue\n }\n const documentHits = searchHits?.get(gherkinDocument.uri)\n if (searchHits && !documentHits) {\n continue\n }\n const pruned = pruneGherkinDocument(gherkinDocument, constraints, documentHits)\n if (pruned) {\n results.push(pruned)\n }\n }\n return results\n}\n\nfunction pruneGherkinDocument(\n gherkinDocument: GherkinDocument,\n constraints: LineageConstraints,\n searchHits?: DocumentSearchHits\n): GherkinDocument | undefined {\n if (searchHits?.feature) {\n searchHits = undefined\n }\n\n const feature = filterFeature(gherkinDocument.feature, constraints, searchHits)\n if (feature) {\n return {\n ...gherkinDocument,\n feature,\n }\n }\n}\n\nfunction filterFeature(\n feature: Feature | undefined,\n constraints: LineageConstraints,\n searchHits?: DocumentSearchHits\n): Feature | undefined {\n if (!feature) {\n return undefined\n }\n\n if (searchHits && matchesOnBackground(feature.children, searchHits)) {\n searchHits = undefined\n }\n\n const children = feature.children\n .map((child) => filterFeatureChild(child, constraints, searchHits))\n .filter((child) => !!child)\n\n if (children.some((child) => !child.background)) {\n return {\n ...feature,\n children,\n }\n }\n}\n\nfunction filterFeatureChild(\n child: FeatureChild,\n constraints: LineageConstraints,\n searchHits?: DocumentSearchHits\n): FeatureChild | undefined {\n if (child.background) {\n const background = filterBackground(child.background, constraints)\n if (background) {\n return {\n background,\n }\n }\n }\n if (child.scenario) {\n const scenario = filterScenario(child.scenario, constraints, searchHits)\n if (scenario) {\n return {\n scenario,\n }\n }\n }\n if (child.rule) {\n const rule = filterRule(child.rule, constraints, searchHits)\n if (rule) {\n return {\n rule,\n }\n }\n }\n return undefined\n}\n\nfunction filterBackground(background: Background, constraints: LineageConstraints) {\n return constraints.background.has(background.id) ? background : undefined\n}\n\nfunction filterRule(\n rule: Rule,\n constraints: LineageConstraints,\n searchHits?: DocumentSearchHits\n): Rule | undefined {\n if (!constraints.rule.has(rule.id)) {\n return undefined\n }\n\n if (\n searchHits &&\n (searchHits.rule.includes(rule.id) || matchesOnBackground(rule.children, searchHits))\n ) {\n searchHits = undefined\n }\n\n const children = rule.children\n .map((child) => filterRuleChild(child, constraints, searchHits))\n .filter((child) => !!child)\n\n if (children.some((child) => !child.background)) {\n return {\n ...rule,\n children,\n }\n }\n}\n\nfunction filterRuleChild(\n child: RuleChild,\n constraints: LineageConstraints,\n searchHits?: DocumentSearchHits\n): RuleChild | undefined {\n if (child.background) {\n const background = filterBackground(child.background, constraints)\n if (background) {\n return {\n background,\n }\n }\n }\n if (child.scenario) {\n const scenario = filterScenario(child.scenario, constraints, searchHits)\n if (scenario) {\n return {\n scenario,\n }\n }\n }\n return undefined\n}\n\nfunction filterScenario(\n scenario: Scenario,\n constraints: LineageConstraints,\n searchHits?: DocumentSearchHits\n): Scenario | undefined {\n if (!constraints.scenario.has(scenario.id)) {\n return undefined\n }\n if (\n searchHits &&\n !searchHits.scenario.includes(scenario.id) &&\n !matchesOnSteps(scenario.steps, searchHits)\n ) {\n return undefined\n }\n return {\n ...scenario,\n examples: scenario.examples\n .map((examples) => filterExamplesTable(examples, constraints))\n .filter((examples) => !!examples),\n }\n}\n\nfunction filterExamplesTable(\n examples: Examples,\n constraints: LineageConstraints\n): Examples | undefined {\n if (!constraints.examples.has(examples.id)) {\n return undefined\n }\n return {\n ...examples,\n tableBody: examples.tableBody\n .map((row) => filterExampleRow(row, constraints))\n .filter((row) => !!row),\n }\n}\n\nfunction filterExampleRow(row: TableRow, constraints: LineageConstraints): TableRow | undefined {\n return constraints.example.has(row.id) ? row : undefined\n}\n\nfunction matchesOnBackground(\n children: ReadonlyArray<RuleChild>,\n searchHits: DocumentSearchHits\n): boolean {\n return children\n .map((child) => child.background)\n .filter((background) => !!background)\n .some(\n (background) =>\n searchHits.background.includes(background.id) ||\n matchesOnSteps(background.steps, searchHits)\n )\n}\n\nfunction matchesOnSteps(steps: ReadonlyArray<Step>, searchHits: DocumentSearchHits): boolean {\n return steps.some((step) => searchHits.step.includes(step.id))\n}\n"]}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/search/types.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,YAAY,OAAO,CAAA;AAEhC,MAAM,WAAW,QAAQ;IACvB,GAAG,EAAE,MAAM,CAAA;IACX,EAAE,EAAE,MAAM,CAAA;CACX;AAED;;;GAGG;AACH,MAAM,WAAW,UAAU,CAAC,UAAU,GAAG,OAAO;IAC9C,MAAM,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,OAAO,CAAC,aAAa,CAAC,QAAQ,CAAC,CAAC,CAAA;IAC3D,GAAG,EAAE,CAAC,IAAI,EAAE,UAAU,EAAE,GAAG,EAAE,MAAM,KAAK,OAAO,CAAC,IAAI,CAAC,CAAA;CACtD;AAED;;GAEG;AACH,MAAM,WAAW,WAAW;IAC1B,MAAM,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,OAAO,CAAC,UAAU,GAAG,KAAK,CAAC,CAAA;CACvD;AAED;;;GAGG;AACH,MAAM,WAAW,kBAAkB;IACjC,OAAO,EAAE,OAAO,CAAA;IAChB,UAAU,EAAE,KAAK,CAAC,MAAM,CAAC,CAAA;IACzB,IAAI,EAAE,KAAK,CAAC,MAAM,CAAC,CAAA;IACnB,QAAQ,EAAE,KAAK,CAAC,MAAM,CAAC,CAAA;IACvB,IAAI,EAAE,KAAK,CAAC,MAAM,CAAC,CAAA;CACpB;AAED,MAAM,MAAM,UAAU,GAAG,WAAW,CAAC,MAAM,EAAE,kBAAkB,CAAC,CAAA;AAEhE;;;;GAIG;AACH,MAAM,WAAW,kBAAkB;IACjC,eAAe,EAAE,WAAW,CAAC,MAAM,CAAC,CAAA;IACpC,UAAU,EAAE,WAAW,CAAC,MAAM,CAAC,CAAA;IAC/B,IAAI,EAAE,WAAW,CAAC,MAAM,CAAC,CAAA;IACzB,QAAQ,EAAE,WAAW,CAAC,MAAM,CAAC,CAAA;IAC7B,QAAQ,EAAE,WAAW,CAAC,MAAM,CAAC,CAAA;IAC7B,OAAO,EAAE,WAAW,CAAC,MAAM,CAAC,CAAA;CAC7B"}
|
package/dist/src/search/types.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../../src/search/types.ts"],"names":[],"mappings":"AAAA,MAAM,CAAC,MAAM,YAAY,GAAG,IAAI,CAAA","sourcesContent":["export const ID_SEPARATOR = '\\0'\n\nexport interface IndexHit {\n uri: string\n id: string\n}\n\n/**\n * Facade for an index that supports adding items of a given type and returning hits as an array\n * of uri/id pairs\n */\nexport interface TypedIndex<SourceType = unknown> {\n search: (query: string) => Promise<ReadonlyArray<IndexHit>>\n add: (item: SourceType, uri: string) => Promise<this>\n}\n\n/**\n * Interface for the top-level document search index\n */\nexport interface SearchIndex {\n search: (query: string) => Promise<SearchHits | false>\n}\n\n/**\n * Collection of Gherkin node ids that matched a search term for a single document, grouped by\n * node type\n */\nexport interface DocumentSearchHits {\n feature: boolean\n background: Array<string>\n rule: Array<string>\n scenario: Array<string>\n step: Array<string>\n}\n\nexport type SearchHits = ReadonlyMap<string, DocumentSearchHits>\n\n/**\n * Collection of Gherkin node ids harvested from executed test cases, grouped by node type\n * @remarks\n * In the case of `gherkinDocument`, the values are URIs\n */\nexport interface LineageConstraints {\n gherkinDocument: ReadonlySet<string>\n background: ReadonlySet<string>\n rule: ReadonlySet<string>\n scenario: ReadonlySet<string>\n examples: ReadonlySet<string>\n example: ReadonlySet<string>\n}\n"]}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"statuses.d.ts","sourceRoot":"","sources":["../../src/statuses.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,oBAAoB,EAAE,MAAM,oBAAoB,CAAA;AAEzD,QAAA,MAAM,QAAQ,EAAE,aAAa,CAAC,oBAAoB,CAQjD,CAAA;AACD,eAAe,QAAQ,CAAA"}
|
package/dist/src/statuses.js
DELETED
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
import { TestStepResultStatus } from '@cucumber/messages';
|
|
2
|
-
const statuses = [
|
|
3
|
-
TestStepResultStatus.UNKNOWN,
|
|
4
|
-
TestStepResultStatus.PASSED,
|
|
5
|
-
TestStepResultStatus.SKIPPED,
|
|
6
|
-
TestStepResultStatus.PENDING,
|
|
7
|
-
TestStepResultStatus.UNDEFINED,
|
|
8
|
-
TestStepResultStatus.AMBIGUOUS,
|
|
9
|
-
TestStepResultStatus.FAILED,
|
|
10
|
-
];
|
|
11
|
-
export default statuses;
|
|
12
|
-
//# sourceMappingURL=statuses.js.map
|
package/dist/src/statuses.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"statuses.js","sourceRoot":"","sources":["../../src/statuses.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,oBAAoB,EAAE,MAAM,oBAAoB,CAAA;AAEzD,MAAM,QAAQ,GAAwC;IACpD,oBAAoB,CAAC,OAAO;IAC5B,oBAAoB,CAAC,MAAM;IAC3B,oBAAoB,CAAC,OAAO;IAC5B,oBAAoB,CAAC,OAAO;IAC5B,oBAAoB,CAAC,SAAS;IAC9B,oBAAoB,CAAC,SAAS;IAC9B,oBAAoB,CAAC,MAAM;CAC5B,CAAA;AACD,eAAe,QAAQ,CAAA","sourcesContent":["import { TestStepResultStatus } from '@cucumber/messages'\n\nconst statuses: ReadonlyArray<TestStepResultStatus> = [\n TestStepResultStatus.UNKNOWN,\n TestStepResultStatus.PASSED,\n TestStepResultStatus.SKIPPED,\n TestStepResultStatus.PENDING,\n TestStepResultStatus.UNDEFINED,\n TestStepResultStatus.AMBIGUOUS,\n TestStepResultStatus.FAILED,\n]\nexport default statuses\n"]}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"toRepositoryId.d.ts","sourceRoot":"","sources":["../../src/toRepositoryId.ts"],"names":[],"mappings":"AAAA,MAAM,CAAC,OAAO,UAAU,cAAc,CAAC,MAAM,EAAE,MAAM,GAAG,MAAM,CAU7D"}
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
export default function toRepositoryId(remote) {
|
|
2
|
-
let result = remote;
|
|
3
|
-
if (!remote.includes('://') && remote.includes(':')) {
|
|
4
|
-
// scp style URL (not really a URL)
|
|
5
|
-
const [host, path] = remote.split(':', 2);
|
|
6
|
-
result = `ssh://${host}/${path}`;
|
|
7
|
-
}
|
|
8
|
-
result = result.replace(/\.git$/, '');
|
|
9
|
-
const url = new URL(result);
|
|
10
|
-
return `${url.hostname}${url.pathname}`;
|
|
11
|
-
}
|
|
12
|
-
//# sourceMappingURL=toRepositoryId.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"toRepositoryId.js","sourceRoot":"","sources":["../../src/toRepositoryId.ts"],"names":[],"mappings":"AAAA,MAAM,CAAC,OAAO,UAAU,cAAc,CAAC,MAAc;IACnD,IAAI,MAAM,GAAG,MAAM,CAAA;IACnB,IAAI,CAAC,MAAM,CAAC,QAAQ,CAAC,KAAK,CAAC,IAAI,MAAM,CAAC,QAAQ,CAAC,GAAG,CAAC,EAAE,CAAC;QACpD,mCAAmC;QACnC,MAAM,CAAC,IAAI,EAAE,IAAI,CAAC,GAAG,MAAM,CAAC,KAAK,CAAC,GAAG,EAAE,CAAC,CAAC,CAAA;QACzC,MAAM,GAAG,SAAS,IAAI,IAAI,IAAI,EAAE,CAAA;IAClC,CAAC;IACD,MAAM,GAAG,MAAM,CAAC,OAAO,CAAC,QAAQ,EAAE,EAAE,CAAC,CAAA;IACrC,MAAM,GAAG,GAAG,IAAI,GAAG,CAAC,MAAM,CAAC,CAAA;IAC3B,OAAO,GAAG,GAAG,CAAC,QAAQ,GAAG,GAAG,CAAC,QAAQ,EAAE,CAAA;AACzC,CAAC","sourcesContent":["export default function toRepositoryId(remote: string): string {\n let result = remote\n if (!remote.includes('://') && remote.includes(':')) {\n // scp style URL (not really a URL)\n const [host, path] = remote.split(':', 2)\n result = `ssh://${host}/${path}`\n }\n result = result.replace(/\\.git$/, '')\n const url = new URL(result)\n return `${url.hostname}${url.pathname}`\n}\n"]}
|