{"ScriptPreparationCode":"DISPLAYED_SCALE_XLABEL_POSITION = {\r\n HOURS: \u0027AT_TICK\u0027,\r\n DAYS: \u0027AT_TICK\u0027,\r\n WEEKS: \u0027BETWEEN_TICKS\u0027,\r\n MONTHS: \u0027BETWEEN_TICKS\u0027,\r\n};","TestCases":[{"Name":"use constant values","Code":"console.log(DISPLAYED_SCALE_XLABEL_POSITION[\u0027HOURS\u0027]);\r\nconsole.log(DISPLAYED_SCALE_XLABEL_POSITION[\u0027DAYS\u0027]);\r\nconsole.log(DISPLAYED_SCALE_XLABEL_POSITION[\u0027WEEKS\u0027]);\r\nconsole.log(DISPLAYED_SCALE_XLABEL_POSITION[\u0027MONTHS\u0027]);","IsDeferred":false},{"Name":"use wrapper function for this constant","Code":"function getAxisLabelPosition(scale, values) {\r\n return values[scale];\r\n}\r\nconsole.log(getAxisLabelPosition(\u0027HOURS\u0027, DISPLAYED_SCALE_XLABEL_POSITION));\r\nconsole.log(getAxisLabelPosition(\u0027DAYS\u0027, DISPLAYED_SCALE_XLABEL_POSITION));\r\nconsole.log(getAxisLabelPosition(\u0027WEEKS\u0027, DISPLAYED_SCALE_XLABEL_POSITION));\r\nconsole.log(getAxisLabelPosition(\u0027MONTHS\u0027, DISPLAYED_SCALE_XLABEL_POSITION));\r\n","IsDeferred":false}]}