Пример #1
0
def test_0_http_www_valid_com():
    assert url('http://www.valid.com') == 'http://www.valid.com'
Пример #2
0
def test_1_https_valid_com():
    assert url('https://valid.com') == 'https://valid.com'
Пример #3
0
def test_8_https_invalid_com():
    with pytest.raises(ValueError) as excinfo:
        url('https//invalid.com')
Пример #4
0
def test_9_https_invalid():
    with pytest.raises(ValueError) as excinfo:
        url('https://invalid')
Пример #5
0
def test_6_htp_www_invalid_com():
    with pytest.raises(ValueError) as excinfo:
        url('htp://www.invalid.com')
Пример #6
0
def test_5_www_invalid_com():
    with pytest.raises(ValueError) as excinfo:
        url('www.invalid.com')
Пример #7
0
def test_4_www_invalid():
    with pytest.raises(ValueError) as excinfo:
        url('www.invalid')
Пример #8
0
def test_3_invalid():
    with pytest.raises(ValueError) as excinfo:
        url('invalid')
Пример #9
0
def test_2_https_www_valid_com():
    assert url('https://www.valid.com') == 'https://www.valid.com'