summaryrefslogtreecommitdiff
path: root/cmds/statsd/tests/shell/ShellSubscriber_test.cpp
diff options
context:
space:
mode:
authorTej Singh <singhtejinder@google.com>2020-05-11 11:05:08 -0700
committerTej Singh <singhtejinder@google.com>2020-05-13 01:50:24 -0700
commit7b975a85db963e8e4a75fdaed13aec52a8d0f316 (patch)
treef4248cf4f8668cf2881f681ceb76b4f2cbb66636 /cmds/statsd/tests/shell/ShellSubscriber_test.cpp
parent1ecd4528fb3c07af3279428e1131909ad640b27d (diff)
Statsd: pull once per event time
If a pull happens at the same event time, we should reuse the existing data, regardless of whether or not the cool down has been met. For example, if an app upgrade happens at time t, and two metrics need to pull atom a, if metric one pulls at time t, but metric two initiates the pull at time t+2, we should still reuse the pull from time t since that is when the app upgrade happened. Bug: 156294650 Test: atest statsd_test Change-Id: I4efc49545093f6683bf6dd89ed68c5dfa5b44d8f
Diffstat (limited to 'cmds/statsd/tests/shell/ShellSubscriber_test.cpp')
-rw-r--r--cmds/statsd/tests/shell/ShellSubscriber_test.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/cmds/statsd/tests/shell/ShellSubscriber_test.cpp b/cmds/statsd/tests/shell/ShellSubscriber_test.cpp
index 363fcb4bf193..e384b6ac7c84 100644
--- a/cmds/statsd/tests/shell/ShellSubscriber_test.cpp
+++ b/cmds/statsd/tests/shell/ShellSubscriber_test.cpp
@@ -190,8 +190,8 @@ TEST(ShellSubscriberTest, testPulledSubscription) {
sp<MockStatsPullerManager> pullerManager = new StrictMock<MockStatsPullerManager>();
const vector<int32_t> uids = {AID_SYSTEM};
- EXPECT_CALL(*pullerManager, Pull(10016, uids, _, _))
- .WillRepeatedly(Invoke([](int tagId, const vector<int32_t>&,
+ EXPECT_CALL(*pullerManager, Pull(10016, uids, _, _, _))
+ .WillRepeatedly(Invoke([](int tagId, const vector<int32_t>&, const int64_t,
vector<std::shared_ptr<LogEvent>>* data, bool) {
data->clear();
data->push_back(makeCpuActiveTimeAtom(/*uid=*/kUid1, /*timeMillis=*/kCpuTime1));