#NEWLINE# def error_status_logged( case , logger ) : #NEWLINE# #INDENT# '\n    Validate the error logging behavior of ``_sync_command_error_squashed``.\n    ' #NEWLINE# assertHasMessage ( logger , logger , ZFS_ERROR , { #NEWLINE# #INDENT# 'status' : 1 , #NEWLINE# 'zfs_command' : 'python -c raise SystemExit(1)' , #NEWLINE# 'output' : '' , #NEWLINE# #UNINDENT# } ) #NEWLINE# case . assertEqual ( len ( LoggedMessage . ofType ( logger . messages , ZFS_ERROR ) ) , 1 )