Skip to content

Commit

Permalink
Merge pull request #809 from oduwsdl/issue-808
Browse files Browse the repository at this point in the history
Fix reference to function that changed names
  • Loading branch information
machawk1 authored Aug 16, 2023
2 parents 54a23e2 + d12d9c8 commit f325ba7
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 9 deletions.
2 changes: 1 addition & 1 deletion ipwb/__main__.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ def main():
check_args(sys.argv)


def checkArgs_index(args):
def check_args_index(args):
# args.daemon_address is always set. Either default or by CLI
try:
# see if it parses
Expand Down
16 changes: 8 additions & 8 deletions tests/test_daemon.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,29 +29,29 @@ def test_daemon_wrong_scheme():
daemon = "/dnswrong/localhost/tcp/5001/http"
args['daemon_address'] = daemon
with pytest.raises(multiaddr_exceptions.StringParseError):
__main__.checkArgs_index(dotdict(args))
__main__.checkArgs_replay(dotdict(args))
__main__.check_args_index(dotdict(args))
__main__.check_args_replay(dotdict(args))


def test_daemon_wrong_ip():
daemon = "/ip4/256.999.478.444/tcp/5001/http"
args['daemon_address'] = daemon
with pytest.raises(multiaddr_exceptions.StringParseError):
__main__.checkArgs_index(dotdict(args))
__main__.checkArgs_replay(dotdict(args))
__main__.check_args_index(dotdict(args))
__main__.check_args_replay(dotdict(args))


def test_daemon_wrong_protocol():
daemon = "/dns/localhost/tcp/5001/httpwrong"
args['daemon_address'] = daemon
with pytest.raises(multiaddr_exceptions.StringParseError):
__main__.checkArgs_index(dotdict(args))
__main__.checkArgs_replay(dotdict(args))
__main__.check_args_index(dotdict(args))
__main__.check_args_replay(dotdict(args))


def test_daemon_wrong_format():
daemon = "localhost:5001"
args['daemon_address'] = daemon
with pytest.raises(multiaddr_exceptions.StringParseError):
__main__.checkArgs_index(dotdict(args))
__main__.checkArgs_replay(dotdict(args))
__main__.check_args_index(dotdict(args))
__main__.check_args_replay(dotdict(args))

0 comments on commit f325ba7

Please sign in to comment.