Clean up a CSS length values test.

A previous iteration of the patch for this bug caused some failures
here, and these changes made them easier to debug.

Differential Revision: https://phabricator.services.mozilla.com/D143941

bugzilla-url: https://bugzilla.mozilla.org/show_bug.cgi?id=1764768
gecko-commit: 7e796201e5512cd6b18e36ad6b386fc982902019
gecko-reviewers: dholbert
diff --git a/css/css-values/absolute-length-units-001.html b/css/css-values/absolute-length-units-001.html
index ae20834..22b4390 100644
--- a/css/css-values/absolute-length-units-001.html
+++ b/css/css-values/absolute-length-units-001.html
@@ -14,30 +14,22 @@
     #t6 { width: 6pc; height: 72pt; }
     #t7 { width: 72pt; height: 96px; }
 </style>
-</head>
-<body>
-    <div id="t1"> </div>
-    <div id="t2"> </div>
-    <div id="t3"> </div>
-    <div id="t4"> </div>
-    <div id="t5"> </div>
-    <div id="t6"> </div>
-    <div id="t7"> </div>
 
-    <script type="text/javascript">
+<div id="t1"> </div>
+<div id="t2"> </div>
+<div id="t3"> </div>
+<div id="t4"> </div>
+<div id="t5"> </div>
+<div id="t6"> </div>
+<div id="t7"> </div>
 
-    var test_items = ["t1", "t2", "t3", "t4", "t5", "t6", "t7"]
+<script>
+  var test_items = ["t1", "t2", "t3", "t4", "t5", "t6", "t7"]
 
-    function getPropertyValue(id, property) {
-        var elem = document.getElementById(id);
-        return window.getComputedStyle(elem, null).getPropertyValue(property);
-    }
-
+  for (var i = 0; i < test_items.length; i++) {
     test(function(){
-        for (var i = 0; i < test_items.length; i++) {
-            assert_equals(getPropertyValue(test_items[i], "width"), getPropertyValue(test_items[i], "height"));
-        }
-    }, "all width and height should be same");
-    </script>
-</body>
-</html>
\ No newline at end of file
+      var elem = document.getElementById(test_items[i]);
+      assert_equals(getComputedStyle(elem).width, getComputedStyle(elem).height, elem.id);
+    }, test_items[i])
+  }
+</script>