Pass process_priority from the StreamingProfile packets through to the JSON output
R=ssid@google.com
Bug:chromium:1065077
Change-Id: Ia73e9a744585a82c7c9f6a679ffedc2b77d3f56e
diff --git a/src/trace_processor/export_json_unittest.cc b/src/trace_processor/export_json_unittest.cc
index 4be5687..7b71563 100644
--- a/src/trace_processor/export_json_unittest.cc
+++ b/src/trace_processor/export_json_unittest.cc
@@ -1340,6 +1340,7 @@
const uint32_t kProcessID = 100;
const uint32_t kThreadID = 200;
const int64_t kTimestamp = 10000000;
+ const int32_t kProcessPriority = 42;
TraceStorage* storage = context_.storage.get();
@@ -1386,7 +1387,7 @@
callsites->Insert({1, frame_callsite_1.id, frame_2.id});
storage->mutable_cpu_profile_stack_sample_table()->Insert(
- {kTimestamp, frame_callsite_2.id, utid});
+ {kTimestamp, frame_callsite_2.id, utid, kProcessPriority});
base::TempFile temp_file = base::TempFile::Create();
FILE* output = fopen(temp_file.path().c_str(), "w+");
@@ -1408,6 +1409,7 @@
EXPECT_EQ(event["args"]["frames"].asString(),
"foo_func - foo_module_name [foo_module_id]\nbar_func - "
"bar_module_name [bar_module_id]\n");
+ EXPECT_EQ(event["args"]["process_priority"].asInt(), kProcessPriority);
}
TEST_F(ExportJsonTest, ArgumentFilter) {