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

Side by Side Diff: mojo/public/js/struct_unittests.js

Issue 830673002: Mojo Windows: test_structs.mojom C++ bindings don't compile (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: Added a comment about tests ignoring V10 Created 5 years, 11 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
« no previous file with comments | « mojo/public/js/codec_unittests.js ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 define([ 5 define([
6 "gin/test/expect", 6 "gin/test/expect",
7 "mojo/public/interfaces/bindings/tests/rect.mojom", 7 "mojo/public/interfaces/bindings/tests/rect.mojom",
8 "mojo/public/interfaces/bindings/tests/test_structs.mojom", 8 "mojo/public/interfaces/bindings/tests/test_structs.mojom",
9 "mojo/public/js/codec", 9 "mojo/public/js/codec",
10 "mojo/public/js/validator", 10 "mojo/public/js/validator",
(...skipping 171 matching lines...) Expand 10 before | Expand all | Expand 10 after
182 expect(decodedStruct.f3).toEqual(testStructs.FloatNumberValues.V3); 182 expect(decodedStruct.f3).toEqual(testStructs.FloatNumberValues.V3);
183 expect(decodedStruct.f4).toEqual(testStructs.FloatNumberValues.V4); 183 expect(decodedStruct.f4).toEqual(testStructs.FloatNumberValues.V4);
184 expect(decodedStruct.f5).toEqual(testStructs.FloatNumberValues.V5); 184 expect(decodedStruct.f5).toEqual(testStructs.FloatNumberValues.V5);
185 expect(decodedStruct.f6).toEqual(testStructs.FloatNumberValues.V6); 185 expect(decodedStruct.f6).toEqual(testStructs.FloatNumberValues.V6);
186 expect(decodedStruct.f7).toEqual(testStructs.FloatNumberValues.V7); 186 expect(decodedStruct.f7).toEqual(testStructs.FloatNumberValues.V7);
187 expect(decodedStruct.f8).toEqual(testStructs.FloatNumberValues.V8); 187 expect(decodedStruct.f8).toEqual(testStructs.FloatNumberValues.V8);
188 expect(decodedStruct.f9).toEqual(testStructs.FloatNumberValues.V9); 188 expect(decodedStruct.f9).toEqual(testStructs.FloatNumberValues.V9);
189 } 189 }
190 190
191 function testIntegerNumberValues() { 191 function testIntegerNumberValues() {
192 var decodedStruct = structEncodeDecode(new testStructs.IntegerNumberValues); 192 var minInt32 = -2147483648; // See crbug.com/445618
193 var decodedStruct = structEncodeDecode(
194 new testStructs.IntegerNumberValues({f10: minInt32}));
193 expect(decodedStruct.f0).toEqual(testStructs.IntegerNumberValues.V0); 195 expect(decodedStruct.f0).toEqual(testStructs.IntegerNumberValues.V0);
194 expect(decodedStruct.f1).toEqual(testStructs.IntegerNumberValues.V1); 196 expect(decodedStruct.f1).toEqual(testStructs.IntegerNumberValues.V1);
195 expect(decodedStruct.f2).toEqual(testStructs.IntegerNumberValues.V2); 197 expect(decodedStruct.f2).toEqual(testStructs.IntegerNumberValues.V2);
196 expect(decodedStruct.f3).toEqual(testStructs.IntegerNumberValues.V3); 198 expect(decodedStruct.f3).toEqual(testStructs.IntegerNumberValues.V3);
197 expect(decodedStruct.f4).toEqual(testStructs.IntegerNumberValues.V4); 199 expect(decodedStruct.f4).toEqual(testStructs.IntegerNumberValues.V4);
198 expect(decodedStruct.f5).toEqual(testStructs.IntegerNumberValues.V5); 200 expect(decodedStruct.f5).toEqual(testStructs.IntegerNumberValues.V5);
199 expect(decodedStruct.f6).toEqual(testStructs.IntegerNumberValues.V6); 201 expect(decodedStruct.f6).toEqual(testStructs.IntegerNumberValues.V6);
200 expect(decodedStruct.f7).toEqual(testStructs.IntegerNumberValues.V7); 202 expect(decodedStruct.f7).toEqual(testStructs.IntegerNumberValues.V7);
201 expect(decodedStruct.f8).toEqual(testStructs.IntegerNumberValues.V8); 203 expect(decodedStruct.f8).toEqual(testStructs.IntegerNumberValues.V8);
202 expect(decodedStruct.f9).toEqual(testStructs.IntegerNumberValues.V9); 204 expect(decodedStruct.f9).toEqual(testStructs.IntegerNumberValues.V9);
203 expect(decodedStruct.f10).toEqual(testStructs.IntegerNumberValues.V10); 205 expect(decodedStruct.f10).toEqual(minInt32);
204 expect(decodedStruct.f11).toEqual(testStructs.IntegerNumberValues.V11); 206 expect(decodedStruct.f11).toEqual(testStructs.IntegerNumberValues.V11);
205 expect(decodedStruct.f12).toEqual(testStructs.IntegerNumberValues.V12); 207 expect(decodedStruct.f12).toEqual(testStructs.IntegerNumberValues.V12);
206 expect(decodedStruct.f13).toEqual(testStructs.IntegerNumberValues.V13); 208 expect(decodedStruct.f13).toEqual(testStructs.IntegerNumberValues.V13);
207 expect(decodedStruct.f14).toEqual(testStructs.IntegerNumberValues.V14); 209 expect(decodedStruct.f14).toEqual(testStructs.IntegerNumberValues.V14);
208 expect(decodedStruct.f15).toEqual(testStructs.IntegerNumberValues.V15); 210 expect(decodedStruct.f15).toEqual(testStructs.IntegerNumberValues.V15);
209 expect(decodedStruct.f16).toEqual(testStructs.IntegerNumberValues.V16); 211 expect(decodedStruct.f16).toEqual(testStructs.IntegerNumberValues.V16);
210 expect(decodedStruct.f17).toEqual(testStructs.IntegerNumberValues.V17); 212 expect(decodedStruct.f17).toEqual(testStructs.IntegerNumberValues.V17);
211 expect(decodedStruct.f18).toEqual(testStructs.IntegerNumberValues.V18); 213 expect(decodedStruct.f18).toEqual(testStructs.IntegerNumberValues.V18);
212 expect(decodedStruct.f19).toEqual(testStructs.IntegerNumberValues.V19); 214 expect(decodedStruct.f19).toEqual(testStructs.IntegerNumberValues.V19);
213 } 215 }
(...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after
262 testDefaultFieldValues(); 264 testDefaultFieldValues();
263 testScopedConstants(); 265 testScopedConstants();
264 testMapKeyTypes(); 266 testMapKeyTypes();
265 testMapValueTypes(); 267 testMapValueTypes();
266 testFloatNumberValues(); 268 testFloatNumberValues();
267 testIntegerNumberValues(); 269 testIntegerNumberValues();
268 testUnsignedNumberValues(); 270 testUnsignedNumberValues();
269 testBitArrayValues(); 271 testBitArrayValues();
270 this.result = "PASS"; 272 this.result = "PASS";
271 }); 273 });
OLDNEW
« no previous file with comments | « mojo/public/js/codec_unittests.js ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698