{"ScriptPreparationCode":"var rect = document.getElementById(\u0027rect1\u0027);\r\nvar width = Number(rect.getAttribute(\u0027width\u0027));","TestCases":[{"Name":"set the same value","Code":"rect.setAttribute(\u0027width\u0027, width);","IsDeferred":false},{"Name":"check and set nothing","Code":"if (rect.getAttribute(\u0027width\u0027) !== \u0060${width}\u0060) {\r\n alert(\u0027this code does not run\u0027);\r\n}","IsDeferred":false},{"Name":"check and set a new value","Code":"if (rect.getAttribute(\u0027width\u0027) !== \u0060${\u002B\u002Bwidth}\u0060) {\r\n rect.setAttribute(\u0027width\u0027, width);\r\n}","IsDeferred":false},{"Name":"set a new value","Code":"rect.setAttribute(\u0027width\u0027, \u002B\u002Bwidth);","IsDeferred":false},{"Name":"check cache and set nothing","Code":"const cache = width;\r\nif (cache !== width) {\r\n alert(\u0027this code does not run\u0027);\r\n}","IsDeferred":false},{"Name":"check cache and set a new value","Code":"const cache = width;\r\nif (cache !== \u002B\u002Bwidth) {\r\n rect.setAttribute(\u0027width\u0027, width);\r\n}","IsDeferred":false}]}