Пример #1
0
def test_basic_client():
    client = correios.Correios(username="******",
                               password="******",
                               environment=correios.Correios.TEST)
    assert client.sigep_url == str(
        get_resource_path('wsdls/AtendeCliente-test.wsdl'))
    assert not client.sigep_verify
    assert client.username == "sigep"
    assert client.password == "XXXXXX"
Пример #2
0
class Freight(WebService):
    base_uri = str(get_resource_path('wsdls') / 'CalcPrecoPrazo.xml')
Пример #3
0
def test_should_use_pkg_resources_to_get_wsdl_files(mock_resource):
    path = get_resource_path('fake')

    mock_resource.assert_called_with('correios', 'data/fake')
    assert str(path) == "/"
Пример #4
0
def test_get_wsdl_file_path():
    path = get_resource_path('fake')
    assert str(path).endswith('correios/data/fake')
Пример #5
0
def test_should_use_pkg_resources_to_get_wsdl_files(mock_resource):
    path = get_resource_path('fake')

    mock_resource.assert_called_with('correios', 'data/fake')
    assert str(path) == "/"
Пример #6
0
def test_get_wsdl_file_path():
    path = get_resource_path('fake')
    assert str(path).endswith('correios/data/fake')