12c3bcdd4d
Review URL: https://codereview.chromium.org//10947040 git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@12596 260f80e4-7a28-3924-810f-c04153c831b5
28 lines
703 B
Dart
28 lines
703 B
Dart
#library('ClientRectTest');
|
|
#import('../../pkg/unittest/unittest.dart');
|
|
#import('../../pkg/unittest/html_config.dart');
|
|
#import('dart:html');
|
|
|
|
main() {
|
|
|
|
insertTestDiv() {
|
|
var element = new Element.tag('div');
|
|
element.innerHTML = @'''
|
|
A large block of text should go here. Click this
|
|
block of text multiple times to see each line
|
|
highlight with every click of the mouse button.
|
|
''';
|
|
document.body.nodes.add(element);
|
|
return element;
|
|
}
|
|
|
|
useHtmlConfiguration();
|
|
|
|
test("ClientRectList test", () {
|
|
insertTestDiv();
|
|
var range = document.createRange();
|
|
List<ClientRect> rects = range.getClientRects();
|
|
Expect.isTrue(rects is List<ClientRect>);
|
|
});
|
|
}
|