DXR is a code search and navigation tool aimed at making sense of large projects. It supports full-text and regex searches as well as structural queries.

Mercurial (b6057e17f856)

VCS Links

Line Code
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26
<!DOCTYPE html>
<html>
<!--
https://bugzilla.mozilla.org/show_bug.cgi?id=798567
-->
<head>
  <title>Test for Bug 798567</title>
  <script type="application/javascript" src="/tests/SimpleTest/SimpleTest.js"></script>
  <link rel="stylesheet" type="text/css" href="/tests/SimpleTest/test.css"/>
</head>
<body>
  <div id="some_div"  style="opacity: 0.5">bar</div>
  <div style="cursor: crosshair" id="div_cursor">foobar</div>
  <script type="application/javascript">
    var elm = document.getElementById("some_div");
    var cs = getComputedStyle(elm);
    var cssValue = cs.getPropertyCSSValue("opacity");
    is(cssValue.getFloatValue(CSSPrimitiveValue.CSS_NUMBER), 0.5, "wrong opacity of some_div");

    elm = document.getElementById("div_cursor");
    cs = getComputedStyle(elm);
    cssValue = cs.getPropertyCSSValue("cursor");
    ok(cssValue[0], "element with set cursor should have a a computed style");
  </script>
</body>
</html>