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

Side by Side Diff: components/nacl/browser/pnacl_translation_cache_unittest.cc

Issue 1748763003: Re-enable PnaclTranslationCacheTest.StoreLargeOnDisk (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 9 months 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 "components/nacl/browser/pnacl_translation_cache.h" 5 #include "components/nacl/browser/pnacl_translation_cache.h"
6 6
7 #include "base/files/file_path.h" 7 #include "base/files/file_path.h"
8 #include "base/files/scoped_temp_dir.h" 8 #include "base/files/scoped_temp_dir.h"
9 #include "base/message_loop/message_loop.h" 9 #include "base/message_loop/message_loop.h"
10 #include "base/run_loop.h" 10 #include "base/run_loop.h"
(...skipping 208 matching lines...) Expand 10 before | Expand all | Expand 10 after
219 } 219 }
220 220
221 TEST_F(PnaclTranslationCacheTest, StoreSmallOnDisk) { 221 TEST_F(PnaclTranslationCacheTest, StoreSmallOnDisk) {
222 // Test that a single store puts something in the disk backend 222 // Test that a single store puts something in the disk backend
223 InitBackend(false); 223 InitBackend(false);
224 StoreNexe(test_key, test_store_val); 224 StoreNexe(test_key, test_store_val);
225 EXPECT_EQ(1, cache_->Size()); 225 EXPECT_EQ(1, cache_->Size());
226 } 226 }
227 227
228 TEST_F(PnaclTranslationCacheTest, StoreLargeOnDisk) { 228 TEST_F(PnaclTranslationCacheTest, StoreLargeOnDisk) {
229 #if defined(OS_WIN)
230 // Flaky on XP bot http://crbug.com/468741
231 if (base::win::GetVersion() <= base::win::VERSION_XP)
232 return;
233 #endif
234 // Test a value too large(?) for a single I/O operation 229 // Test a value too large(?) for a single I/O operation
235 InitBackend(false); 230 InitBackend(false);
236 const std::string large_buffer(kLargeNexeSize, 'a'); 231 const std::string large_buffer(kLargeNexeSize, 'a');
237 StoreNexe(test_key, large_buffer); 232 StoreNexe(test_key, large_buffer);
238 EXPECT_EQ(1, cache_->Size()); 233 EXPECT_EQ(1, cache_->Size());
239 } 234 }
240 235
241 TEST_F(PnaclTranslationCacheTest, InMemSizeLimit) { 236 TEST_F(PnaclTranslationCacheTest, InMemSizeLimit) {
242 InitBackend(true); 237 InitBackend(true);
243 scoped_refptr<net::DrainableIOBuffer> large_buffer(new net::DrainableIOBuffer( 238 scoped_refptr<net::DrainableIOBuffer> large_buffer(new net::DrainableIOBuffer(
(...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after
300 StoreNexe(test_key, test_store_val); 295 StoreNexe(test_key, test_store_val);
301 TestNexeCallback load_cb; 296 TestNexeCallback load_cb;
302 std::string nexe; 297 std::string nexe;
303 cache_->GetNexe(test_key + "a", load_cb.callback()); 298 cache_->GetNexe(test_key + "a", load_cb.callback());
304 int rv; 299 int rv;
305 scoped_refptr<net::DrainableIOBuffer> buf(load_cb.GetResult(&rv)); 300 scoped_refptr<net::DrainableIOBuffer> buf(load_cb.GetResult(&rv));
306 EXPECT_EQ(net::ERR_FAILED, rv); 301 EXPECT_EQ(net::ERR_FAILED, rv);
307 } 302 }
308 303
309 } // namespace pnacl 304 } // namespace pnacl
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698