|
1 <html xmlns="http://www.w3.org/1999/xhtml"> |
|
2 <!-- |
|
3 https://bugzilla.mozilla.org/show_bug.cgi?id=542406 |
|
4 --> |
|
5 <head> |
|
6 <bindings xmlns="http://www.mozilla.org/xbl"> |
|
7 <binding id="foo"> |
|
8 <content><children/></content> |
|
9 <implementation> |
|
10 <field name="one" readonly="true">1</field> |
|
11 <field name="three">3</field> |
|
12 </implementation> |
|
13 </binding> |
|
14 </bindings> |
|
15 <title>Test for Bug 542406</title> |
|
16 <script type="application/javascript" src="/tests/SimpleTest/SimpleTest.js"></script> |
|
17 <link rel="stylesheet" type="text/css" href="/tests/SimpleTest/test.css"/> |
|
18 </head> |
|
19 <body> |
|
20 <a target="_blank" href="https://bugzilla.mozilla.org/show_bug.cgi?id=542406">Mozilla Bug 542406</a> |
|
21 <p id="display" style="-moz-binding: url(#foo)"></p> |
|
22 <div id="content" style="display: none"> |
|
23 |
|
24 </div> |
|
25 <pre id="test"> |
|
26 <script type="application/javascript"> |
|
27 <![CDATA[ |
|
28 |
|
29 /** Test for Bug 542406 **/ |
|
30 SimpleTest.waitForExplicitFinish(); |
|
31 addLoadEvent(function() { |
|
32 is($("display").one, 1, "Field one not installed?"); |
|
33 $("display").one = 2; |
|
34 is($("display").one, 1, "Field one not readonly"); |
|
35 is($("display").three, 3, "Field three not installed?"); |
|
36 $("display").three = 4; |
|
37 is($("display").three, 4, "Field three readonly?"); |
|
38 SimpleTest.finish(); |
|
39 }); |
|
40 ]]> |
|
41 </script> |
|
42 </pre> |
|
43 </body> |
|
44 </html> |