from django.test import TestCase

from smoothglue.map.utils.coordinate_utils import get_decimal_degrees_from_dms_string


class TestCoordinateUtilsSerializer(TestCase):

    def test_serializer_valid(self):

        coordinate_str = "373420.50N1272218.92E"
        result = get_decimal_degrees_from_dms_string(coordinate_str)
        self.assertEqual(result, [127.37192222222221, 37.572361111111114])
