input: Write a python function to parse XML files and extract specific event features into a CSV file.
  assert FeaturesExtractor().parseFile('test.xml') == expected_output
  assert FeaturesExtractor().save_to_csv('test_output.csv') == expected_csv_output
output: import xml.etree.ElementTree as ET
  import csv
  
  class FeaturesExtractor:
      def __init__(self):
          self.data = []
  
      def parseFile(self, file_path):
          tree = ET.parse(file_path)
          root = tree.getroot()
          for event in root.findall('event'):
              event_data = {}
              event_data['id'] = event.get('id')
              event_data['type'] = event.find('type').text
              event_data['timestamp'] = event.find('timestamp').text
              self.data.append(event_data)
          return self.data
  
      def save_to_csv(self, output_file):
          keys = self.data[0].keys()
          with open(output_file, 'w', newline='') as csvfile:
              dict_writer = csv.DictWriter(csvfile, fieldnames=keys)
              dict_writer.writeheader()
              dict_writer.writerows(self.data)
          return output_file