'Helper, assert that the given WMI query and flags were submitted.'

def assertWMIQuery(self, query=None, flags=None):

    if query:
        last_wmi_query = SWbemServices.get_last_wmi_query()
        self.assertEquals(last_wmi_query, query)
    if flags:
        last_wmi_flags = SWbemServices.get_last_wmi_flags()
        self.assertEquals(last_wmi_flags, flags)
