Skip to content

Available Widgets

This section describes the available widgets and their parameters.

Summary Widget (summary)

The Summary Widget displays a summary of the test results, including the total number of tests and the number of tests in each status (passed, failed, skipped, error).

summary-widget

Parameters (SummaryWidgetParameters)

FieldTypeDescription
titlestring(Optional) The title of the widget. Defaults to "Analysis Summary".

Container Widget (container)

The Container Widget is used to group other widgets together. This is useful for organizing the layout of a page.

Children

The container widget has a children field, which is an array of Widget objects. These are the widgets that will be rendered inside the container.

Tree Widget (tree)

The Tree Widget displays test results in a hierarchical tree structure. It allows for filtering and sorting of the tests.

tree-widget

Parameters (TreeWidgetParameters)

FieldTypeDescription
titlestring(Optional) The title of the widget.
strategystringThe organization strategy for the tree. Possible values are 'folder' (default) and 'status'.
sortStrategiesstring[]An array of sorting strategies to apply to the tree. Currently, the only possible value is 'name' (default).

Test Distribution Pie (distribution-pie)

The Test Distribution Pie widget displays a pie chart showing the distribution of test results.

distribution-pie-widget

Parameters (TestDistributionPieParameters)

FieldTypeDescription
titleobject(Optional) The title of the widget.
subtitleobject(Optional) The subtitle of the widget.
strategystringThe distribution strategy for the pie chart. Possible values are 'status' (default) and 'duration'.
strategyParametersobject(Optional) Parameters for the selected strategy.
legendobject(Optional) Parameters for the chart's legend.
datasetobject(Optional) Parameters for the chart's dataset.
optionsobject(Optional) General options for the chart.
widthstring(Optional) The width of the chart.
heightstring(Optional) The height of the chart.

The strategyParameters object depends on the selected strategy.

duration Strategy Parameters

When strategy is set to 'duration', the strategyParameters object can contain the following fields:

FieldTypeDescription
intervals[DurationInterval](#durationinterval)[]An array of DurationInterval objects that define the duration ranges for the pie chart.
DurationInterval
FieldTypeDescription
labelstring(Optional) The label for the duration interval. If not provided, a label will be generated automatically based on the duration range.
colorstringThe color for the duration interval. This can be any valid CSS color string.
minnumber(Optional) The minimum duration (in milliseconds) for this interval.
maxnumber(Optional) The maximum duration (in milliseconds) for this interval.

title and subtitle Parameters

The title and subtitle objects can contain the following fields:

See the Chart.js title documentation for more details.

FieldTypeDescription
displayboolean(Optional) If true, the title is shown. Defaults to false.
positiontop left bottom right(Optional) The position of the title. Defaults to top.
alignstart center end(Optional) The alignment of the title. Defaults to center.
textstring string[]The text to display.
colorstring(Optional) The color of the text.
fontobject(Optional) An object that configures the font of the text.
paddingnumber object(Optional) The padding to apply around the title.
fullSizeboolean(Optional) If true, the title will take the full width of the canvas.

legend Parameters

The legend object can contain the following fields:

See the Chart.js legend documentation for more details.

FieldTypeDescription
displayboolean(Optional) If true, the legend is shown. Defaults to true.
positiontop left bottom right(Optional) The position of the legend. Defaults to top.
alignstart center end(Optional) The alignment of the legend. Defaults to center.
maxHeightnumber(Optional) The maximum height of the legend in pixels.
maxWidthnumber(Optional) The maximum width of the legend in pixels.
fullSizeboolean(Optional) If true, the legend will take the full width/height of the canvas. Defaults to true.
reverseboolean(Optional) If true, the legend items are displayed in reverse order. Defaults to false.
rtlboolean(Optional) If true, the legend is in right-to-left mode. Defaults to false.
textDirectionltr rtl(Optional) The text direction of the legend. Defaults to the canvas's style.
labelsobject(Optional) An object that configures the legend labels.
labels Parameters

The labels object can contain the following fields:

FieldTypeDescription
boxWidthnumber(Optional) The width of the colored box in the legend.
boxHeightnumber(Optional) The height of the colored box in the legend.
colorstring(Optional) The color of the label text.
fontobject(Optional) An object that configures the font of the label text.
paddingnumber(Optional) The padding between the legend items.
pointStylestring(Optional) The style of the point in the legend.
textAlignstring(Optional) The alignment of the text in the legend.
useBorderRadiusboolean(Optional) If true, the borderRadius property is used to style the legend box.
borderRadiusnumber(Optional) The border radius of the legend box.

dataset Parameters

The dataset object allows for the customization of the pie chart's dataset.

See the Chart.js dataset documentation for more details.

FieldTypeDescription
borderAligncenter inner(Optional) The alignment of the border.
borderColorstring string[](Optional) The color of the border.
borderWidthnumber object(Optional) The width of the border in pixels.
hoverBorderColorstring string[](Optional) The color of the border when hovered.
hoverBorderWidthnumber object(Optional) The width of the border when hovered.
hoverOffsetnumber(Optional) The pixel value to offset the segment when hovered.
offsetnumber(Optional) The pixel value to offset the segment.
weightnumber(Optional) The relative thickness of the dataset.

options Parameters

The options object allows for the customization of the pie chart's general options.

See the Chart.js options documentation for more details.

FieldTypeDescription
cutoutnumber(Optional) The percentage of the chart that is cut out of the middle.
radiusnumber(Optional) The outer radius of the chart.
rotationnumber(Optional) The starting angle to draw arcs from.
circumferencenumber(Optional) The sweep to allow arcs to cover.