| OLD | NEW |
| 1 // Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file |
| 2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
| 3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
| 4 | 4 |
| 5 library ElementTest; | 5 library ElementTest; |
| 6 import '../../pkg/unittest/lib/unittest.dart'; | 6 import '../../pkg/unittest/lib/unittest.dart'; |
| 7 import '../../pkg/unittest/lib/html_individual_config.dart'; | 7 import '../../pkg/unittest/lib/html_individual_config.dart'; |
| 8 import 'dart:async'; | 8 import 'dart:async'; |
| 9 import 'dart:html'; | 9 import 'dart:html'; |
| 10 import 'dart:svg' as svg; | 10 import 'dart:svg' as svg; |
| (...skipping 600 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 611 testUnsupported('insertangeRange', () => getQueryAll().insertRange(0, 1)); | 611 testUnsupported('insertangeRange', () => getQueryAll().insertRange(0, 1)); |
| 612 | 612 |
| 613 testUnsupported('clear', () => getQueryAll().clear()); | 613 testUnsupported('clear', () => getQueryAll().clear()); |
| 614 | 614 |
| 615 testUnsupported('removeLast', () => getQueryAll().removeLast()); | 615 testUnsupported('removeLast', () => getQueryAll().removeLast()); |
| 616 }); | 616 }); |
| 617 | 617 |
| 618 group('functional', () { | 618 group('functional', () { |
| 619 test('toString', () { | 619 test('toString', () { |
| 620 final elems = makeElementWithChildren().children; | 620 final elems = makeElementWithChildren().children; |
| 621 expect(elems.toString(), "[BR, IMG, INPUT]"); | 621 expect(elems.toString(), "[br, img, input]"); |
| 622 final elem = makeElement().children; | 622 final elem = makeElement().children; |
| 623 expect(elem.toString(), '[]'); | 623 expect(elem.toString(), '[]'); |
| 624 }); | 624 }); |
| 625 | 625 |
| 626 test('scrollIntoView', () { | 626 test('scrollIntoView', () { |
| 627 var child = new DivElement(); | 627 var child = new DivElement(); |
| 628 document.body.append(child); | 628 document.body.append(child); |
| 629 | 629 |
| 630 child.scrollIntoView(ScrollAlignment.TOP); | 630 child.scrollIntoView(ScrollAlignment.TOP); |
| 631 child.scrollIntoView(ScrollAlignment.BOTTOM); | 631 child.scrollIntoView(ScrollAlignment.BOTTOM); |
| (...skipping 13 matching lines...) Expand all Loading... |
| 645 }); | 645 }); |
| 646 | 646 |
| 647 test('sublist', () { | 647 test('sublist', () { |
| 648 var range = makeElList().sublist(1, 3); | 648 var range = makeElList().sublist(1, 3); |
| 649 expect(range, isElementList); | 649 expect(range, isElementList); |
| 650 expect(range[0], isImageElement); | 650 expect(range[0], isImageElement); |
| 651 expect(range[1], isInputElement); | 651 expect(range[1], isInputElement); |
| 652 }); | 652 }); |
| 653 }); | 653 }); |
| 654 } | 654 } |
| OLD | NEW |