Refactored language_calculator_spec