OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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/sessions/session_restore_stats_collector.h" | 5 #include "chrome/browser/sessions/session_restore_stats_collector.h" |
6 | 6 |
| 7 #include <stddef.h> |
| 8 |
| 9 #include "base/macros.h" |
7 #include "base/message_loop/message_loop.h" | 10 #include "base/message_loop/message_loop.h" |
8 #include "base/test/simple_test_tick_clock.h" | 11 #include "base/test/simple_test_tick_clock.h" |
9 #include "chrome/test/base/testing_profile.h" | 12 #include "chrome/test/base/testing_profile.h" |
10 #include "content/public/browser/notification_service.h" | 13 #include "content/public/browser/notification_service.h" |
11 #include "content/public/browser/notification_types.h" | 14 #include "content/public/browser/notification_types.h" |
12 #include "content/public/browser/render_widget_host.h" | 15 #include "content/public/browser/render_widget_host.h" |
13 #include "content/public/browser/render_widget_host_view.h" | 16 #include "content/public/browser/render_widget_host_view.h" |
14 #include "content/public/browser/web_contents.h" | 17 #include "content/public/browser/web_contents.h" |
15 #include "content/public/test/test_browser_thread.h" | 18 #include "content/public/test/test_browser_thread.h" |
16 #include "content/public/test/test_web_contents_factory.h" | 19 #include "content/public/test/test_web_contents_factory.h" |
(...skipping 610 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
627 mock_reporting_delegate.ExpectReportTabLoaderStatsCalled(2, 1, 1, 0, 0, 0, 0, | 630 mock_reporting_delegate.ExpectReportTabLoaderStatsCalled(2, 1, 1, 0, 0, 0, 0, |
628 1); | 631 1); |
629 mock_reporting_delegate.EnsureNoUnexpectedCalls(); | 632 mock_reporting_delegate.EnsureNoUnexpectedCalls(); |
630 | 633 |
631 // Destroy the background tab. The collector should release itself. | 634 // Destroy the background tab. The collector should release itself. |
632 Tick(); // 3 ms. | 635 Tick(); // 3 ms. |
633 GenerateWebContentsDestroyed(1); | 636 GenerateWebContentsDestroyed(1); |
634 mock_reporting_delegate.ExpectReportStatsCollectorDeathCalled(); | 637 mock_reporting_delegate.ExpectReportStatsCollectorDeathCalled(); |
635 mock_reporting_delegate.EnsureNoUnexpectedCalls(); | 638 mock_reporting_delegate.EnsureNoUnexpectedCalls(); |
636 } | 639 } |
OLD | NEW |