function getActionForAssertion({ agent, assertion }) {
  const childActions = []
  const method = camelCase(assertion.rule.operator)
  childActions.push(() => {
    logger('RUNNING ASSERTION', method, assertion.description)
    testAssertions[method](agent, assertion.rule.parameters, assertion.description)
  })

  return () => {
    childActions.forEach((action) => action())
  }
}
Adds an assertion to the queue to be run after operations

@param {object} params to function
@param {Agent} params.agent agent instance
@param {object} params.assertion assertion object that defines the assertion to run
@returns {function} deferred function to run