dicogis.utils.checknorris module

Name: Check Norris Purpose: A class dedicated to perform system test to ensure another program works fine

Author: Julien Moura (@geojulien)

class dicogis.utils.checknorris.CheckNorris

Bases: object

Check Norris never fails, always tests.

check_internet_connection(remote_server='www.google.com')

Check if an internet connection is operational.

Source: http://stackoverflow.com/a/20913928/2556577

Parameters:

remote_server (str) – internet address to try. Defaults to “www.google.com”.

Return type:

bool

Returns:

True if connection works

check_proxy(specific={})

Check if proxy settings are set on the OS.

Returns: – 1 when direct connection works fine – 2 when direct connection fails and any proxy is set in the OS – 3 and settings when direct connection fails but a proxy is set see: https://docs.python.org/2/library/urllib.html#urllib.getproxies