I am using Vaadin Testbench to implement test imulations. I have to check whether the Chrome Browsers language is English or German and based on that I have to set values either in English or German to simulate.
How to detect Chrome browser language when running the Integration test class? Based on the language detected I will set the language in the Chrome Driver parameters.
Using Vaadin
TestBench
, you can retrieve the language via a JavaScript call like soNote also that rather than retrieving the language, it might be useful to set it explicitly yourself like so