mirror of
https://github.com/StevenBlack/hosts.git
synced 2024-07-02 02:25:54 +02:00
First, format with black.
This commit is contained in:
parent
3e06d4b8b5
commit
a2008b78f9
|
@ -1743,9 +1743,7 @@ class TestIsValidDomainFormat(BaseStdout):
|
||||||
self.assertTrue(expected in output)
|
self.assertTrue(expected in output)
|
||||||
|
|
||||||
def test_invalid_domain(self):
|
def test_invalid_domain(self):
|
||||||
expected = (
|
expected = "Do not include www.domain.com or http(s)://domain.com. Try again."
|
||||||
"Do not include www.domain.com or http(s)://domain.com. Try again."
|
|
||||||
)
|
|
||||||
|
|
||||||
for invalid_domain in [
|
for invalid_domain in [
|
||||||
"www.subdomain.domain",
|
"www.subdomain.domain",
|
||||||
|
|
|
@ -80,7 +80,10 @@ def main():
|
||||||
source_rows += t.substitute(this_row) + "\n"
|
source_rows += t.substitute(this_row) + "\n"
|
||||||
|
|
||||||
with open(
|
with open(
|
||||||
os.path.join(data[key]["location"], README_FILENAME), "wt", encoding="utf-8", newline="\n"
|
os.path.join(data[key]["location"], README_FILENAME),
|
||||||
|
"wt",
|
||||||
|
encoding="utf-8",
|
||||||
|
newline="\n",
|
||||||
) as out:
|
) as out:
|
||||||
for line in open(README_TEMPLATE, encoding="utf-8", newline="\n"):
|
for line in open(README_TEMPLATE, encoding="utf-8", newline="\n"):
|
||||||
line = line.replace(
|
line = line.replace(
|
||||||
|
|
Loading…
Reference in New Issue
Block a user