refactored String Cal and added chai test