@cucumber/react-components 22.4.2 → 23.1.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 +35 -139
- package/dist/src/SearchContext.d.ts +12 -0
- package/dist/src/SearchContext.d.ts.map +1 -0
- package/dist/src/SearchContext.js +7 -0
- package/dist/src/SearchContext.js.map +1 -0
- package/dist/src/ciCommitLink.d.ts +2 -2
- package/dist/src/ciCommitLink.d.ts.map +1 -1
- package/dist/src/ciCommitLink.js +1 -1
- package/dist/src/ciCommitLink.js.map +1 -1
- package/dist/src/components/app/CICommitLink.d.ts +5 -7
- package/dist/src/components/app/CICommitLink.d.ts.map +1 -1
- package/dist/src/components/app/CICommitLink.js +12 -9
- package/dist/src/components/app/CICommitLink.js.map +1 -1
- package/dist/src/components/app/CIJobLink.d.ts +5 -7
- package/dist/src/components/app/CIJobLink.d.ts.map +1 -1
- package/dist/src/components/app/CIJobLink.js +8 -9
- package/dist/src/components/app/CIJobLink.js.map +1 -1
- package/dist/src/components/app/ControlledSearchProvider.d.ts +9 -0
- package/dist/src/components/app/ControlledSearchProvider.d.ts.map +1 -0
- package/dist/src/components/app/ControlledSearchProvider.js +15 -0
- package/dist/src/components/app/ControlledSearchProvider.js.map +1 -0
- package/dist/src/components/app/CopyButton.d.ts +5 -0
- package/dist/src/components/app/CopyButton.d.ts.map +1 -0
- package/dist/src/components/app/CopyButton.js +23 -0
- package/dist/src/components/app/CopyButton.js.map +1 -0
- package/dist/src/components/app/CopyButton.module.scss +14 -0
- package/dist/src/components/app/EnvelopesProvider.d.ts +8 -0
- package/dist/src/components/app/EnvelopesProvider.d.ts.map +1 -0
- package/dist/src/components/app/EnvelopesProvider.js +17 -0
- package/dist/src/components/app/EnvelopesProvider.js.map +1 -0
- package/dist/src/components/app/ExecutionSummary.d.ts +2 -12
- package/dist/src/components/app/ExecutionSummary.d.ts.map +1 -1
- package/dist/src/components/app/ExecutionSummary.js +66 -65
- package/dist/src/components/app/ExecutionSummary.js.map +1 -1
- package/dist/src/components/app/ExecutionSummary.module.scss +3 -58
- package/dist/src/components/app/FilteredDocuments.d.ts +3 -0
- package/dist/src/components/app/FilteredDocuments.d.ts.map +1 -0
- package/dist/src/components/app/FilteredDocuments.js +15 -0
- package/dist/src/components/app/FilteredDocuments.js.map +1 -0
- package/dist/src/components/app/GherkinDocumentList.d.ts +4 -4
- package/dist/src/components/app/GherkinDocumentList.d.ts.map +1 -1
- package/dist/src/components/app/GherkinDocumentList.js +26 -25
- package/dist/src/components/app/GherkinDocumentList.js.map +1 -1
- package/dist/src/components/app/GherkinDocumentList.module.scss +6 -6
- package/dist/src/components/app/Header.d.ts +5 -0
- package/dist/src/components/app/Header.d.ts.map +1 -0
- package/dist/src/components/app/Header.js +12 -0
- package/dist/src/components/app/Header.js.map +1 -0
- package/dist/src/components/app/Header.module.scss +43 -0
- package/dist/src/components/app/HealthChart.d.ts +3 -0
- package/dist/src/components/app/HealthChart.d.ts.map +1 -0
- package/dist/src/components/app/HealthChart.js +15 -0
- package/dist/src/components/app/HealthChart.js.map +1 -0
- package/dist/src/components/app/HealthChart.module.scss +9 -0
- package/dist/src/components/app/HighLight.js +2 -2
- package/dist/src/components/app/HighLight.js.map +1 -1
- package/dist/src/components/app/ImplementationIcon.d.ts +6 -0
- package/dist/src/components/app/ImplementationIcon.d.ts.map +1 -0
- package/dist/src/components/app/ImplementationIcon.js +10 -0
- package/dist/src/components/app/ImplementationIcon.js.map +1 -0
- package/dist/src/components/app/InMemorySearchProvider.d.ts +9 -0
- package/dist/src/components/app/InMemorySearchProvider.d.ts.map +1 -0
- package/dist/src/components/app/InMemorySearchProvider.js +10 -0
- package/dist/src/components/app/InMemorySearchProvider.js.map +1 -0
- package/dist/src/components/app/NavigationButton.module.scss +2 -2
- package/dist/src/components/app/NoMatchResult.d.ts +2 -6
- package/dist/src/components/app/NoMatchResult.d.ts.map +1 -1
- package/dist/src/components/app/NoMatchResult.js +2 -4
- package/dist/src/components/app/NoMatchResult.js.map +1 -1
- package/dist/src/components/app/OSIcon.d.ts +4 -3
- package/dist/src/components/app/OSIcon.d.ts.map +1 -1
- package/dist/src/components/app/OSIcon.js +3 -5
- package/dist/src/components/app/OSIcon.js.map +1 -1
- package/dist/src/components/app/QueriesProvider.d.ts +10 -0
- package/dist/src/components/app/QueriesProvider.d.ts.map +1 -0
- package/dist/src/components/app/QueriesProvider.js +6 -0
- package/dist/src/components/app/QueriesProvider.js.map +1 -0
- package/dist/src/components/app/RuntimeIcon.d.ts +4 -3
- package/dist/src/components/app/RuntimeIcon.d.ts.map +1 -1
- package/dist/src/components/app/RuntimeIcon.js +3 -5
- package/dist/src/components/app/RuntimeIcon.js.map +1 -1
- package/dist/src/components/app/SearchBar.d.ts +2 -11
- package/dist/src/components/app/SearchBar.d.ts.map +1 -1
- package/dist/src/components/app/SearchBar.js +35 -30
- package/dist/src/components/app/SearchBar.js.map +1 -1
- package/dist/src/components/app/SearchBar.module.scss +55 -56
- package/dist/src/components/app/StatusesSummary.d.ts +2 -7
- package/dist/src/components/app/StatusesSummary.d.ts.map +1 -1
- package/dist/src/components/app/StatusesSummary.js +4 -2
- package/dist/src/components/app/StatusesSummary.js.map +1 -1
- package/dist/src/components/app/StatusesSummary.module.scss +2 -9
- package/dist/src/components/app/UriProvider.d.ts +5 -0
- package/dist/src/components/app/UriProvider.d.ts.map +1 -0
- package/dist/src/components/app/UriProvider.js +6 -0
- package/dist/src/components/app/UriProvider.js.map +1 -0
- package/dist/src/components/app/UrlSearchProvider.d.ts +8 -0
- package/dist/src/components/app/UrlSearchProvider.d.ts.map +1 -0
- package/dist/src/components/app/UrlSearchProvider.js +26 -0
- package/dist/src/components/app/UrlSearchProvider.js.map +1 -0
- package/dist/src/components/app/icons/CucumberLogo.d.ts +2 -2
- package/dist/src/components/app/icons/CucumberLogo.d.ts.map +1 -1
- package/dist/src/components/app/icons/CucumberLogo.js +1 -1
- package/dist/src/components/app/icons/CucumberLogo.js.map +1 -1
- package/dist/src/components/app/icons/Jvm.d.ts +2 -2
- package/dist/src/components/app/icons/Jvm.d.ts.map +1 -1
- package/dist/src/components/app/icons/Jvm.js +1 -1
- package/dist/src/components/app/icons/Jvm.js.map +1 -1
- package/dist/src/components/app/icons/Linux.d.ts +2 -2
- package/dist/src/components/app/icons/Linux.d.ts.map +1 -1
- package/dist/src/components/app/icons/Linux.js +1 -1
- package/dist/src/components/app/icons/Linux.js.map +1 -1
- package/dist/src/components/app/icons/MacOS.d.ts +2 -2
- package/dist/src/components/app/icons/MacOS.d.ts.map +1 -1
- package/dist/src/components/app/icons/MacOS.js +1 -1
- package/dist/src/components/app/icons/MacOS.js.map +1 -1
- package/dist/src/components/app/icons/NodeJs.d.ts +2 -2
- package/dist/src/components/app/icons/NodeJs.d.ts.map +1 -1
- package/dist/src/components/app/icons/NodeJs.js +4 -32
- package/dist/src/components/app/icons/NodeJs.js.map +1 -1
- package/dist/src/components/app/icons/Ruby.d.ts +2 -2
- package/dist/src/components/app/icons/Ruby.d.ts.map +1 -1
- package/dist/src/components/app/icons/Ruby.js +1 -1
- package/dist/src/components/app/icons/Ruby.js.map +1 -1
- package/dist/src/components/app/icons/Windows.d.ts +2 -2
- package/dist/src/components/app/icons/Windows.d.ts.map +1 -1
- package/dist/src/components/app/icons/Windows.js +1 -1
- package/dist/src/components/app/icons/Windows.js.map +1 -1
- package/dist/src/components/app/index.d.ts +7 -4
- package/dist/src/components/app/index.d.ts.map +1 -1
- package/dist/src/components/app/index.js +7 -4
- package/dist/src/components/app/index.js.map +1 -1
- package/dist/src/components/app/makeSetupString.d.ts +3 -0
- package/dist/src/components/app/makeSetupString.d.ts.map +1 -0
- package/dist/src/components/app/makeSetupString.js +21 -0
- package/dist/src/components/app/makeSetupString.js.map +1 -0
- package/dist/src/components/customise/{customRendering.d.ts → CustomRendering.d.ts} +5 -2
- package/dist/src/components/customise/CustomRendering.d.ts.map +1 -0
- package/dist/src/components/customise/{customRendering.js → CustomRendering.js} +4 -1
- package/dist/src/components/customise/{customRendering.js.map → CustomRendering.js.map} +1 -1
- package/dist/src/components/{CucumberReact.module.scss → customise/CustomRendering.stories.scss} +10 -20
- package/dist/src/components/customise/index.d.ts +1 -1
- package/dist/src/components/customise/index.js +1 -1
- package/dist/src/components/gherkin/Anchor.module.scss +2 -2
- package/dist/src/components/gherkin/Children.module.scss +1 -1
- package/dist/src/components/gherkin/DataTable.module.scss +2 -2
- package/dist/src/components/gherkin/Description.module.scss +2 -2
- package/dist/src/components/gherkin/DocString.module.scss +2 -3
- package/dist/src/components/gherkin/ErrorMessage.module.scss +3 -4
- package/dist/src/components/gherkin/ExampleDetail.module.scss +1 -1
- package/dist/src/components/gherkin/Examples.module.scss +1 -1
- package/dist/src/components/gherkin/ExamplesTable.module.scss +3 -3
- package/dist/src/components/gherkin/Keyword.module.scss +3 -3
- package/dist/src/components/gherkin/Parameter.module.scss +2 -2
- package/dist/src/components/gherkin/StatusIcon.module.scss +4 -11
- package/dist/src/components/gherkin/StepItem.module.scss +0 -1
- package/dist/src/components/gherkin/Tags.module.scss +2 -2
- package/dist/src/components/gherkin/Title.module.scss +2 -2
- package/dist/src/components/gherkin/attachment/Attachment.module.scss +5 -6
- package/dist/src/components/index.d.ts +3 -4
- package/dist/src/components/index.d.ts.map +1 -1
- package/dist/src/components/index.js +3 -4
- package/dist/src/components/index.js.map +1 -1
- package/dist/src/countScenariosByStatuses.d.ts +1 -5
- package/dist/src/countScenariosByStatuses.d.ts.map +1 -1
- package/dist/src/countScenariosByStatuses.js +14 -31
- package/dist/src/countScenariosByStatuses.js.map +1 -1
- package/dist/src/filter/filterByStatus.d.ts +1 -2
- package/dist/src/filter/filterByStatus.d.ts.map +1 -1
- package/dist/src/filter/filterByStatus.js +5 -2
- package/dist/src/filter/filterByStatus.js.map +1 -1
- package/dist/src/formatExecutionDistance.d.ts +2 -0
- package/dist/src/formatExecutionDistance.d.ts.map +1 -0
- package/dist/src/formatExecutionDistance.js +7 -0
- package/dist/src/formatExecutionDistance.js.map +1 -0
- package/dist/src/formatExecutionDuration.d.ts +2 -0
- package/dist/src/formatExecutionDuration.d.ts.map +1 -0
- package/dist/src/formatExecutionDuration.js +12 -0
- package/dist/src/formatExecutionDuration.js.map +1 -0
- package/dist/src/formatStatusRate.d.ts +2 -0
- package/dist/src/formatStatusRate.d.ts.map +1 -0
- package/dist/src/formatStatusRate.js +9 -0
- package/dist/src/formatStatusRate.js.map +1 -0
- package/dist/src/hooks/useFilteredDocuments.d.ts +2 -2
- package/dist/src/hooks/useFilteredDocuments.d.ts.map +1 -1
- package/dist/src/hooks/useFilteredDocuments.js +7 -5
- package/dist/src/hooks/useFilteredDocuments.js.map +1 -1
- package/dist/src/hooks/useQueries.d.ts +2 -6
- package/dist/src/hooks/useQueries.d.ts.map +1 -1
- package/dist/src/hooks/useQueries.js +1 -3
- package/dist/src/hooks/useQueries.js.map +1 -1
- package/dist/src/hooks/useResultStatistics.js +2 -2
- package/dist/src/hooks/useResultStatistics.js.map +1 -1
- package/dist/src/hooks/useSearch.d.ts +2 -2
- package/dist/src/hooks/useSearch.d.ts.map +1 -1
- package/dist/src/hooks/useSearch.js +1 -1
- package/dist/src/hooks/useSearch.js.map +1 -1
- package/dist/src/index.d.ts +3 -8
- package/dist/src/index.d.ts.map +1 -1
- package/dist/src/index.js +3 -8
- package/dist/src/index.js.map +1 -1
- package/dist/src/statuses.d.ts +4 -0
- package/dist/src/statuses.d.ts.map +1 -0
- package/dist/src/statuses.js +12 -0
- package/dist/src/statuses.js.map +1 -0
- package/dist/src/styles/statuses.scss +14 -0
- package/dist/src/styles/tables.scss +3 -3
- package/dist/src/styles/theming.scss +15 -18
- package/dist/tsconfig.build.tsbuildinfo +1 -1
- package/package.json +16 -18
- package/dist/src/EnvelopesQueryContext.d.ts +0 -15
- package/dist/src/EnvelopesQueryContext.d.ts.map +0 -1
- package/dist/src/EnvelopesQueryContext.js +0 -28
- package/dist/src/EnvelopesQueryContext.js.map +0 -1
- package/dist/src/SearchQueryContext.d.ts +0 -34
- package/dist/src/SearchQueryContext.d.ts.map +0 -1
- package/dist/src/SearchQueryContext.js +0 -73
- package/dist/src/SearchQueryContext.js.map +0 -1
- package/dist/src/components/CucumberReact.d.ts +0 -10
- package/dist/src/components/CucumberReact.d.ts.map +0 -1
- package/dist/src/components/CucumberReact.js +0 -9
- package/dist/src/components/CucumberReact.js.map +0 -1
- package/dist/src/components/app/EnvelopesWrapper.d.ts +0 -8
- package/dist/src/components/app/EnvelopesWrapper.d.ts.map +0 -1
- package/dist/src/components/app/EnvelopesWrapper.js +0 -20
- package/dist/src/components/app/EnvelopesWrapper.js.map +0 -1
- package/dist/src/components/app/FilteredResults.d.ts +0 -7
- package/dist/src/components/app/FilteredResults.d.ts.map +0 -1
- package/dist/src/components/app/FilteredResults.js +0 -23
- package/dist/src/components/app/FilteredResults.js.map +0 -1
- package/dist/src/components/app/FilteredResults.module.scss +0 -7
- package/dist/src/components/app/QueriesWrapper.d.ts +0 -12
- package/dist/src/components/app/QueriesWrapper.d.ts.map +0 -1
- package/dist/src/components/app/QueriesWrapper.js +0 -8
- package/dist/src/components/app/QueriesWrapper.js.map +0 -1
- package/dist/src/components/app/SearchWrapper.d.ts +0 -4
- package/dist/src/components/app/SearchWrapper.d.ts.map +0 -1
- package/dist/src/components/app/SearchWrapper.js +0 -6
- package/dist/src/components/app/SearchWrapper.js.map +0 -1
- package/dist/src/components/app/statuses.d.ts +0 -4
- package/dist/src/components/app/statuses.d.ts.map +0 -1
- package/dist/src/components/app/statuses.js +0 -12
- package/dist/src/components/app/statuses.js.map +0 -1
- package/dist/src/components/customise/custom-classes.stories.scss +0 -8
- package/dist/src/components/customise/customRendering.d.ts.map +0 -1
- package/dist/src/styles/fonts.scss +0 -18
|
@@ -1,16 +1,9 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
'SKIPPED' #00a0cc,
|
|
4
|
-
'PENDING' #ffad33,
|
|
5
|
-
'UNDEFINED' #ffad33,
|
|
6
|
-
'AMBIGUOUS' #f4ebfd,
|
|
7
|
-
'FAILED' #bb0000,
|
|
8
|
-
'UNKNOWN' #b6becb;
|
|
9
|
-
|
|
1
|
+
@use 'sass:color';
|
|
2
|
+
@use '../../styles/statuses';
|
|
10
3
|
.icon {
|
|
11
|
-
@each $name, $color in
|
|
4
|
+
@each $name, $color in statuses.$statusColors {
|
|
12
5
|
&[data-status='#{$name}'] {
|
|
13
|
-
color:
|
|
6
|
+
color: color.adjust($color, $alpha: -0.25);
|
|
14
7
|
}
|
|
15
8
|
}
|
|
16
9
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
@
|
|
1
|
+
@use '../../styles/theming';
|
|
2
2
|
|
|
3
3
|
.tags {
|
|
4
4
|
padding: 0;
|
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
display: inline;
|
|
10
10
|
list-style-type: none;
|
|
11
11
|
padding: 8px 0;
|
|
12
|
-
color:
|
|
12
|
+
color: theming.$tagColor;
|
|
13
13
|
|
|
14
14
|
&:not(:last-child) {
|
|
15
15
|
margin-right: 10px;
|
|
@@ -1,16 +1,15 @@
|
|
|
1
|
-
@
|
|
1
|
+
@use '../../../styles/theming';
|
|
2
2
|
|
|
3
3
|
.text {
|
|
4
4
|
position: relative;
|
|
5
5
|
white-space: pre-wrap;
|
|
6
|
-
font-family: $monoFamily;
|
|
7
6
|
font-size: 0.875em;
|
|
8
7
|
padding: 0.666em 0.75em;
|
|
9
8
|
border-radius: 0.25em;
|
|
10
9
|
margin: 0;
|
|
11
10
|
overflow-x: auto;
|
|
12
|
-
background-color:
|
|
13
|
-
color:
|
|
11
|
+
background-color: theming.$codeBackgroundColor;
|
|
12
|
+
color: theming.$codeTextColor;
|
|
14
13
|
}
|
|
15
14
|
|
|
16
15
|
.log {
|
|
@@ -23,7 +22,7 @@
|
|
|
23
22
|
left: 0.75em;
|
|
24
23
|
text-transform: uppercase;
|
|
25
24
|
font-weight: bold;
|
|
26
|
-
color:
|
|
25
|
+
color: theming.$parameterColor;
|
|
27
26
|
opacity: 0.75;
|
|
28
27
|
}
|
|
29
28
|
}
|
|
@@ -48,7 +47,7 @@
|
|
|
48
47
|
|
|
49
48
|
a {
|
|
50
49
|
text-decoration: none;
|
|
51
|
-
color:
|
|
50
|
+
color: theming.$anchorColor;
|
|
52
51
|
}
|
|
53
52
|
|
|
54
53
|
svg {
|
|
@@ -1,5 +1,4 @@
|
|
|
1
|
-
export *
|
|
2
|
-
export * from './
|
|
3
|
-
export *
|
|
4
|
-
export * as gherkin from './gherkin/index.js';
|
|
1
|
+
export * from './app/index.js';
|
|
2
|
+
export * from './customise/index.js';
|
|
3
|
+
export * from './gherkin/index.js';
|
|
5
4
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/index.ts"],"names":[],"mappings":"AAAA,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/index.ts"],"names":[],"mappings":"AAAA,cAAc,gBAAgB,CAAA;AAC9B,cAAc,sBAAsB,CAAA;AACpC,cAAc,oBAAoB,CAAA"}
|
|
@@ -1,5 +1,4 @@
|
|
|
1
|
-
export *
|
|
2
|
-
export * from './
|
|
3
|
-
export *
|
|
4
|
-
export * as gherkin from './gherkin/index.js';
|
|
1
|
+
export * from './app/index.js';
|
|
2
|
+
export * from './customise/index.js';
|
|
3
|
+
export * from './gherkin/index.js';
|
|
5
4
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/components/index.ts"],"names":[],"mappings":"AAAA,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/components/index.ts"],"names":[],"mappings":"AAAA,cAAc,gBAAgB,CAAA;AAC9B,cAAc,sBAAsB,CAAA;AACpC,cAAc,oBAAoB,CAAA"}
|
|
@@ -1,10 +1,6 @@
|
|
|
1
|
-
import { Query as GherkinQuery } from '@cucumber/gherkin-utils';
|
|
2
1
|
import { TestStepResultStatus } from '@cucumber/messages';
|
|
3
2
|
import { Query as CucumberQuery } from '@cucumber/query';
|
|
4
|
-
|
|
5
|
-
export declare const allStatuses: readonly [TestStepResultStatus.UNKNOWN, TestStepResultStatus.SKIPPED, TestStepResultStatus.FAILED, TestStepResultStatus.PASSED, TestStepResultStatus.AMBIGUOUS, TestStepResultStatus.PENDING, TestStepResultStatus.UNDEFINED];
|
|
6
|
-
export declare function makeEmptyScenarioCountsByStatus(): Record<TestStepResultStatus, number>;
|
|
7
|
-
export default function countScenariosByStatuses(gherkinQuery: GherkinQuery, cucumberQuery: CucumberQuery, envelopesQuery: EnvelopesQuery): {
|
|
3
|
+
export default function countScenariosByStatuses(cucumberQuery: CucumberQuery): {
|
|
8
4
|
scenarioCountByStatus: Record<TestStepResultStatus, number>;
|
|
9
5
|
statusesWithScenarios: readonly TestStepResultStatus[];
|
|
10
6
|
totalScenarioCount: number;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"countScenariosByStatuses.d.ts","sourceRoot":"","sources":["../../src/countScenariosByStatuses.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,
|
|
1
|
+
{"version":3,"file":"countScenariosByStatuses.d.ts","sourceRoot":"","sources":["../../src/countScenariosByStatuses.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,oBAAoB,EAAE,MAAM,oBAAoB,CAAA;AACzD,OAAO,EAAE,KAAK,IAAI,aAAa,EAAE,MAAM,iBAAiB,CAAA;AAIxD,MAAM,CAAC,OAAO,UAAU,wBAAwB,CAAC,aAAa,EAAE,aAAa,GAAG;IAC9E,qBAAqB,EAAE,MAAM,CAAC,oBAAoB,EAAE,MAAM,CAAC,CAAA;IAC3D,qBAAqB,EAAE,SAAS,oBAAoB,EAAE,CAAA;IACtD,kBAAkB,EAAE,MAAM,CAAA;CAC3B,CAgBA"}
|
|
@@ -1,39 +1,22 @@
|
|
|
1
|
-
import
|
|
2
|
-
export
|
|
3
|
-
|
|
4
|
-
TestStepResultStatus.SKIPPED,
|
|
5
|
-
TestStepResultStatus.FAILED,
|
|
6
|
-
TestStepResultStatus.PASSED,
|
|
7
|
-
TestStepResultStatus.AMBIGUOUS,
|
|
8
|
-
TestStepResultStatus.PENDING,
|
|
9
|
-
TestStepResultStatus.UNDEFINED,
|
|
10
|
-
];
|
|
11
|
-
export function makeEmptyScenarioCountsByStatus() {
|
|
12
|
-
return {
|
|
13
|
-
[TestStepResultStatus.UNKNOWN]: 0,
|
|
14
|
-
[TestStepResultStatus.SKIPPED]: 0,
|
|
15
|
-
[TestStepResultStatus.FAILED]: 0,
|
|
16
|
-
[TestStepResultStatus.PASSED]: 0,
|
|
17
|
-
[TestStepResultStatus.AMBIGUOUS]: 0,
|
|
18
|
-
[TestStepResultStatus.PENDING]: 0,
|
|
19
|
-
[TestStepResultStatus.UNDEFINED]: 0,
|
|
20
|
-
};
|
|
21
|
-
}
|
|
22
|
-
export default function countScenariosByStatuses(gherkinQuery, cucumberQuery, envelopesQuery) {
|
|
23
|
-
const scenarioCountByStatus = makeEmptyScenarioCountsByStatus();
|
|
24
|
-
gherkinQuery
|
|
25
|
-
.getPickles()
|
|
26
|
-
.filter((pickle) => envelopesQuery.hasTestCase(pickle.id))
|
|
27
|
-
.forEach((pickle) => {
|
|
28
|
-
const status = getWorstTestStepResult(cucumberQuery.getPickleTestStepResults([pickle.id])).status;
|
|
29
|
-
scenarioCountByStatus[status] = scenarioCountByStatus[status] + 1;
|
|
30
|
-
});
|
|
1
|
+
import statuses from './statuses.js';
|
|
2
|
+
export default function countScenariosByStatuses(cucumberQuery) {
|
|
3
|
+
const scenarioCountByStatus = cucumberQuery.countMostSevereTestStepResultStatus();
|
|
31
4
|
const statusesWithScenarios = Object.entries(scenarioCountByStatus)
|
|
32
5
|
.filter(([, value]) => {
|
|
33
6
|
return value > 0;
|
|
34
7
|
})
|
|
35
|
-
.map(([key]) => key)
|
|
8
|
+
.map(([key]) => key)
|
|
9
|
+
.sort(statusComparator);
|
|
36
10
|
const totalScenarioCount = [...Object.values(scenarioCountByStatus)].reduce((prev, curr) => prev + curr, 0);
|
|
37
11
|
return { scenarioCountByStatus, statusesWithScenarios, totalScenarioCount };
|
|
38
12
|
}
|
|
13
|
+
function statusComparator(a, b) {
|
|
14
|
+
if (statuses.indexOf(a) < statuses.indexOf(b)) {
|
|
15
|
+
return -1;
|
|
16
|
+
}
|
|
17
|
+
if (statuses.indexOf(a) > statuses.indexOf(b)) {
|
|
18
|
+
return 1;
|
|
19
|
+
}
|
|
20
|
+
return 0;
|
|
21
|
+
}
|
|
39
22
|
//# sourceMappingURL=countScenariosByStatuses.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"countScenariosByStatuses.js","sourceRoot":"","sources":["../../src/countScenariosByStatuses.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"countScenariosByStatuses.js","sourceRoot":"","sources":["../../src/countScenariosByStatuses.ts"],"names":[],"mappings":"AAGA,OAAO,QAAQ,MAAM,eAAe,CAAA;AAEpC,MAAM,CAAC,OAAO,UAAU,wBAAwB,CAAC,aAA4B;IAK3E,MAAM,qBAAqB,GAAG,aAAa,CAAC,mCAAmC,EAAE,CAAA;IAEjF,MAAM,qBAAqB,GAAG,MAAM,CAAC,OAAO,CAAC,qBAAqB,CAAC;SAChE,MAAM,CAAC,CAAC,CAAC,EAAE,KAAK,CAAC,EAAE,EAAE;QACpB,OAAO,KAAK,GAAG,CAAC,CAAA;IAClB,CAAC,CAAC;SACD,GAAG,CAAC,CAAC,CAAC,GAAG,CAAC,EAAE,EAAE,CAAC,GAAG,CAAC;SACnB,IAAI,CAAC,gBAAgB,CAA2B,CAAA;IAEnD,MAAM,kBAAkB,GAAG,CAAC,GAAG,MAAM,CAAC,MAAM,CAAC,qBAAqB,CAAC,CAAC,CAAC,MAAM,CACzE,CAAC,IAAI,EAAE,IAAI,EAAE,EAAE,CAAC,IAAI,GAAG,IAAI,EAC3B,CAAC,CACF,CAAA;IAED,OAAO,EAAE,qBAAqB,EAAE,qBAAqB,EAAE,kBAAkB,EAAE,CAAA;AAC7E,CAAC;AAED,SAAS,gBAAgB,CAAC,CAAuB,EAAE,CAAuB;IACxE,IAAI,QAAQ,CAAC,OAAO,CAAC,CAAC,CAAC,GAAG,QAAQ,CAAC,OAAO,CAAC,CAAC,CAAC,EAAE;QAC7C,OAAO,CAAC,CAAC,CAAA;KACV;IACD,IAAI,QAAQ,CAAC,OAAO,CAAC,CAAC,CAAC,GAAG,QAAQ,CAAC,OAAO,CAAC,CAAC,CAAC,EAAE;QAC7C,OAAO,CAAC,CAAA;KACT;IACD,OAAO,CAAC,CAAA;AACV,CAAC"}
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { Query as GherkinQuery } from '@cucumber/gherkin-utils';
|
|
2
2
|
import * as messages from '@cucumber/messages';
|
|
3
3
|
import { Query as CucumberQuery } from '@cucumber/query';
|
|
4
|
-
|
|
5
|
-
export default function filterByStatus(gherkinDocument: messages.GherkinDocument, gherkinQuery: GherkinQuery, cucumberQuery: CucumberQuery, envelopesQuery: EnvelopesQuery, statuses: readonly messages.TestStepResultStatus[]): messages.GherkinDocument | null;
|
|
4
|
+
export default function filterByStatus(gherkinDocument: messages.GherkinDocument, gherkinQuery: GherkinQuery, cucumberQuery: CucumberQuery, statuses: readonly messages.TestStepResultStatus[]): messages.GherkinDocument | null;
|
|
6
5
|
//# sourceMappingURL=filterByStatus.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"filterByStatus.d.ts","sourceRoot":"","sources":["../../../src/filter/filterByStatus.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,IAAI,YAAY,EAAE,MAAM,yBAAyB,CAAA;AAE/D,OAAO,KAAK,QAAQ,MAAM,oBAAoB,CAAA;AAE9C,OAAO,EAAE,KAAK,IAAI,aAAa,EAAE,MAAM,iBAAiB,CAAA;AAExD,
|
|
1
|
+
{"version":3,"file":"filterByStatus.d.ts","sourceRoot":"","sources":["../../../src/filter/filterByStatus.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,IAAI,YAAY,EAAE,MAAM,yBAAyB,CAAA;AAE/D,OAAO,KAAK,QAAQ,MAAM,oBAAoB,CAAA;AAE9C,OAAO,EAAE,KAAK,IAAI,aAAa,EAAE,MAAM,iBAAiB,CAAA;AAExD,MAAM,CAAC,OAAO,UAAU,cAAc,CACpC,eAAe,EAAE,QAAQ,CAAC,eAAe,EACzC,YAAY,EAAE,YAAY,EAC1B,aAAa,EAAE,aAAa,EAC5B,QAAQ,EAAE,SAAS,QAAQ,CAAC,oBAAoB,EAAE,GACjD,QAAQ,CAAC,eAAe,GAAG,IAAI,CA0BjC"}
|
|
@@ -1,13 +1,16 @@
|
|
|
1
1
|
import { GherkinDocumentWalker, rejectAllFilters } from '@cucumber/gherkin-utils';
|
|
2
2
|
import { getWorstTestStepResult } from '@cucumber/messages';
|
|
3
|
-
export default function filterByStatus(gherkinDocument, gherkinQuery, cucumberQuery,
|
|
3
|
+
export default function filterByStatus(gherkinDocument, gherkinQuery, cucumberQuery, statuses) {
|
|
4
4
|
const filters = {
|
|
5
5
|
acceptScenario: (scenario) => {
|
|
6
6
|
if (!gherkinDocument.uri)
|
|
7
7
|
throw new Error('Missing uri for gherkinDocument');
|
|
8
8
|
const pickleIds = gherkinQuery.getPickleIds(gherkinDocument.uri, scenario.id);
|
|
9
|
+
const picklesIdsWithTestCases = cucumberQuery
|
|
10
|
+
.findAllTestCaseStarted()
|
|
11
|
+
.map((tcs) => cucumberQuery.findTestCaseBy(tcs).pickleId);
|
|
9
12
|
return pickleIds
|
|
10
|
-
.filter((pickleId) =>
|
|
13
|
+
.filter((pickleId) => picklesIdsWithTestCases.includes(pickleId))
|
|
11
14
|
.some((pickleId) => statuses.includes(getWorstTestStepResult(cucumberQuery.getPickleTestStepResults([pickleId])).status));
|
|
12
15
|
},
|
|
13
16
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"filterByStatus.js","sourceRoot":"","sources":["../../../src/filter/filterByStatus.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,qBAAqB,EAAE,gBAAgB,EAAE,MAAM,yBAAyB,CAAA;AAEjF,OAAO,EAAE,sBAAsB,
|
|
1
|
+
{"version":3,"file":"filterByStatus.js","sourceRoot":"","sources":["../../../src/filter/filterByStatus.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,qBAAqB,EAAE,gBAAgB,EAAE,MAAM,yBAAyB,CAAA;AAEjF,OAAO,EAAE,sBAAsB,EAAY,MAAM,oBAAoB,CAAA;AAGrE,MAAM,CAAC,OAAO,UAAU,cAAc,CACpC,eAAyC,EACzC,YAA0B,EAC1B,aAA4B,EAC5B,QAAkD;IAElD,MAAM,OAAO,GAAG;QACd,cAAc,EAAE,CAAC,QAA2B,EAAE,EAAE;YAC9C,IAAI,CAAC,eAAe,CAAC,GAAG;gBAAE,MAAM,IAAI,KAAK,CAAC,iCAAiC,CAAC,CAAA;YAC5E,MAAM,SAAS,GAAG,YAAY,CAAC,YAAY,CAAC,eAAe,CAAC,GAAG,EAAE,QAAQ,CAAC,EAAE,CAAC,CAAA;YAE7E,MAAM,uBAAuB,GAAG,aAAa;iBAC1C,sBAAsB,EAAE;iBACxB,GAAG,CAAC,CAAC,GAAG,EAAE,EAAE,CAAE,aAAa,CAAC,cAAc,CAAC,GAAG,CAAc,CAAC,QAAQ,CAAC,CAAA;YAEzE,OAAO,SAAS;iBACb,MAAM,CAAC,CAAC,QAAQ,EAAE,EAAE,CAAC,uBAAuB,CAAC,QAAQ,CAAC,QAAQ,CAAC,CAAC;iBAChE,IAAI,CAAC,CAAC,QAAQ,EAAE,EAAE,CACjB,QAAQ,CAAC,QAAQ,CACf,sBAAsB,CAAC,aAAa,CAAC,wBAAwB,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC,CAAC,MAAM,CAClF,CACF,CAAA;QACL,CAAC;KACF,CAAA;IAED,MAAM,MAAM,GAAG,IAAI,qBAAqB,CAAC;QACvC,GAAG,gBAAgB;QACnB,GAAG,OAAO;KACX,CAAC,CAAA;IAEF,OAAO,MAAM,CAAC,mBAAmB,CAAC,eAAe,CAAC,CAAA;AACpD,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"formatExecutionDistance.d.ts","sourceRoot":"","sources":["../../src/formatExecutionDistance.ts"],"names":[],"mappings":"AAEA,wBAAgB,uBAAuB,CAAC,IAAI,EAAE,IAAI,EAAE,aAAa,GAAE,IAAiB,UAInF"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"formatExecutionDistance.js","sourceRoot":"","sources":["../../src/formatExecutionDistance.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,oBAAoB,EAAE,MAAM,UAAU,CAAA;AAE/C,MAAM,UAAU,uBAAuB,CAAC,IAAU,EAAE,gBAAsB,IAAI,IAAI,EAAE;IAClF,OAAO,oBAAoB,CAAC,IAAI,EAAE,aAAa,EAAE;QAC/C,SAAS,EAAE,IAAI;KAChB,CAAC,CAAA;AACJ,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"formatExecutionDuration.d.ts","sourceRoot":"","sources":["../../src/formatExecutionDuration.ts"],"names":[],"mappings":"AAEA,wBAAgB,uBAAuB,CAAC,SAAS,EAAE,IAAI,EAAE,UAAU,EAAE,IAAI,UASxE"}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { formatDuration, intervalToDuration } from 'date-fns';
|
|
2
|
+
export function formatExecutionDuration(startDate, finishDate) {
|
|
3
|
+
const inMilllis = finishDate.getTime() - startDate.getTime();
|
|
4
|
+
// if under 10s, use 0.01s precision, otherwise 1s is fine
|
|
5
|
+
if (inMilllis < 10000) {
|
|
6
|
+
return `${new Intl.NumberFormat(undefined, {
|
|
7
|
+
maximumFractionDigits: 2,
|
|
8
|
+
}).format(inMilllis / 1000)} seconds`;
|
|
9
|
+
}
|
|
10
|
+
return formatDuration(intervalToDuration({ start: startDate, end: finishDate }), {});
|
|
11
|
+
}
|
|
12
|
+
//# sourceMappingURL=formatExecutionDuration.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"formatExecutionDuration.js","sourceRoot":"","sources":["../../src/formatExecutionDuration.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,kBAAkB,EAAE,MAAM,UAAU,CAAA;AAE7D,MAAM,UAAU,uBAAuB,CAAC,SAAe,EAAE,UAAgB;IACvE,MAAM,SAAS,GAAG,UAAU,CAAC,OAAO,EAAE,GAAG,SAAS,CAAC,OAAO,EAAE,CAAA;IAC5D,0DAA0D;IAC1D,IAAI,SAAS,GAAG,KAAK,EAAE;QACrB,OAAO,GAAG,IAAI,IAAI,CAAC,YAAY,CAAC,SAAS,EAAE;YACzC,qBAAqB,EAAE,CAAC;SACzB,CAAC,CAAC,MAAM,CAAC,SAAS,GAAG,IAAI,CAAC,UAAU,CAAA;KACtC;IACD,OAAO,cAAc,CAAC,kBAAkB,CAAC,EAAE,KAAK,EAAE,SAAS,EAAE,GAAG,EAAE,UAAU,EAAE,CAAC,EAAE,EAAE,CAAC,CAAA;AACtF,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"formatStatusRate.d.ts","sourceRoot":"","sources":["../../src/formatStatusRate.ts"],"names":[],"mappings":"AAAA,wBAAgB,gBAAgB,CAAC,MAAM,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,UAQ7D"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
export function formatStatusRate(passed, total) {
|
|
2
|
+
const percentPassed = total > 0 ? passed / total : 0;
|
|
3
|
+
const roundedDown = Math.floor(percentPassed * 1000) / 1000;
|
|
4
|
+
return new Intl.NumberFormat(undefined, {
|
|
5
|
+
style: 'percent',
|
|
6
|
+
maximumFractionDigits: 1,
|
|
7
|
+
}).format(roundedDown);
|
|
8
|
+
}
|
|
9
|
+
//# sourceMappingURL=formatStatusRate.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"formatStatusRate.js","sourceRoot":"","sources":["../../src/formatStatusRate.ts"],"names":[],"mappings":"AAAA,MAAM,UAAU,gBAAgB,CAAC,MAAc,EAAE,KAAa;IAC5D,MAAM,aAAa,GAAG,KAAK,GAAG,CAAC,CAAC,CAAC,CAAC,MAAM,GAAG,KAAK,CAAC,CAAC,CAAC,CAAC,CAAA;IACpD,MAAM,WAAW,GAAG,IAAI,CAAC,KAAK,CAAC,aAAa,GAAG,IAAI,CAAC,GAAG,IAAI,CAAA;IAE3D,OAAO,IAAI,IAAI,CAAC,YAAY,CAAC,SAAS,EAAE;QACtC,KAAK,EAAE,SAAS;QAChB,qBAAqB,EAAE,CAAC;KACzB,CAAC,CAAC,MAAM,CAAC,WAAW,CAAC,CAAA;AACxB,CAAC"}
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { GherkinDocument
|
|
2
|
-
export declare function useFilteredDocuments(
|
|
1
|
+
import { GherkinDocument } from '@cucumber/messages';
|
|
2
|
+
export declare function useFilteredDocuments(): GherkinDocument[] | undefined;
|
|
3
3
|
//# sourceMappingURL=useFilteredDocuments.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useFilteredDocuments.d.ts","sourceRoot":"","sources":["../../../src/hooks/useFilteredDocuments.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAE,
|
|
1
|
+
{"version":3,"file":"useFilteredDocuments.d.ts","sourceRoot":"","sources":["../../../src/hooks/useFilteredDocuments.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAE,MAAM,oBAAoB,CAAA;AASpD,wBAAgB,oBAAoB,IAAI,eAAe,EAAE,GAAG,SAAS,CA6BpE"}
|
|
@@ -1,10 +1,12 @@
|
|
|
1
1
|
import { useEffect, useState } from 'react';
|
|
2
|
-
import { allStatuses } from '../countScenariosByStatuses.js';
|
|
3
2
|
import filterByStatus from '../filter/filterByStatus.js';
|
|
4
3
|
import { createSearch } from '../search/index.js';
|
|
4
|
+
import statuses from '../statuses.js';
|
|
5
5
|
import { useQueries } from './useQueries.js';
|
|
6
|
-
|
|
7
|
-
|
|
6
|
+
import { useSearch } from './useSearch.js';
|
|
7
|
+
export function useFilteredDocuments() {
|
|
8
|
+
const { query, hideStatuses } = useSearch();
|
|
9
|
+
const { gherkinQuery, cucumberQuery } = useQueries();
|
|
8
10
|
const [searchable, setSearchable] = useState();
|
|
9
11
|
const [results, setResults] = useState();
|
|
10
12
|
useEffect(() => {
|
|
@@ -17,11 +19,11 @@ export function useFilteredDocuments(query, hideStatuses) {
|
|
|
17
19
|
;
|
|
18
20
|
(query ? searchable.search(query) : Promise.resolve(gherkinQuery.getGherkinDocuments())).then((searched) => {
|
|
19
21
|
const filtered = searched
|
|
20
|
-
.map((document) => filterByStatus(document, gherkinQuery, cucumberQuery,
|
|
22
|
+
.map((document) => filterByStatus(document, gherkinQuery, cucumberQuery, statuses.filter((s) => !hideStatuses.includes(s))))
|
|
21
23
|
.filter((document) => document !== null);
|
|
22
24
|
setResults(filtered);
|
|
23
25
|
});
|
|
24
|
-
}, [query, hideStatuses, gherkinQuery, cucumberQuery,
|
|
26
|
+
}, [query, hideStatuses, gherkinQuery, cucumberQuery, searchable]);
|
|
25
27
|
return results;
|
|
26
28
|
}
|
|
27
29
|
//# sourceMappingURL=useFilteredDocuments.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useFilteredDocuments.js","sourceRoot":"","sources":["../../../src/hooks/useFilteredDocuments.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,SAAS,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAA;AAE3C,OAAO,
|
|
1
|
+
{"version":3,"file":"useFilteredDocuments.js","sourceRoot":"","sources":["../../../src/hooks/useFilteredDocuments.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,SAAS,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAA;AAE3C,OAAO,cAAc,MAAM,6BAA6B,CAAA;AACxD,OAAO,EAAE,YAAY,EAAc,MAAM,oBAAoB,CAAA;AAC7D,OAAO,QAAQ,MAAM,gBAAgB,CAAA;AACrC,OAAO,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAA;AAC5C,OAAO,EAAE,SAAS,EAAE,MAAM,gBAAgB,CAAA;AAE1C,MAAM,UAAU,oBAAoB;IAClC,MAAM,EAAE,KAAK,EAAE,YAAY,EAAE,GAAG,SAAS,EAAE,CAAA;IAC3C,MAAM,EAAE,YAAY,EAAE,aAAa,EAAE,GAAG,UAAU,EAAE,CAAA;IACpD,MAAM,CAAC,UAAU,EAAE,aAAa,CAAC,GAAG,QAAQ,EAAc,CAAA;IAC1D,MAAM,CAAC,OAAO,EAAE,UAAU,CAAC,GAAG,QAAQ,EAAqB,CAAA;IAC3D,SAAS,CAAC,GAAG,EAAE;QACb,YAAY,CAAC,YAAY,CAAC,CAAC,IAAI,CAAC,CAAC,OAAO,EAAE,EAAE,CAAC,aAAa,CAAC,OAAO,CAAC,CAAC,CAAA;IACtE,CAAC,EAAE,CAAC,YAAY,CAAC,CAAC,CAAA;IAClB,SAAS,CAAC,GAAG,EAAE;QACb,IAAI,CAAC,UAAU,EAAE;YACf,OAAM;SACP;QACD,CAAC;QAAA,CAAC,KAAK,CAAC,CAAC,CAAC,UAAU,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,OAAO,CAAC,OAAO,CAAC,YAAY,CAAC,mBAAmB,EAAE,CAAC,CAAC,CAAC,IAAI,CAC5F,CAAC,QAAQ,EAAE,EAAE;YACX,MAAM,QAAQ,GAAG,QAAQ;iBACtB,GAAG,CAAC,CAAC,QAAQ,EAAE,EAAE,CAChB,cAAc,CACZ,QAAQ,EACR,YAAY,EACZ,aAAa,EACb,QAAQ,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,YAAY,CAAC,QAAQ,CAAC,CAAC,CAAC,CAAC,CAClD,CACF;iBACA,MAAM,CAAC,CAAC,QAAQ,EAAE,EAAE,CAAC,QAAQ,KAAK,IAAI,CAAsB,CAAA;YAC/D,UAAU,CAAC,QAAQ,CAAC,CAAA;QACtB,CAAC,CACF,CAAA;IACH,CAAC,EAAE,CAAC,KAAK,EAAE,YAAY,EAAE,YAAY,EAAE,aAAa,EAAE,UAAU,CAAC,CAAC,CAAA;IAClE,OAAO,OAAO,CAAA;AAChB,CAAC"}
|
|
@@ -1,11 +1,7 @@
|
|
|
1
1
|
import { Query as GherkinQuery } from '@cucumber/gherkin-utils';
|
|
2
2
|
import { Query as CucumberQuery } from '@cucumber/query';
|
|
3
|
-
|
|
4
|
-
interface IQueries {
|
|
3
|
+
export declare function useQueries(): {
|
|
5
4
|
cucumberQuery: CucumberQuery;
|
|
6
5
|
gherkinQuery: GherkinQuery;
|
|
7
|
-
|
|
8
|
-
}
|
|
9
|
-
export declare function useQueries(): IQueries;
|
|
10
|
-
export {};
|
|
6
|
+
};
|
|
11
7
|
//# sourceMappingURL=useQueries.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useQueries.d.ts","sourceRoot":"","sources":["../../../src/hooks/useQueries.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,IAAI,YAAY,EAAE,MAAM,yBAAyB,CAAA;AAC/D,OAAO,EAAE,KAAK,IAAI,aAAa,EAAE,MAAM,iBAAiB,CAAA;
|
|
1
|
+
{"version":3,"file":"useQueries.d.ts","sourceRoot":"","sources":["../../../src/hooks/useQueries.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,IAAI,YAAY,EAAE,MAAM,yBAAyB,CAAA;AAC/D,OAAO,EAAE,KAAK,IAAI,aAAa,EAAE,MAAM,iBAAiB,CAAA;AAMxD,wBAAgB,UAAU,IAAI;IAC5B,aAAa,EAAE,aAAa,CAAA;IAC5B,YAAY,EAAE,YAAY,CAAA;CAC3B,CAIA"}
|
|
@@ -1,11 +1,9 @@
|
|
|
1
1
|
import { useContext } from 'react';
|
|
2
2
|
import CucumberQueryContext from '../CucumberQueryContext.js';
|
|
3
|
-
import EnvelopesQueryContext from '../EnvelopesQueryContext.js';
|
|
4
3
|
import GherkinQueryContext from '../GherkinQueryContext.js';
|
|
5
4
|
export function useQueries() {
|
|
6
|
-
const envelopesQuery = useContext(EnvelopesQueryContext);
|
|
7
5
|
const gherkinQuery = useContext(GherkinQueryContext);
|
|
8
6
|
const cucumberQuery = useContext(CucumberQueryContext);
|
|
9
|
-
return { cucumberQuery, gherkinQuery
|
|
7
|
+
return { cucumberQuery, gherkinQuery };
|
|
10
8
|
}
|
|
11
9
|
//# sourceMappingURL=useQueries.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useQueries.js","sourceRoot":"","sources":["../../../src/hooks/useQueries.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,UAAU,EAAE,MAAM,OAAO,CAAA;AAElC,OAAO,oBAAoB,MAAM,4BAA4B,CAAA;AAC7D,OAAO,
|
|
1
|
+
{"version":3,"file":"useQueries.js","sourceRoot":"","sources":["../../../src/hooks/useQueries.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,UAAU,EAAE,MAAM,OAAO,CAAA;AAElC,OAAO,oBAAoB,MAAM,4BAA4B,CAAA;AAC7D,OAAO,mBAAmB,MAAM,2BAA2B,CAAA;AAE3D,MAAM,UAAU,UAAU;IAIxB,MAAM,YAAY,GAAG,UAAU,CAAC,mBAAmB,CAAC,CAAA;IACpD,MAAM,aAAa,GAAG,UAAU,CAAC,oBAAoB,CAAC,CAAA;IACtD,OAAO,EAAE,aAAa,EAAE,YAAY,EAAE,CAAA;AACxC,CAAC"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import countScenariosByStatuses from '../countScenariosByStatuses.js';
|
|
2
2
|
import { useQueries } from './useQueries.js';
|
|
3
3
|
export function useResultStatistics() {
|
|
4
|
-
const {
|
|
5
|
-
return countScenariosByStatuses(
|
|
4
|
+
const { cucumberQuery } = useQueries();
|
|
5
|
+
return countScenariosByStatuses(cucumberQuery);
|
|
6
6
|
}
|
|
7
7
|
//# sourceMappingURL=useResultStatistics.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useResultStatistics.js","sourceRoot":"","sources":["../../../src/hooks/useResultStatistics.ts"],"names":[],"mappings":"AAAA,OAAO,wBAAwB,MAAM,gCAAgC,CAAA;AACrE,OAAO,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAA;AAE5C,MAAM,UAAU,mBAAmB;IACjC,MAAM,EAAE,
|
|
1
|
+
{"version":3,"file":"useResultStatistics.js","sourceRoot":"","sources":["../../../src/hooks/useResultStatistics.ts"],"names":[],"mappings":"AAAA,OAAO,wBAAwB,MAAM,gCAAgC,CAAA;AACrE,OAAO,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAA;AAE5C,MAAM,UAAU,mBAAmB;IACjC,MAAM,EAAE,aAAa,EAAE,GAAG,UAAU,EAAE,CAAA;IACtC,OAAO,wBAAwB,CAAC,aAAa,CAAC,CAAA;AAChD,CAAC"}
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export declare function useSearch():
|
|
1
|
+
import { SearchContextValue } from '../SearchContext.js';
|
|
2
|
+
export declare function useSearch(): SearchContextValue;
|
|
3
3
|
//# sourceMappingURL=useSearch.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useSearch.d.ts","sourceRoot":"","sources":["../../../src/hooks/useSearch.ts"],"names":[],"mappings":"AAEA,OAA2B,EAAE,
|
|
1
|
+
{"version":3,"file":"useSearch.d.ts","sourceRoot":"","sources":["../../../src/hooks/useSearch.ts"],"names":[],"mappings":"AAEA,OAA2B,EAAE,kBAAkB,EAAE,MAAM,qBAAqB,CAAA;AAE5E,wBAAgB,SAAS,IAAI,kBAAkB,CAE9C"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useSearch.js","sourceRoot":"","sources":["../../../src/hooks/useSearch.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,OAAO,CAAA;AAElC,OAAO,
|
|
1
|
+
{"version":3,"file":"useSearch.js","sourceRoot":"","sources":["../../../src/hooks/useSearch.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,OAAO,CAAA;AAElC,OAAO,kBAA0C,MAAM,qBAAqB,CAAA;AAE5E,MAAM,UAAU,SAAS;IACvB,OAAO,UAAU,CAAC,kBAAkB,CAAC,CAAA;AACvC,CAAC"}
|
package/dist/src/index.d.ts
CHANGED
|
@@ -1,9 +1,4 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
import GherkinQueryContext from './GherkinQueryContext.js';
|
|
5
|
-
import SearchQueryContext, { searchFromURLParams, SearchQueryProps, SearchQueryUpdateFn, WindowUrlApi } from './SearchQueryContext.js';
|
|
6
|
-
export * as components from './components/index.js';
|
|
7
|
-
export * as hooks from './hooks/index.js';
|
|
8
|
-
export { CucumberQueryContext, EnvelopesQuery, EnvelopesQueryContext, filterByStatus, GherkinQueryContext, searchFromURLParams, SearchQueryContext, SearchQueryProps, SearchQueryUpdateFn, WindowUrlApi, };
|
|
1
|
+
export * from './components/index.js';
|
|
2
|
+
export * as filterByStatus from './filter/filterByStatus.js';
|
|
3
|
+
export * from './hooks/index.js';
|
|
9
4
|
//# sourceMappingURL=index.d.ts.map
|
package/dist/src/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,uBAAuB,CAAA;AACrC,OAAO,KAAK,cAAc,MAAM,4BAA4B,CAAA;AAC5D,cAAc,kBAAkB,CAAA"}
|
package/dist/src/index.js
CHANGED
|
@@ -1,9 +1,4 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
import GherkinQueryContext from './GherkinQueryContext.js';
|
|
5
|
-
import SearchQueryContext, { searchFromURLParams, } from './SearchQueryContext.js';
|
|
6
|
-
export * as components from './components/index.js';
|
|
7
|
-
export * as hooks from './hooks/index.js';
|
|
8
|
-
export { CucumberQueryContext, EnvelopesQuery, EnvelopesQueryContext, filterByStatus, GherkinQueryContext, searchFromURLParams, SearchQueryContext, };
|
|
1
|
+
export * from './components/index.js';
|
|
2
|
+
export * as filterByStatus from './filter/filterByStatus.js';
|
|
3
|
+
export * from './hooks/index.js';
|
|
9
4
|
//# sourceMappingURL=index.js.map
|
package/dist/src/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,uBAAuB,CAAA;AACrC,OAAO,KAAK,cAAc,MAAM,4BAA4B,CAAA;AAC5D,cAAc,kBAAkB,CAAA"}
|
|
@@ -0,0 +1 @@
|
|
|
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"}
|
|
@@ -0,0 +1,12 @@
|
|
|
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
|
|
@@ -0,0 +1 @@
|
|
|
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"}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
$statusColors:
|
|
2
|
+
'PASSED' oklch(72.3% 0.219 149.579),
|
|
3
|
+
// green-500
|
|
4
|
+
'SKIPPED' oklch(62.3% 0.214 259.815),
|
|
5
|
+
// blue-500
|
|
6
|
+
'PENDING' oklch(79.5% 0.184 86.047),
|
|
7
|
+
// yellow-500
|
|
8
|
+
'UNDEFINED' oklch(79.5% 0.184 86.047),
|
|
9
|
+
// yellow-500
|
|
10
|
+
'AMBIGUOUS' oklch(55.4% 0.046 257.417),
|
|
11
|
+
// slate-500
|
|
12
|
+
'FAILED' oklch(63.7% 0.237 25.331),
|
|
13
|
+
// red-500
|
|
14
|
+
'UNKNOWN' oklch(55.4% 0.046 257.417); // slate-500;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
@
|
|
1
|
+
@use 'theming';
|
|
2
2
|
|
|
3
3
|
@mixin cucumber-table-style {
|
|
4
4
|
border-collapse: collapse;
|
|
@@ -19,7 +19,7 @@
|
|
|
19
19
|
border-style: solid;
|
|
20
20
|
border-top: none;
|
|
21
21
|
border-bottom: none;
|
|
22
|
-
border-color:
|
|
23
|
-
color:
|
|
22
|
+
border-color: theming.$keywordColor;
|
|
23
|
+
color: theming.$parameterColor;
|
|
24
24
|
}
|
|
25
25
|
}
|