tests.test_repo_not_found   A
last analyzed

Complexity

Total Complexity 2

Size/Duplication

Total Lines 11
Duplicated Lines 0 %

Importance

Changes 0
Metric Value
wmc 2
eloc 6
dl 0
loc 11
rs 10
c 0
b 0
f 0

1 Function

Rating   Name   Duplication   Size   Complexity  
A test_should_raise_error_if_repo_does_not_exist() 0 4 2
1
"""Testing invalid cookiecutter template repositories."""
2
import pytest
3
4
from cookiecutter import exceptions, main
5
6
7
def test_should_raise_error_if_repo_does_not_exist():
8
    """Cookiecutter invocation with non-exist repository should raise error."""
9
    with pytest.raises(exceptions.RepositoryNotFound):
10
        main.cookiecutter('definitely-not-a-valid-repo-dir')
11