Skip to content
This repository has been archived by the owner on Feb 3, 2024. It is now read-only.

Commit

Permalink
Merge pull request #335 from maarten-boot/master
Browse files Browse the repository at this point in the history
update make test
  • Loading branch information
maarten-boot authored Nov 2, 2023
2 parents e62cd3e + 9457074 commit 995091d
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 5 deletions.
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ reformat:
./reformat-code.sh

test:
./test2.py -d google.com
./test2.py -t 2>2 | tee 1

build:
python -m build
Expand Down
11 changes: 8 additions & 3 deletions testwhl.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
import whois

domain = "google.com"
d = whois.query(domain, verbose=True)
print(d.__dict__)
for tld in whois.validTlds():
hint = whois.getTestHint(tld)
if hint:
print(f"# == {hint}")
d = whois.query(hint, verbose=True)
for k,v in d.__dict__.items():
print(f"\t{k}\t{v}")
print("")
2 changes: 1 addition & 1 deletion whois/tldDb/tld_regexpr.py
Original file line number Diff line number Diff line change
Expand Up @@ -736,7 +736,7 @@ def xStr(what: str, times: int = 1, firstMandatory: bool = True) -> str:
"creation_date": R(r"\ncreated:\s*(.+)\n"),
"updated_date": R(r"\nlast modified:\s*(.+)\n"),
# If no "option expiration date:" is present, use "renewal date:", but only
# if it's not not followed by "option expiration date:".
# if it's not not followed by "option expiration date:". google.pl is the test case here
"expiration_date": R(r"(?:\noption expiration date:|renewal date:(?!(?:.|\n)*\noption expiration date:))\s*(.+)\n"),
"name_servers": R(r"nameservers:%s" % xStr(r"(?:\s+(\S+)[^\n]*\n)?", 4)),
"status": R(r"\nStatus:\n\s*(.+)"),
Expand Down

0 comments on commit 995091d

Please sign in to comment.