OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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/test/base/chrome_render_view_test.h" | 5 #include "chrome/test/base/chrome_render_view_test.h" |
6 | 6 |
| 7 #include "base/debug/leak_annotations.h" |
7 #include "chrome/browser/extensions/extension_function_dispatcher.h" | 8 #include "chrome/browser/extensions/extension_function_dispatcher.h" |
8 #include "chrome/common/render_messages.h" | 9 #include "chrome/common/render_messages.h" |
9 #include "chrome/renderer/extensions/chrome_v8_context_set.h" | 10 #include "chrome/renderer/extensions/chrome_v8_context_set.h" |
10 #include "chrome/renderer/extensions/chrome_v8_extension.h" | 11 #include "chrome/renderer/extensions/chrome_v8_extension.h" |
11 #include "chrome/renderer/extensions/dispatcher.h" | 12 #include "chrome/renderer/extensions/dispatcher.h" |
12 #include "chrome/renderer/extensions/event_bindings.h" | 13 #include "chrome/renderer/extensions/event_bindings.h" |
13 #include "chrome/renderer/spellchecker/spellcheck.h" | 14 #include "chrome/renderer/spellchecker/spellcheck.h" |
14 #include "components/autofill/content/renderer/autofill_agent.h" | 15 #include "components/autofill/content/renderer/autofill_agent.h" |
15 #include "components/autofill/content/renderer/password_autofill_agent.h" | 16 #include "components/autofill/content/renderer/password_autofill_agent.h" |
16 #include "components/autofill/content/renderer/test_password_autofill_agent.h" | 17 #include "components/autofill/content/renderer/test_password_autofill_agent.h" |
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
68 password_autofill_ = new autofill::TestPasswordAutofillAgent(view_); | 69 password_autofill_ = new autofill::TestPasswordAutofillAgent(view_); |
69 password_generation_ = new autofill::TestPasswordGenerationAgent(view_); | 70 password_generation_ = new autofill::TestPasswordGenerationAgent(view_); |
70 autofill_agent_ = | 71 autofill_agent_ = |
71 new AutofillAgent(view_, password_autofill_, password_generation_); | 72 new AutofillAgent(view_, password_autofill_, password_generation_); |
72 } | 73 } |
73 | 74 |
74 void ChromeRenderViewTest::TearDown() { | 75 void ChromeRenderViewTest::TearDown() { |
75 extension_dispatcher_->OnRenderProcessShutdown(); | 76 extension_dispatcher_->OnRenderProcessShutdown(); |
76 extension_dispatcher_ = NULL; | 77 extension_dispatcher_ = NULL; |
77 | 78 |
| 79 #if defined(LEAK_SANITIZER) |
| 80 // Do this before shutting down V8 in RenderViewTest::TearDown(). |
| 81 // http://crbug.com/328552 |
| 82 __lsan_do_leak_check(); |
| 83 #endif |
78 content::RenderViewTest::TearDown(); | 84 content::RenderViewTest::TearDown(); |
79 } | 85 } |
OLD | NEW |