No results for

Powered byAlgolia
⚠️ This documentation is outdated. Please visit grafana.com for the latest k6 documentation.📚

setGeolocation(geolocation)

attention

This feature has known issues. For details, refer to #435.

Sets the context's geolocation.

ParameterTypeDefaultDescription
geolocation
objectnull

Example

import { chromium } from 'k6/experimental/browser';
export default function () {
const browser = chromium.launch();
const context = browser.newContext();
context.setGeolocation({latitude: 59.95, longitude: 30.31667});
}