File tree Expand file tree Collapse file tree 1 file changed +4
-5
lines changed Expand file tree Collapse file tree 1 file changed +4
-5
lines changed Original file line number Diff line number Diff line change 99
1010import difflib
1111import json
12- import logging
1312import os
1413import subprocess
1514from pathlib import Path
@@ -77,16 +76,16 @@ def test_one(self, testObj):
7776 try :
7877 a_parsed = parse_output (res .stdout , outputType )
7978 except Exception as e :
80- logging .error (f"Error parsing command output as { outputType } : '{ str (e )} '; res: { str (res )} " )
79+ self . log .error (f"Error parsing command output as { outputType } : '{ str (e )} '; res: { str (res )} " )
8180 raise
8281 try :
8382 b_parsed = parse_output (outputData , outputType )
8483 except Exception as e :
85- logging .error ('Error parsing expected output %s as %s: %s' % (outputFn , outputType , e ))
84+ self . log .error ('Error parsing expected output %s as %s: %s' % (outputFn , outputType , e ))
8685 raise
8786 # Compare data
8887 if a_parsed != b_parsed :
89- logging .error (f"Output data mismatch for { outputFn } (format { outputType } ); res: { str (res )} " )
88+ self . log .error (f"Output data mismatch for { outputFn } (format { outputType } ); res: { str (res )} " )
9089 data_mismatch = True
9190 # Compare formatting
9291 if res .stdout != outputData :
@@ -95,7 +94,7 @@ def test_one(self, testObj):
9594 res .stdout .splitlines (True ),
9695 fromfile = outputFn ,
9796 tofile = "returned" ))
98- logging .error (error_message )
97+ self . log .error (error_message )
9998 formatting_mismatch = True
10099
101100 assert not data_mismatch and not formatting_mismatch
You can’t perform that action at this time.
0 commit comments