示例#1
0
def test_parse_stop_dom_ria_flat_invalid(
        dom_ria_flat_parser: DomRiaFlatParser):
    assert None is dom_ria_flat_parser.parse_stop(-13)  # noqa
    assert None is dom_ria_flat_parser.parse_stop(None)  # noqa
    assert None is dom_ria_flat_parser.parse_stop('')  # noqa
    assert None is dom_ria_flat_parser.parse_stop({'url': 'https://xxx.org/'
                                                   })  # noqa
示例#2
0
def test_parse_stop_dom_ria_flat(dom_ria_flat_parser: DomRiaFlatParser):
    assert 5664 == dom_ria_flat_parser.parse_stop(
        read('fixtures/test_parse_stop/dom_ria_flat0.html'))