@@ -59,7 +59,7 @@ def test_api_forwarding_get_active_xapi_forwardings_with_empty_forwardings(
5959 configuration, should log that forwarding is inactive and return an empty list.
6060 """
6161
62- expected_log = "No xAPI forwarding is configured; forwarding is disabled."
62+ expected_log = "No xAPI forwarding configured; forwarding is disabled."
6363 # RALPH_XAPI_FORWARDINGS not set
6464 monkeypatch .delenv ("RALPH_XAPI_FORWARDINGS" , raising = False )
6565 monkeypatch .setattr ("ralph.api.forwarding.settings" , Settings ())
@@ -108,7 +108,7 @@ def test_api_forwarding_get_active_xapi_forwardings_with_inactive_forwardings(
108108
109109 msg = (
110110 f"The RALPH_XAPI_FORWARDINGS configuration value: '{ inactive_forwarding } ' is "
111- "not activated . It will be ignored."
111+ "not active . It will be ignored."
112112 )
113113 assert len (caplog .record_tuples ) == 1
114114 assert caplog .record_tuples [0 ][2 ] == msg
@@ -163,6 +163,7 @@ async def post_success(*args, **kwargs): # pylint: disable=unused-argument
163163 monkeypatch .setenv ("RALPH_XAPI_FORWARDINGS" , f"[{ forwarding .json ()} ]" )
164164 monkeypatch .setattr ("ralph.api.forwarding.settings" , Settings ())
165165
166+ caplog .clear ()
166167 with caplog .at_level (logging .DEBUG ):
167168 asyncio .get_event_loop ().run_until_complete (forward_xapi_statements (statements ))
168169
@@ -205,7 +206,7 @@ async def post_fail(*args, **kwargs): # pylint: disable=unused-argument
205206 monkeypatch .setenv ("RALPH_XAPI_FORWARDINGS" , f"[{ forwarding .json ()} ]" )
206207 monkeypatch .setattr ("ralph.api.forwarding.settings" , Settings ())
207208
208- with caplog .at_level (logging .DEBUG ):
209+ with caplog .at_level (logging .ERROR ):
209210 asyncio .get_event_loop ().run_until_complete (forward_xapi_statements (statements ))
210211
211212 assert ["Failed to forward xAPI statements. Something went wrong." ] == [
0 commit comments