Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(195)

Side by Side Diff: tests/html/postmessage_structured_test.dart

Issue 296153013: Fixing iframe.contentWindow.postMessage passing incorrect data (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 6 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « sdk/lib/html/dart2js/html_dart2js.dart ('k') | tools/dom/src/dart2js_DOMImplementation.dart » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, 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 postmessage_js_test; 5 library postmessage_js_test;
6 import 'package:unittest/unittest.dart'; 6 import 'package:unittest/unittest.dart';
7 import 'package:unittest/html_individual_config.dart'; 7 import 'package:unittest/html_individual_config.dart';
8 import 'dart:html'; 8 import 'dart:html';
9 import 'dart:collection'; // SplayTreeMap 9 import 'dart:collection'; // SplayTreeMap
10 import 'dart:typed_data'; 10 import 'dart:typed_data';
(...skipping 131 matching lines...) Expand 10 before | Expand all | Expand 10 after
142 var view_b = new Uint8List.view(array_buffer, 1, 13); 142 var view_b = new Uint8List.view(array_buffer, 1, 13);
143 var typed_arrays_list = [view_a, array_buffer, view_b]; 143 var typed_arrays_list = [view_a, array_buffer, view_b];
144 144
145 // Note that FF is failing this test because in the sent message: 145 // Note that FF is failing this test because in the sent message:
146 // view_a.buffer == array_buffer 146 // view_a.buffer == array_buffer
147 // But in the response: 147 // But in the response:
148 // view_a.buffer != array_buffer 148 // view_a.buffer != array_buffer
149 go('typed_arrays_list', typed_arrays_list); 149 go('typed_arrays_list', typed_arrays_list);
150 }); 150 });
151 151
152 group('iframe', () {
153 test('postMessage clones data', () {
154 var iframe = new IFrameElement();
155 var future = iframe.onLoad.first.then((_) {
156 iframe.contentWindow.postMessage(new HashMap<String,num>(), '*');
157 });
158 iframe.src = 'about:blank';
159 document.body.append(iframe);
160
161 return future;
162 });
163 });
164
152 } 165 }
OLDNEW
« no previous file with comments | « sdk/lib/html/dart2js/html_dart2js.dart ('k') | tools/dom/src/dart2js_DOMImplementation.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698