Xk6-browser for pages behind authentication

Hi @sashi1, welcome to the forum :slight_smile:

  1. Metrics are emitted by xk6-browser, and collected and processed by any k6 output you have enabled, so they work the same way as with plain k6. Let me know if you have a specific question about this.

  2. The end-of-test summary shows an aggregated view of all metric data. But you can see individual metric samples by enabling a k6 output.

    For example, if you enable the JSON output with xk6-browser run --out json=result.json script.js, you’ll see all raw metric data in the created result.json file. There you can see DOM related metrics for any loaded pages, and HTTP related metrics for any URLs loaded by the page, such as static assets. There will be no averages here, just raw metric samples for each URL.

    So to answer your question, you’ll see metric data separately for all pages loaded in your script (/login, /marketplace, etc.).

Hope this helps,

Ivan