Skip to content

Commit

Permalink
Merge pull request #21 from szkiba/feature/report
Browse files Browse the repository at this point in the history
Feature/report
  • Loading branch information
szkiba authored May 18, 2023
2 parents 7301ec6 + 35bd0c3 commit 376b757
Show file tree
Hide file tree
Showing 50 changed files with 1,425 additions and 335 deletions.
3 changes: 2 additions & 1 deletion .dashboard.js
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,8 @@ const customTab = {
title: 'Custom',
event: overview.event,
panels: customPanels,
charts: [overview.chart('http_reqs'), durationChart]
charts: [overview.chart('http_reqs'), durationChart],
description: 'Example of customizing the display of metrics.'
}

// add custom tab to configuration
Expand Down
28 changes: 27 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,20 +12,45 @@ By using **xk6-dashboard** output extension you can access metrics from [k6](htt
**Screenshots**

*Overview*

The overview tabs provides an overview of the most important metrics of the test run. Graphs plot the value of metrics over time.

![k6 dashboard overview snapshot](screenshot/k6-dashboard-overview-snapshot.png)

*Overview Cumulative*
![k6 dashboard overview cumulative](screenshot/k6-dashboard-overview-cumulative.png)

*Timings*

The timings tabs provides an overview of test run HTTP timing metrics. Graphs plot the value of metrics over time.

![k6 dashboard timings snapshot](screenshot/k6-dashboard-timings-snapshot.png)

*Timings Cumulative*
![k6 dashboard timings cumulative](screenshot/k6-dashboard-timings-cumulative.png)

*Custom Tab*

Example of customizing the display of metrics.

![k6 dashboard custom](screenshot/k6-dashboard-custom.png)

*Summary Tab*

Summary tab contains a summary of the test run metrics. The tables contains the aggregated values of the metrics for the entire test run.

![k6 dashboard summary](screenshot/k6-dashboard-summary.png)

**Report**

The report tab contains a test run report in a printable (or saveable to PDF) format.

*Report Tab*
![k6 dashboard report](screenshot/k6-dashboard-report.png)

*Report PDF*

See [sample PDF report](screenshot/k6-dashboard-report.pdf)

**Table of Contents**

Expand Down Expand Up @@ -198,7 +223,8 @@ const customTab = {
title: 'Custom',
event: overview.event,
panels: customPanels,
charts: [overview.chart('http_reqs'), durationChart]
charts: [overview.chart('http_reqs'), durationChart],
description: 'Example of customizing the display of metrics.'
}
// add custom tab to configuration
Expand Down
4 changes: 4 additions & 0 deletions dashboard/extension_test.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
// SPDX-FileCopyrightText: 2023 Iván Szkiba
//
// SPDX-License-Identifier: MIT

package dashboard

import (
Expand Down
4 changes: 4 additions & 0 deletions dashboard/helper_test.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
// SPDX-FileCopyrightText: 2023 Iván Szkiba
//
// SPDX-License-Identifier: MIT

package dashboard

import (
Expand Down
4 changes: 4 additions & 0 deletions dashboard/meter_test.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
// SPDX-FileCopyrightText: 2023 Iván Szkiba
//
// SPDX-License-Identifier: MIT

package dashboard

import (
Expand Down
4 changes: 4 additions & 0 deletions dashboard/options_test.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
// SPDX-FileCopyrightText: 2023 Iván Szkiba
//
// SPDX-License-Identifier: MIT

package dashboard

import (
Expand Down
4 changes: 4 additions & 0 deletions dashboard/registry_test.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
// SPDX-FileCopyrightText: 2023 Iván Szkiba
//
// SPDX-License-Identifier: MIT

package dashboard

import (
Expand Down
2 changes: 2 additions & 0 deletions dashboard/sse.go
Original file line number Diff line number Diff line change
Expand Up @@ -50,5 +50,7 @@ func (esrc *eventSource) ServeHTTP(res http.ResponseWriter, req *http.Request) {
values.Add("stream", esrc.channel)
req.URL.RawQuery = values.Encode()

res.Header().Set("Access-Control-Allow-Origin", "*")

esrc.Server.ServeHTTP(res, req)
}
4 changes: 4 additions & 0 deletions dashboard/sse_test.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
// SPDX-FileCopyrightText: 2023 Iván Szkiba
//
// SPDX-License-Identifier: MIT

package dashboard

import (
Expand Down
4 changes: 4 additions & 0 deletions dashboard/web_test.go
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
// SPDX-FileCopyrightText: 2023 Iván Szkiba
//
// SPDX-License-Identifier: MIT

package dashboard

import (
Expand Down
1 change: 1 addition & 0 deletions magefiles/magefile.go
Original file line number Diff line number Diff line change
Expand Up @@ -148,6 +148,7 @@ func Exif() error {
`exiftool -ext png -overwrite_original -XMP:Subject+="k6 dashboard xk6" -Title="k6 dashboard screenshot" -Description="Screenshot of xk6-dashboard extension that enables creating web based metrics dashboard for k6." -Author="Ivan SZKIBA" screenshot`,
`exiftool -all= -overwrite_original -ext png .github`,
`exiftool -ext png -overwrite_original -XMP:Subject+="k6 dashboard xk6" -Title="k6 dashboard screenshot" -Description="Screenshot of xk6-dashboard extension that enables creating web based metrics dashboard for k6." -Author="Ivan SZKIBA" .github`,
`exiftool -ext pdf -overwrite_original -Subject+="k6 dashboard report" -Title="k6 dashboard report" -Description="Example report of xk6-dashboard extension that enables creating web based metrics dashboard for k6." -Author="Ivan SZKIBA" screenshot`,
)
}

Expand Down
Binary file modified screenshot/k6-dashboard-custom.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified screenshot/k6-dashboard-overview-cumulative.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified screenshot/k6-dashboard-overview-snapshot.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added screenshot/k6-dashboard-report.pdf
Binary file not shown.
Binary file added screenshot/k6-dashboard-report.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added screenshot/k6-dashboard-summary.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified screenshot/k6-dashboard-timings-cumulative.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified screenshot/k6-dashboard-timings-snapshot.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 0 additions & 1 deletion ui/assets/ui/dist/assets/index-5c1d0d38.css

This file was deleted.

1 change: 1 addition & 0 deletions ui/assets/ui/dist/assets/index-d1d2aca3.css

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit 376b757

Please sign in to comment.