function createTestData(agent, callback) {
  const metric = agent.metrics.getOrCreateMetric('myMetric')
  metric.incrementCallCount()

  agent.errors.addUserError(null, new Error('Why?!!!?!!'))

  agent.customEventAggregator.add([{ type: 'MyCustomEvent', timestamp: Date.now() }])

  helper.runInTransaction(agent, (transaction) => {
    const segment = transaction.trace.add('MySegment')
    segment.overwriteDurationInMillis(1)
    agent.queries.add({
      segment,
      transaction,
      type: 'mysql',
      query: 'select * from foo',
      trace: new Error().stack
    })

    transaction.finalizeNameFromUri('/some/test/url', 200)
    transaction.end()
    callback()
  })
}
Adds data to agent instance for use in endpoint tests.
Each type is added every test, even though not all endpoints are mocked.
This allows for verifying response handling for endpoint under test still
behaves correctly when other endpoints fail.
@param {*} agent The agent instance to add data to
@param {*} callback