Esempio n. 1
0
def test_should_add_to_readahead_no_referrer_yes_header():
    assert should_add_to_readahead(EX_CONFIG, None, HEADER_YES) is True
Esempio n. 2
0
def test_should_add_to_readahead_no_referrer():
    assert should_add_to_readahead(EX_CONFIG, None, HEADER_NO) is False
Esempio n. 3
0
def test_should_add_to_readahead_sane_url_no_header():
    assert should_add_to_readahead(EX_CONFIG, 'http://grafana/blah', HEADER_NO) is True
Esempio n. 4
0
def test_should_add_to_readahead_edit_url_no_header():
    assert should_add_to_readahead(EX_CONFIG, 'http://grafana/blah&edit', HEADER_NO) is False
Esempio n. 5
0
def test_should_add_to_readahead_edit_url_with_header():
    assert should_add_to_readahead(EX_CONFIG, 'http://grafana/blah&edit', HEADER_YES) is True
Esempio n. 6
0
def test_should_add_to_readahead_header_set():
    assert should_add_to_readahead(EX_CONFIG, 'http://whatever', HEADER_YES) is True