| OLD | NEW |
| 1 <html> | 1 <html> |
| 2 <foo /> | 2 <foo /> |
| 3 <script> | 3 <script> |
| 4 import "../resources/third_party/unittest/unittest.dart"; | 4 import "../resources/third_party/unittest/unittest.dart"; |
| 5 import "../resources/unit.dart"; | 5 import "../resources/unit.dart"; |
| 6 | 6 |
| 7 import "dart:sky"; | 7 import "dart:sky"; |
| 8 | 8 |
| 9 void main() { | 9 void main() { |
| 10 initUnit(); | 10 initUnit(); |
| 11 | 11 |
| 12 test('should be settable using "style" attribute', () { | 12 test('should be settable using "style" attribute', () { |
| 13 var foo = document.querySelector('foo'); | 13 var foo = document.querySelector('foo'); |
| 14 foo.setAttribute('style', 'color: red'); | 14 foo.setAttribute('style', 'color: red'); |
| 15 | 15 |
| 16 | 16 |
| 17 expect(foo.getAttribute('style'), equals('color: red')); | 17 expect(foo.getAttribute('style'), equals('color: red')); |
| 18 expect(foo.style.getPropertyValue("color"), equals('rgb(255, 0, 0)')); | 18 expect(foo.style["color"], equals('rgb(255, 0, 0)')); |
| 19 expect(window.getComputedStyle(foo).getPropertyValue("color"), | 19 expect(window.getComputedStyle(foo)["color"], equals('rgb(255, 0, 0)')); |
| 20 equals('rgb(255, 0, 0)')); | |
| 21 }); | 20 }); |
| 22 } | 21 } |
| 23 </script> | 22 </script> |
| 24 </html> | 23 </html> |
| OLD | NEW |