1

The test fails when I'm connected through the VPN but without it works fine. It performs a click to this URL: https://www.google.com/search?q=let+me+google+that+for+you

I tried with the --proxy-bypass setting but I suppose I'm not doing it right, any guidance on how it should look like?

Alex Skorkin
  • 4,264
  • 3
  • 25
  • 47
viktors89
  • 97
  • 1
  • 1
  • 7

1 Answers1

3

A VPN should not affect your tests. Judging by the symptoms, it looks like you are using a proxy, not a VPN. If it's true, the proxy server address should be specified using the --proxy option as described here mentioned below.

--proxy <host>

Specifies the proxy server used in your local network to access the Internet.

testcafe chrome my-tests/**/*.js --proxy proxy.corp.mycompany.com
testcafe chrome my-tests/**/*.js --proxy 172.0.10.10:8080

You can also specify authentication credentials with the proxy host.

testcafe chrome my-tests/**/*.js --proxy username:password@proxy.mycorp.com

As for the --proxy-bypass option, it has the opposite meaning. You can use it to specify resources that are not proxied, for example, the ones that are hosted inside of your local network.

Bharadwaj Pendyala
  • 324
  • 1
  • 3
  • 16
Alexey Lindberg
  • 756
  • 3
  • 12
  • 1
    You are absolutely right, I made it work exactly with what you said! proxy option and then the bypass for the ones hosted inside my local network! – viktors89 Oct 17 '19 at 16:33