OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 #include "chrome/browser/extensions/activity_log/fullstream_ui_policy.h" | 5 #include "chrome/browser/extensions/activity_log/fullstream_ui_policy.h" |
6 | 6 |
7 #include <stdint.h> | 7 #include <stdint.h> |
8 | 8 |
9 #include <memory> | 9 #include <memory> |
10 #include <utility> | 10 #include <utility> |
(...skipping 805 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
816 scoped_refptr<Action> action = | 816 scoped_refptr<Action> action = |
817 new Action("punky", | 817 new Action("punky", |
818 base::Time::Now(), | 818 base::Time::Now(), |
819 Action::ACTION_API_CALL, | 819 Action::ACTION_API_CALL, |
820 base::StringPrintf("apicall_%d", i)); | 820 base::StringPrintf("apicall_%d", i)); |
821 policy->ProcessAction(action); | 821 policy->ProcessAction(action); |
822 } | 822 } |
823 | 823 |
824 policy->Flush(); | 824 policy->Flush(); |
825 BrowserThread::PostTaskAndReply( | 825 BrowserThread::PostTaskAndReply( |
826 BrowserThread::DB, FROM_HERE, base::Bind(&base::DoNothing), | 826 BrowserThread::DB, FROM_HERE, base::BindOnce(&base::DoNothing), |
827 base::MessageLoop::current()->QuitWhenIdleClosure()); | 827 base::MessageLoop::current()->QuitWhenIdleClosure()); |
828 base::RunLoop().Run(); | 828 base::RunLoop().Run(); |
829 | 829 |
830 CheckReadFilteredData( | 830 CheckReadFilteredData( |
831 policy, | 831 policy, |
832 "punky", | 832 "punky", |
833 Action::ACTION_ANY, | 833 Action::ACTION_ANY, |
834 "", | 834 "", |
835 "", | 835 "", |
836 "", | 836 "", |
(...skipping 104 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
941 action_ids.push_back(3); | 941 action_ids.push_back(3); |
942 action_ids.push_back(4); | 942 action_ids.push_back(4); |
943 CheckRemoveActions( | 943 CheckRemoveActions( |
944 policy, action_ids, base::Bind(&FullStreamUIPolicyTest::Action2Deleted)); | 944 policy, action_ids, base::Bind(&FullStreamUIPolicyTest::Action2Deleted)); |
945 action_ids.clear(); | 945 action_ids.clear(); |
946 | 946 |
947 policy->Close(); | 947 policy->Close(); |
948 } | 948 } |
949 | 949 |
950 } // namespace extensions | 950 } // namespace extensions |
OLD | NEW |