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

Side by Side Diff: runtime/vm/object_test.cc

Issue 1154163004: Libraries have uris not urls. Scripts have uris not names. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: sync Created 5 years, 6 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 | « runtime/vm/object.cc ('k') | runtime/vm/report_test.cc » ('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 #include "platform/globals.h" 5 #include "platform/globals.h"
6 6
7 #include "vm/assembler.h" 7 #include "vm/assembler.h"
8 #include "vm/class_finalizer.h" 8 #include "vm/class_finalizer.h"
9 #include "vm/dart_api_impl.h" 9 #include "vm/dart_api_impl.h"
10 #include "vm/dart_entry.h" 10 #include "vm/dart_entry.h"
(...skipping 4322 matching lines...) Expand 10 before | Expand all | Expand 10 after
4333 buffer); 4333 buffer);
4334 } 4334 }
4335 // Library reference 4335 // Library reference
4336 { 4336 {
4337 JSONStream js; 4337 JSONStream js;
4338 Library& lib = Library::Handle(isolate->object_store()->core_library()); 4338 Library& lib = Library::Handle(isolate->object_store()->core_library());
4339 lib.PrintJSON(&js, true); 4339 lib.PrintJSON(&js, true);
4340 elideSubstring("libraries", js.ToCString(), buffer); 4340 elideSubstring("libraries", js.ToCString(), buffer);
4341 EXPECT_STREQ( 4341 EXPECT_STREQ(
4342 "{\"type\":\"@Library\",\"id\":\"\",\"name\":\"dart.core\"," 4342 "{\"type\":\"@Library\",\"id\":\"\",\"name\":\"dart.core\","
4343 "\"url\":\"dart:core\"}", 4343 "\"uri\":\"dart:core\"}",
4344 buffer); 4344 buffer);
4345 } 4345 }
4346 // Bool reference 4346 // Bool reference
4347 { 4347 {
4348 JSONStream js; 4348 JSONStream js;
4349 Bool::True().PrintJSON(&js, true); 4349 Bool::True().PrintJSON(&js, true);
4350 elideSubstring("classes", js.ToCString(), buffer); 4350 elideSubstring("classes", js.ToCString(), buffer);
4351 EXPECT_STREQ( 4351 EXPECT_STREQ(
4352 "{\"type\":\"@bool\"," 4352 "{\"type\":\"@bool\","
4353 "\"class\":{\"type\":\"@Class\",\"id\":\"\",\"name\":\"bool\"}," 4353 "\"class\":{\"type\":\"@Class\",\"id\":\"\",\"name\":\"bool\"},"
(...skipping 239 matching lines...) Expand 10 before | Expand all | Expand 10 after
4593 EXPECT_VALID(h_result); 4593 EXPECT_VALID(h_result);
4594 Integer& result = Integer::Handle(); 4594 Integer& result = Integer::Handle();
4595 result ^= Api::UnwrapHandle(h_result); 4595 result ^= Api::UnwrapHandle(h_result);
4596 String& foo = String::Handle(String::New("foo")); 4596 String& foo = String::Handle(String::New("foo"));
4597 Integer& expected = Integer::Handle(); 4597 Integer& expected = Integer::Handle();
4598 expected ^= foo.HashCode(); 4598 expected ^= foo.HashCode();
4599 EXPECT(result.IsIdenticalTo(expected)); 4599 EXPECT(result.IsIdenticalTo(expected));
4600 } 4600 }
4601 4601
4602 } // namespace dart 4602 } // namespace dart
OLDNEW
« no previous file with comments | « runtime/vm/object.cc ('k') | runtime/vm/report_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698