This is an easy and quick way to test if a URI will use your proxy-server or be bypassed as per your IE settings:

Note: The URI has to be complete – http://www.google.com.au as e.g.

Function Test-ProxyBypass
{
  param
  (
    [Parameter(Mandatory=$true)]
    [string]$url
  )
 
  $webclient = New-Object System.Net.WebClient
  return $webclient.Proxy.IsBypassed($url)
}