cleaned up FormulaTestUtils by adding a commonly used function.