Chromium Code Reviews| Index: test/data/input/component_field_2way_test.html |
| diff --git a/test/data/input/component_field_2way_test.html b/test/data/input/component_field_2way_test.html |
| index 52be12870653ac032b797db54eb45b8a828e34fc..b9c0f5615629236ed84bab04d0fd1d959cefabf7 100644 |
| --- a/test/data/input/component_field_2way_test.html |
| +++ b/test/data/input/component_field_2way_test.html |
| @@ -16,11 +16,18 @@ |
| <template></template> |
| <script type='application/dart'> |
| import 'package:web_ui/web_ui.dart'; |
| + @observable |
| class Greeter extends WebComponent { |
| String greetIng; |
| + |
| + // TODO(jmesserly): original test was testing for the "title" DOM |
| + // property. Unfortunately it can't be observed, so we'll use |
| + // a different property. |
|
Siggi Cherem (dart-lang)
2013/02/13 19:28:54
strange, because the purpose of 'title' in this te
Jennifer Messerly
2013/02/13 20:21:20
We do have another test verifying that you can bin
|
| + String title2; |
| + |
| changeStuff() { |
| greetIng = 'Yo dawg'; |
| - title = 'I heard you like $title so we put $title in yo $title.'; |
| + title2 = 'I heard you like $title2 so we put $title2 in yo $title2.'; |
| } |
| } |
| </script> |
| @@ -30,7 +37,7 @@ |
| </p> |
| <!-- Note: "title" is a DOM field on all elements. |
| Also this element has no rendering. --> |
| - <x-greeter id="greet" bind-title="data[1]" bind-greet-ing="data[0]"> |
| + <x-greeter id="greet" bind-title2="data[1]" bind-greet-ing="data[0]"> |
| </x-greeter> |
| <p id="actual">{{data[0]}} {{data[1]}}</p> |
| <script type="application/dart"> |
| @@ -38,14 +45,15 @@ |
| import 'package:unittest/unittest.dart'; |
| import 'package:web_ui/web_ui.dart'; |
| - var data = ['hello', 'world']; |
| + final data = new ObservableList.from(['hello', 'world']); |
| + |
| main() { |
| window.setTimeout(() { |
| var actual = query('#actual'); |
| var greet = query('#greet'); |
| expect(actual.innerHtml, 'hello world'); |
| greet.xtag.changeStuff(); |
| - dispatch(); |
| + deliverChangesSync(); |
| expect(actual.innerHtml, contains('Yo dawg I heard')); |
| window.postMessage('done', '*'); |
| }, 0); |