def testGetFormatStringAttributeNames(self): """Tests the GetFormatStringAttributeNames function.""" event_formatter = pcap.PCAPFormatter() expected_attribute_names = [ 'source_ip', 'dest_ip', 'source_port', 'dest_port', 'protocol', 'stream_type', 'size', 'protocol_data', 'stream_data', 'first_packet_id', 'last_packet_id', 'packet_count' ] self._TestGetFormatStringAttributeNames(event_formatter, expected_attribute_names)
def testInitialization(self): """Tests the initialization.""" event_formatter = pcap.PCAPFormatter() self.assertIsNotNone(event_formatter)