Skip to content

Commit

Permalink
Fix base model formatting test
Browse files Browse the repository at this point in the history
  • Loading branch information
tpoliaw committed Sep 5, 2024
1 parent cba1fb7 commit c49b1b9
Showing 1 changed file with 2 additions and 14 deletions.
16 changes: 2 additions & 14 deletions tests/test_cli.py
Original file line number Diff line number Diff line change
Expand Up @@ -150,7 +150,7 @@ def test_valid_stomp_config_for_listener(runner: CliRunner):
)
assert (
result.output
== "Subscribing to all bluesky events from localhost:61613\nPress enter to exit"
== "Subscribing to all bluesky events from localhost:61613\nPress enter to exit\n"
)
assert result.exit_code == 0

Expand Down Expand Up @@ -511,19 +511,7 @@ def test_unknown_object_formatting():
def test_generic_base_model_formatting():
output = StringIO()
obj = ExtendedModel(name="foo", keys=[1, 2, 3], metadata={"fizz": "buzz"})
exp = dedent("""\
{
"name": "foo",
"keys": [
1,
2,
3
],
"metadata": {
"fizz": "buzz"
}
}
""")
exp = '{"name": "foo", "keys": [1, 2, 3], "metadata": {"fizz": "buzz"}}\n'
OutputFormat.JSON.display(obj, output)
assert exp == output.getvalue()

Expand Down

0 comments on commit c49b1b9

Please sign in to comment.