Skip to content

Commit 0fd9012

Browse files
🧪 [testing improvement] Refactor imports in command_arguments tests
Updated the test file to import the `command_arguments` module instead of the `parse_command_arguments` function directly, following the project's coding conventions as requested in the PR review. Co-authored-by: rnovatorov <20299819+rnovatorov@users.noreply.github.com>
1 parent 2e3fd3d commit 0fd9012

1 file changed

Lines changed: 4 additions & 4 deletions

File tree

‎tests/unit/test_cli/test_http/test_api/test_command_arguments.py‎

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,21 +2,21 @@
22

33
import pytest
44

5-
from enapter.cli.http.api.command_arguments import parse_command_arguments
5+
from enapter.cli.http.api import command_arguments
66

77

88
def test_parse_command_arguments_none():
9-
assert parse_command_arguments(None) == {}
9+
assert command_arguments.parse_command_arguments(None) == {}
1010

1111

1212
def test_parse_command_arguments_valid_json():
13-
assert parse_command_arguments('{"foo": "bar", "baz": 1}') == {
13+
assert command_arguments.parse_command_arguments('{"foo": "bar", "baz": 1}') == {
1414
"foo": "bar",
1515
"baz": 1,
1616
}
1717

1818

1919
def test_parse_command_arguments_invalid_json():
2020
with pytest.raises(argparse.ArgumentTypeError) as excinfo:
21-
parse_command_arguments("invalid json")
21+
command_arguments.parse_command_arguments("invalid json")
2222
assert "Decode JSON:" in str(excinfo.value)

0 commit comments

Comments
 (0)