tests.test_manifest_file   A
last analyzed

Complexity

Total Complexity 3

Size/Duplication

Total Lines 18
Duplicated Lines 0 %

Importance

Changes 0
Metric Value
wmc 3
eloc 10
dl 0
loc 18
rs 10
c 0
b 0
f 0

1 Function

Rating   Name   Duplication   Size   Complexity  
A test_manifest_file() 0 10 3
1
"""
2
Manifest file testing module for the generated project.
3
"""
4
import os
5
from . import bake_cookie, load_cookiecutter_json
6
7
8
def test_manifest_file(cookies):
9
    "Test that the MANIFEST.in file exists and the content is valid"
10
    with bake_cookie(cookies) as result:
11
        manifest_file_path = result.project_path.joinpath("MANIFEST.in")
12
        cookiecutter_json = load_cookiecutter_json()
13
14
        assert os.path.exists(manifest_file_path)
15
16
        with open(manifest_file_path, "r") as fp:
0 ignored issues
show
Coding Style Naming introduced by
Variable name "fp" doesn't conform to snake_case naming style ('([^\\W\\dA-Z][^\\WA-Z]2,|_[^\\WA-Z]*|__[^\\WA-Z\\d_][^\\WA-Z]+__)$' pattern)

This check looks for invalid names for a range of different identifiers.

You can set regular expressions to which the identifiers must conform if the defaults do not match your requirements.

If your project includes a Pylint configuration file, the settings contained in that file take precedence.

To find out more about Pylint, please refer to their site.

Loading history...
17
            assert str(cookiecutter_json["project_slug"]) in fp.read()
18