Skip to content

Commit eac6cbd

Browse files
committed
test: fix unit tests
1 parent b891b9c commit eac6cbd

1 file changed

Lines changed: 3 additions & 4 deletions

File tree

openedx_authz/tests/test_commands.py

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -266,10 +266,9 @@ def test_interactive_request_error(self, exception: Exception, mock_is_allowed:
266266
with patch("builtins.input", side_effect=["alice view_library lib:Org1:LIB1", "quit"]):
267267
call_command(self.command_name, stdout=self.buffer)
268268

269-
invalid_output = self.buffer.getvalue()
270-
self.assertIn("✗ Invalid format. Expected 3 parts, got 2", invalid_output)
271-
self.assertIn("Format: subject action scope", invalid_output)
272-
self.assertIn(f"Example: alice read lib:Org1:LIB1 {make_scope_key('org', 'OpenedX')}", invalid_output)
269+
output = self.buffer.getvalue()
270+
self.assertIn("✗ Error processing request:", output)
271+
self.assertIn(str(exception), output)
273272

274273

275274
class LoadPoliciesCommandTests(TestCase):

0 commit comments

Comments
 (0)