Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(65)

Side by Side Diff: chrome/browser/ui/webui/theme_source_unittest.cc

Issue 8477004: Have content/ create and destroy its own threads. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: More IWYU, missing link-time dependency for Chrome Frame. Created 9 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 "base/memory/ref_counted_memory.h" 5 #include "base/memory/ref_counted_memory.h"
6 #include "base/message_loop.h"
6 #include "chrome/browser/profiles/profile.h" 7 #include "chrome/browser/profiles/profile.h"
7 #include "chrome/browser/ui/webui/theme_source.h" 8 #include "chrome/browser/ui/webui/theme_source.h"
8 #include "chrome/common/url_constants.h" 9 #include "chrome/common/url_constants.h"
9 #include "chrome/test/base/testing_profile.h" 10 #include "chrome/test/base/testing_profile.h"
10 #include "content/test/test_browser_thread.h" 11 #include "content/test/test_browser_thread.h"
11 #include "grit/theme_resources.h" 12 #include "grit/theme_resources.h"
12 #include "grit/theme_resources_standard.h" 13 #include "grit/theme_resources_standard.h"
13 #include "testing/gtest/include/gtest/gtest.h" 14 #include "testing/gtest/include/gtest/gtest.h"
14 15
15 using content::BrowserThread; 16 using content::BrowserThread;
(...skipping 77 matching lines...) Expand 10 before | Expand all | Expand 10 after
93 94
94 theme_source()->StartDataRequest("css/newtab.css?pie", false, 3); 95 theme_source()->StartDataRequest("css/newtab.css?pie", false, 3);
95 EXPECT_EQ(theme_source()->result_request_id_, 3); 96 EXPECT_EQ(theme_source()->result_request_id_, 3);
96 EXPECT_NE(theme_source()->result_data_size_, empty_size); 97 EXPECT_NE(theme_source()->result_data_size_, empty_size);
97 98
98 // Check that we send NULL back when we can't find what we're looking for. 99 // Check that we send NULL back when we can't find what we're looking for.
99 theme_source()->StartDataRequest("css/WRONGURL", false, 7); 100 theme_source()->StartDataRequest("css/WRONGURL", false, 7);
100 EXPECT_EQ(theme_source()->result_request_id_, 7); 101 EXPECT_EQ(theme_source()->result_request_id_, 7);
101 EXPECT_EQ(theme_source()->result_data_size_, empty_size); 102 EXPECT_EQ(theme_source()->result_data_size_, empty_size);
102 } 103 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698