Skip to content

Commit f20e367

Browse files
committed
round 2: ignore less
1 parent de25c04 commit f20e367

8 files changed

Lines changed: 217 additions & 182 deletions

File tree

tests/test_api.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -312,7 +312,7 @@ def test_build_super_table() -> None:
312312

313313
def test_add_dotted_key() -> None:
314314
doc = tomlkit.document()
315-
doc.add(tomlkit.key(["foo", "bar"]), 1) # type: ignore[arg-type]
315+
doc.add(tomlkit.key(["foo", "bar"]), 1)
316316
assert doc.as_string() == "foo.bar = 1\n"
317317

318318
table = tomlkit.table()

tests/test_build.py

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ def test_build_example(example: Callable[[str], str]) -> None:
1818
doc = document()
1919
doc.add(comment("This is a TOML document. Boom."))
2020
doc.add(nl())
21-
doc.add("title", "TOML Example") # type: ignore[arg-type]
21+
doc.add("title", "TOML Example")
2222

2323
owner = table()
2424
owner.add("name", "Tom Preston-Werner")
@@ -41,9 +41,10 @@ def test_build_example(example: Callable[[str], str]) -> None:
4141
servers.add(nl())
4242
c = comment(
4343
"You can indent as you please. Tabs or spaces. TOML don't care."
44-
).indent(2)
44+
)
45+
c.indent(2)
4546
c.trivia.trail = ""
46-
servers.add(c) # type: ignore[call-overload]
47+
servers.add(c)
4748
alpha = table()
4849
servers.append("alpha", alpha)
4950
alpha.indent(2)
@@ -100,7 +101,7 @@ def test_add_remove() -> None:
100101
content = ""
101102

102103
doc = parse(content)
103-
doc.append("foo", "bar") # type: ignore[arg-type]
104+
doc.append("foo", "bar")
104105

105106
assert (
106107
doc.as_string()
@@ -125,7 +126,7 @@ def test_append_table_after_multiple_indices() -> None:
125126
version = "*"
126127
"""
127128
doc = parse(content)
128-
doc.append("foobar", {"name": "John"}) # type: ignore[arg-type]
129+
doc.append("foobar", {"name": "John"})
129130

130131

131132
def test_top_level_keys_are_put_at_the_root_of_the_document() -> None:

0 commit comments

Comments
 (0)