added beforeAction statement to spec file
Added a test for calculation but it is not working, not sure what it is