| OLD | NEW | 
|---|
| 1 // Copyright (c) 2013, the Dart project authors.  Please see the AUTHORS file | 1 // Copyright (c) 2013, 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 attribute_changed_callback_test; | 5 library attribute_changed_callback_test; | 
| 6 | 6 | 
| 7 import 'dart:html'; | 7 import 'dart:html'; | 
| 8 import 'dart:js' as js; | 8 import 'dart:js' as js; | 
| 9 import 'package:unittest/html_individual_config.dart'; | 9 import 'package:unittest/html_individual_config.dart'; | 
| 10 import 'package:unittest/unittest.dart'; | 10 import 'package:unittest/unittest.dart'; | 
| (...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 77       b.attributes['data-v'] = 'x'; | 77       b.attributes['data-v'] = 'x'; | 
| 78       expect(B.invocations, ['data-v: w => x']); | 78       expect(B.invocations, ['data-v: w => x']); | 
| 79 | 79 | 
| 80       B.invocations = []; | 80       B.invocations = []; | 
| 81       b.attributes['data-v'] = 'x'; | 81       b.attributes['data-v'] = 'x'; | 
| 82       expect(B.invocations, []); | 82       expect(B.invocations, []); | 
| 83 | 83 | 
| 84       b.attributes.remove('data-v'); | 84       b.attributes.remove('data-v'); | 
| 85       expect(B.invocations, ['data-v: x => null']); | 85       expect(B.invocations, ['data-v: x => null']); | 
| 86     }); | 86     }); | 
| 87   }); |  | 
| 88 | 87 | 
| 89   group('unsupported_on_polyfill', () { |  | 
| 90     test('add, change ID', () { | 88     test('add, change ID', () { | 
| 91       B.invocations = []; | 89       B.invocations = []; | 
| 92 | 90 | 
| 93       var b = new B(); | 91       var b = new B(); | 
| 94       b.id = 'x'; | 92       b.id = 'x'; | 
| 95       expect(B.invocations, ['created', 'id: null => x']); | 93       expect(B.invocations, ['created', 'id: null => x']); | 
| 96 | 94 | 
| 97       B.invocations = []; | 95       B.invocations = []; | 
| 98       b.attributes.remove('id'); | 96       b.attributes.remove('id'); | 
| 99       expect(B.invocations, ['id: x => null']); | 97       expect(B.invocations, ['id: x => null']); | 
| 100     }); | 98     }); | 
|  | 99   }); | 
|  | 100 | 
|  | 101   group('unsupported_on_polyfill', () { | 
|  | 102 | 
|  | 103     // If these tests start passing, don't remove the status suppression. Move | 
|  | 104     // the tests to the fullYy_supported group. | 
| 101 | 105 | 
| 102     test('add, change classes', () { | 106     test('add, change classes', () { | 
| 103       var b = new B(); | 107       var b = new B(); | 
| 104 | 108 | 
| 105       B.invocations = []; | 109       B.invocations = []; | 
| 106       b.classes.toggle('u'); | 110       b.classes.toggle('u'); | 
| 107       expect(B.invocations, ['class: null => u']); | 111       expect(B.invocations, ['class: null => u']); | 
| 108     }); | 112     }); | 
| 109   }); | 113   }); | 
| 110 } | 114 } | 
| OLD | NEW | 
|---|