# Path: elodie/geolocation.py
# __KEY__ = None
# __DEFAULT_LOCATION__ = 'Unknown Location'
# __PREFER_ENGLISH_NAMES__ = None
#         __KEY__ = constants.mapquest_key
#     __KEY__ = config['MapQuest']['key']
#     __PREFER_ENGLISH_NAMES__ = bool(config['MapQuest']['prefer_english_names'])
# def coordinates_by_name(name):
# def decimal_to_dms(decimal):
# def dms_to_decimal(degrees, minutes, seconds, direction=' '):
# def dms_string(decimal, type='latitude'):
# def get_key():
# def get_prefer_english_names():
# def place_name(lat, lon):
# def lookup(**kwargs):
# def parse_result(result):


from builtins import range
from past.utils import old_div
from mock import patch
from tempfile import gettempdir
from . import helper
from elodie import geolocation
import mock
import os
import random
import re
import sys
from __future__ import absolute_import
from __future__ import division
# Project imports

sys.path.insert(0, os.path.abspath(os.path.dirname(os.path.dirname(os.path.dirname(os.path.realpath(__file__))))))


os.environ['TZ'] = 'GMT'


def test_decimal_to_dms():

    for x in range(0, 1000):
        target_decimal_value = random.uniform(0.0, 180.0)
        if(x % 2 == 1):
            target_decimal_value = target_decimal_value * -1


# Path: elodie/geolocation.py
# __KEY__ = None
# __DEFAULT_LOCATION__ = 'Unknown Location'
# __PREFER_ENGLISH_NAMES__ = None
#         __KEY__ = constants.mapquest_key
#     __KEY__ = config['MapQuest']['key']
#     __PREFER_ENGLISH_NAMES__ = bool(config['MapQuest']['prefer_english_names'])
# def coordinates_by_name(name):
# def decimal_to_dms(decimal):
# def dms_to_decimal(degrees, minutes, seconds, direction=' '):
# def dms_string(decimal, type='latitude'):
# def get_key():
# def get_prefer_english_names():
# def place_name(lat, lon):
# def lookup(**kwargs):
# def parse_result(result):


# Path: elodie/tests/geolocation_test.py
from builtins import range
from past.utils import old_div
from mock import patch
from tempfile import gettempdir
from . import helper
from elodie import geolocation
import mock
import os
import random
import re
import sys

from __future__ import absolute_import
from __future__ import division
# Project imports

sys.path.insert(0, os.path.abspath(os.path.dirname(os.path.dirname(os.path.dirname(os.path.realpath(__file__))))))


os.environ['TZ'] = 'GMT'


def test_decimal_to_dms():

    for x in range(0, 1000):
        target_decimal_value = random.uniform(0.0, 180.0)
        if(x % 2 == 1):
            target_decimal_value = target_decimal_value * -1


        dms = geolocation.decimal_to_dms(target_decimal_value)