summaryrefslogtreecommitdiffstats
path: root/chrome/renderer
diff options
context:
space:
mode:
authorbryner@chromium.org <bryner@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-08-06 01:34:38 +0000
committerbryner@chromium.org <bryner@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-08-06 01:34:38 +0000
commitc5281ffa30138fee2700ac283bd1c840ab3b7dd4 (patch)
tree187bd80ccd544dec0a52bcfd2c6d847867084c64 /chrome/renderer
parent940e621e882a1fc0ddf641d8b3ed35f75d1b5cd0 (diff)
downloadchromium_src-c5281ffa30138fee2700ac283bd1c840ab3b7dd4.zip
chromium_src-c5281ffa30138fee2700ac283bd1c840ab3b7dd4.tar.gz
chromium_src-c5281ffa30138fee2700ac283bd1c840ab3b7dd4.tar.bz2
One more PhishingDOMFeatureExtractorTest suppression, for the IPC channel name.
BUG=50598 TEST=tools/heapcheck/chrome_tests.sh -t unit --gtest_filter=PhishingDOM* Review URL: http://codereview.chromium.org/3092010 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@55174 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/renderer')
-rw-r--r--chrome/renderer/safe_browsing/phishing_dom_feature_extractor_unittest.cc18
1 files changed, 11 insertions, 7 deletions
diff --git a/chrome/renderer/safe_browsing/phishing_dom_feature_extractor_unittest.cc b/chrome/renderer/safe_browsing/phishing_dom_feature_extractor_unittest.cc
index d307134..a841963 100644
--- a/chrome/renderer/safe_browsing/phishing_dom_feature_extractor_unittest.cc
+++ b/chrome/renderer/safe_browsing/phishing_dom_feature_extractor_unittest.cc
@@ -69,13 +69,7 @@ class PhishingDOMFeatureExtractorTest : public ::testing::Test,
platform_.reset(new RendererMainPlatformDelegate(*params_));
platform_->PlatformInitialize();
- // We use a new IPC channel name for each test that runs.
- // This is necessary because the renderer-side IPC channel is not
- // shut down when the RenderThread goes away, so attempting to reuse
- // the channel name gives an error (see ChildThread::~ChildThread()).
- std::string thread_name = StringPrintf(
- "phishing_dom_feature_Extractor_unittest.%d",
- next_thread_id_++);
+ std::string thread_name = GetNextThreadName();
channel_.reset(new IPC::Channel(thread_name,
IPC::Channel::MODE_SERVER, this));
ASSERT_TRUE(channel_->Connect());
@@ -206,6 +200,16 @@ class PhishingDOMFeatureExtractorTest : public ::testing::Test,
msg_loop_.Quit();
}
+ // We use a new IPC channel name for each test that runs.
+ // This is necessary because the renderer-side IPC channel is not
+ // shut down when the RenderThread goes away, so attempting to reuse
+ // the channel name gives an error (see ChildThread::~ChildThread()).
+ static std::string GetNextThreadName() {
+ return StringPrintf(
+ "phishing_dom_feature_Extractor_unittest.%d",
+ next_thread_id_++);
+ }
+
static int next_thread_id_; // incrementing counter for thread ids
static const int32 kViewId = 5; // arbitrary id for our testing view