Specify Geolocation for Cypress tests - LambdaTest
chuac
Posted on November 3, 2022
If you're using a tool like LambdaTest Cypress Automation to execute your Cypress tests as part of your pipelines, you may eventually require the environment your tests are running on to mock certain Geolocations which your tests are dependent on.
Luckily, with LambdaTest, this is possible however it is not clear in their documentation on how to turn this on!
After consulting with their handy tech support, the following is how we can specify Australia as the Geolocation of the machine LambdaTest runs our Cypress tests on:
Inside lambdatest-config.json
:
"run_settings": {
...
"geo_location": "AU",
...
}
It is unclear what ISO standard that LambdaTest uses for their geo_location
field, but ISO 3166-1 (Alpha-2) is a good bet.
Posted on November 3, 2022
Join Our Newsletter. No Spam, Only the good stuff.
Sign up to receive the latest update from our blog.