fixed front-end unit tests to reflect the actual code used in app to perform calculations