Skip to content

Commit f241ae9

Browse files
authored
Add flynt and --cov-report=term-missing
1 parent 7aabc88 commit f241ae9

File tree

3 files changed

+7
-9
lines changed

3 files changed

+7
-9
lines changed

eland/dataframe.py

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -889,10 +889,7 @@ def _verbose_repr() -> None:
889889
counts = self.count()
890890
if len(cols) != len(counts): # pragma: no cover
891891
raise AssertionError(
892-
"Columns must equal counts "
893-
"({cols:d} != {counts:d})".format(
894-
cols=len(cols), counts=len(counts)
895-
)
892+
f"Columns must equal counts ({len(cols):d} != {len(counts):d})"
896893
)
897894
count_header = "Non-Null Count"
898895
len_count = len(count_header)

noxfile.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -55,10 +55,11 @@
5555

5656
@nox.session(reuse_venv=True)
5757
def format(session):
58-
session.install("black", "isort")
58+
session.install("black", "isort", "flynt")
5959
session.run("python", "utils/license-headers.py", "fix", *SOURCE_FILES)
60+
session.run("flynt", *SOURCE_FILES)
6061
session.run("black", "--target-version=py37", *SOURCE_FILES)
61-
session.run("isort", *SOURCE_FILES)
62+
session.run("isort", "--profile=black", *SOURCE_FILES)
6263
lint(session)
6364

6465

@@ -70,7 +71,7 @@ def lint(session):
7071
session.install("--pre", "elasticsearch")
7172
session.run("python", "utils/license-headers.py", "check", *SOURCE_FILES)
7273
session.run("black", "--check", "--target-version=py37", *SOURCE_FILES)
73-
session.run("isort", "--check", *SOURCE_FILES)
74+
session.run("isort", "--check", "--profile=black", *SOURCE_FILES)
7475
session.run("flake8", "--ignore=E501,W503,E402,E712,E203", *SOURCE_FILES)
7576

7677
# TODO: When all files are typed we can change this to .run("mypy", "--strict", "eland/")
@@ -107,8 +108,7 @@ def test(session, pandas_version: str):
107108
"python",
108109
"-m",
109110
"pytest",
110-
"--cov-report",
111-
"term-missing",
111+
"--cov-report=term-missing",
112112
"--cov=eland/",
113113
"--cov-config=setup.cfg",
114114
"--doctest-modules",

setup.cfg

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,3 +6,4 @@ plugins = numpy.typing.mypy_plugin
66
exclude_lines=
77
@abstractmethod
88
if TYPE_CHECKING:
9+
raise NotImplementedError*

0 commit comments

Comments
 (0)