Skip to content
This repository was archived by the owner on Jan 12, 2026. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion workspaces/ui/.env
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
REACT_APP_TESTING_DASHBOARD=false
REACT_APP_TESTING_DASHBOARD_TEASER=false
REACT_APP_TESTING_DASHBOARD_TEASER=false
REACT_APP_TESTING_DASHBOARD_ENDPOINT_DETAILS=false
3 changes: 2 additions & 1 deletion workspaces/ui/.env.development
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
REACT_APP_TESTING_DASHBOARD=true
REACT_APP_TESTING_DASHBOARD_TEASER=false
REACT_APP_TESTING_DASHBOARD_TEASER=false
REACT_APP_TESTING_DASHBOARD_ENDPOINT_DETAILS=true
13 changes: 8 additions & 5 deletions workspaces/ui/src/components/dashboards/TestingDashboard.js
Original file line number Diff line number Diff line change
Expand Up @@ -80,11 +80,14 @@ export default function TestingDashboardPage(props) {
{hasCaptures ? (
<div className={classes.reportContainer}>
<Switch>
<Route
strict
path={routerPaths.testingEndpointDetails}
component={TestingDashboard}
/>
{process.env.REACT_APP_TESTING_DASHBOARD_ENDPOINT_DETAILS ===
'true' && (
<Route
strict
path={routerPaths.testingEndpointDetails}
component={TestingDashboard}
/>
)}
<Route
strict
path={routerPaths.testingCapture}
Expand Down
147 changes: 78 additions & 69 deletions workspaces/ui/src/components/testing/ReportSummary.js
Original file line number Diff line number Diff line change
Expand Up @@ -115,83 +115,92 @@ export default function ReportSummary(props) {

{endpoints.length > 0 ? (
<ul className={classes.endpointsList} onClick={onClickList}>
{endpoints.map((endpoint) => (
<li
key={endpoint.id}
className={classNames(classes.endpointsListItem, {
[classes.isCurrent]:
currentEndpointId && endpoint.id === currentEndpointId,
})}
>
<Card className={classes.endpointCard}>
<ReportEndpointLink
replace
className={classes.endpointLink}
captureId={captureId}
endpointId={endpoint.id}
{endpoints.map((endpoint) => {
const endpointHeader = (
<div className={classes.endpointHeader}>
<span
className={classNames(
classes.endpointMethod,
classesHttpMethods[endpoint.descriptor.httpMethod]
)}
>
<div className={classes.endpointHeader}>
{endpoint.descriptor.httpMethod}
</span>
<code className={classes.endpointPath}>
{endpoint.descriptor.fullPath}
</code>

<div className={classes.endpointStats}>
{endpoint.counts.diffs > 0 && (
<span
className={classNames(
classes.endpointMethod,
classesHttpMethods[endpoint.descriptor.httpMethod]
classes.endpointChip,
classes.endpointDiffsChip
)}
>
{endpoint.descriptor.httpMethod}
<strong>{endpoint.counts.diffs}</strong>
{endpoint.counts.diffs > 1 ? ' diffs' : ' diff'}
</span>
<code className={classes.endpointPath}>
{endpoint.descriptor.fullPath}
</code>

<div className={classes.endpointStats}>
{endpoint.counts.diffs > 0 && (
<span
className={classNames(
classes.endpointChip,
classes.endpointDiffsChip
)}
>
<strong>{endpoint.counts.diffs}</strong>
{endpoint.counts.diffs > 1 ? ' diffs' : ' diff'}
</span>
)}
{endpoint.counts.incompliant > 0 ? (
<span
className={classNames(
classes.endpointChip,
classes.endpointIncompliantChip
)}
{endpoint.counts.incompliant > 0 ? (
<span
className={classNames(
classes.endpointChip,
classes.endpointIncompliantChip
)}
>
<strong>
{endpoint.counts.incompliant}/
{endpoint.counts.interactions}
</strong>
{' incompliant'}
</span>
) : (
<span
className={classNames(
classes.endpointChip,
classes.endpointCompliantChip
)}
>
<strong>
{endpoint.counts.compliant}/
{endpoint.counts.interactions}
</strong>
{' compliant'}
</span>
>
<strong>
{endpoint.counts.incompliant}/
{endpoint.counts.interactions}
</strong>
{' incompliant'}
</span>
) : (
<span
className={classNames(
classes.endpointChip,
classes.endpointCompliantChip
)}
</div>
</div>
</ReportEndpointLink>

{currentEndpointId && endpoint.id === currentEndpointId && (
<EndpointReport endpoint={endpoint} captureId={captureId} />
)}
</Card>
</li>
))}
>
<strong>
{endpoint.counts.compliant}/
{endpoint.counts.interactions}
</strong>
{' compliant'}
</span>
)}
</div>
</div>
);
return (
<li
key={endpoint.id}
className={classNames(classes.endpointsListItem, {
[classes.isCurrent]:
currentEndpointId && endpoint.id === currentEndpointId,
})}
>
<Card className={classes.endpointCard}>
{process.env.REACT_APP_TESTING_DASHBOARD_ENDPOINT_DETAILS ===
'true' ? (
<ReportEndpointLink
replace
className={classes.endpointLink}
captureId={captureId}
endpointId={endpoint.id}
>
{endpointHeader}
</ReportEndpointLink>
) : (
<div className={classes.endpointLink}>{endpointHeader}</div>
)}
{currentEndpointId && endpoint.id === currentEndpointId && (
<EndpointReport endpoint={endpoint} captureId={captureId} />
)}
</Card>
</li>
);
})}
</ul>
) : (
// @TODO: revisit this empty state
Expand Down