Fixed jscs errors
Added tests to validate duration syntax.