Chromium Code Reviews| 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 245 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 256 testEvent(target.onScroll, 'scroll'); | 256 testEvent(target.onScroll, 'scroll'); |
| 257 testEvent(target.onSearch, 'search'); | 257 testEvent(target.onSearch, 'search'); |
| 258 testEvent(target.onSelect, 'select'); | 258 testEvent(target.onSelect, 'select'); |
| 259 testEvent(target.onSelectStart, 'selectstart'); | 259 testEvent(target.onSelectStart, 'selectstart'); |
| 260 testEvent(target.onSubmit, 'submit'); | 260 testEvent(target.onSubmit, 'submit'); |
| 261 testEvent(target.onTouchCancel, 'touchcancel'); | 261 testEvent(target.onTouchCancel, 'touchcancel'); |
| 262 testEvent(target.onTouchEnd, 'touchend'); | 262 testEvent(target.onTouchEnd, 'touchend'); |
| 263 testEvent(target.onTouchLeave, 'touchleave'); | 263 testEvent(target.onTouchLeave, 'touchleave'); |
| 264 testEvent(target.onTouchMove, 'touchmove'); | 264 testEvent(target.onTouchMove, 'touchmove'); |
| 265 testEvent(target.onTouchStart, 'touchstart'); | 265 testEvent(target.onTouchStart, 'touchstart'); |
| 266 testEvent(target.onTransitionEnd, 'webkitTransitionEnd'); | |
|
blois
2013/02/08 21:42:23
We should probably just remove all of these- they
| |
| 267 }); | 266 }); |
| 268 }); | 267 }); |
| 269 | 268 |
| 270 group('click', () { | 269 group('click', () { |
| 271 test('clickEvent', () { | 270 test('clickEvent', () { |
| 272 var e = new DivElement(); | 271 var e = new DivElement(); |
| 273 var firedEvent = false; | 272 var firedEvent = false; |
| 274 e.onClick.listen((event) { | 273 e.onClick.listen((event) { |
| 275 firedEvent = true; | 274 firedEvent = true; |
| 276 }); | 275 }); |
| (...skipping 353 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 630 }); | 629 }); |
| 631 | 630 |
| 632 test('getRange', () { | 631 test('getRange', () { |
| 633 var range = makeElList().getRange(1, 2); | 632 var range = makeElList().getRange(1, 2); |
| 634 expect(range, isElementList); | 633 expect(range, isElementList); |
| 635 expect(range[0], isImageElement); | 634 expect(range[0], isImageElement); |
| 636 expect(range[1], isInputElement); | 635 expect(range[1], isInputElement); |
| 637 }); | 636 }); |
| 638 }); | 637 }); |
| 639 } | 638 } |
| OLD | NEW |