mirror of
https://github.com/dart-lang/sdk
synced 2024-09-21 13:41:18 +00:00
Fix get_cpu_profile_timeline_rpc_test.
AddProperty64 encodes as a JSON integer, not a JSON string. R=johnmccutchan@google.com Review URL: https://codereview.chromium.org/1535513002 .
This commit is contained in:
parent
ac170168dd
commit
55a22037fb
|
@ -31,6 +31,7 @@ var tests = [
|
|||
expect(result['type'], equals('_CpuProfileTimeline'));
|
||||
|
||||
var isString = new isInstanceOf<String>();
|
||||
var isInt = new isInstanceOf<int>();
|
||||
|
||||
Map frames = result['stackFrames'];
|
||||
for (Map frame in frames.values) {
|
||||
|
@ -44,9 +45,9 @@ var tests = [
|
|||
List events = result['traceEvents'];
|
||||
for (Map event in events) {
|
||||
expect(event['ph'], equals('P'));
|
||||
expect(event['pid'], isString);
|
||||
expect(event['tid'], isString);
|
||||
expect(event['ts'], isString);
|
||||
expect(event['pid'], isInt);
|
||||
expect(event['tid'], isInt);
|
||||
expect(event['ts'], isInt);
|
||||
expect(event['category'], equals("Dart"));
|
||||
expect(frames.containsKey(event['sf']), isTrue);
|
||||
}
|
||||
|
|
|
@ -3242,7 +3242,7 @@ void Service::PrintJSONForVM(JSONStream* js, bool ref) {
|
|||
jsobj.AddProperty("targetCPU", CPU::Id());
|
||||
jsobj.AddProperty("hostCPU", HostCPUFeatures::hardware());
|
||||
jsobj.AddProperty("version", Version::String());
|
||||
jsobj.AddProperty("pid", OS::ProcessId());
|
||||
jsobj.AddProperty64("pid", OS::ProcessId());
|
||||
int64_t start_time_millis = (vm_isolate->start_time() /
|
||||
kMicrosecondsPerMillisecond);
|
||||
jsobj.AddPropertyTimeMillis("startTime", start_time_millis);
|
||||
|
|
Loading…
Reference in a new issue