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

Side by Side Diff: chrome/browser/chromeos/drive/drive_url_request_job_unittest.cc

Issue 18355004: google_apis: Move data files out of chrome/test/data/chromeos (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix extension tests Created 7 years, 5 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 | Annotate | Revision Log
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 "chrome/browser/chromeos/drive/drive_url_request_job.h" 5 #include "chrome/browser/chromeos/drive/drive_url_request_job.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/memory/ref_counted.h" 8 #include "base/memory/ref_counted.h"
9 #include "base/memory/scoped_ptr.h" 9 #include "base/memory/scoped_ptr.h"
10 #include "base/run_loop.h" 10 #include "base/run_loop.h"
(...skipping 88 matching lines...) Expand 10 before | Expand all | Expand 10 after
99 : thread_bundle_(content::TestBrowserThreadBundle::IO_MAINLOOP) { 99 : thread_bundle_(content::TestBrowserThreadBundle::IO_MAINLOOP) {
100 } 100 }
101 101
102 virtual ~DriveURLRequestJobTest() { 102 virtual ~DriveURLRequestJobTest() {
103 } 103 }
104 104
105 virtual void SetUp() OVERRIDE { 105 virtual void SetUp() OVERRIDE {
106 // Initialize FakeDriveService. 106 // Initialize FakeDriveService.
107 fake_drive_service_.reset(new FakeDriveService); 107 fake_drive_service_.reset(new FakeDriveService);
108 ASSERT_TRUE(fake_drive_service_->LoadResourceListForWapi( 108 ASSERT_TRUE(fake_drive_service_->LoadResourceListForWapi(
109 "chromeos/gdata/root_feed.json")); 109 "gdata/root_feed.json"));
110 ASSERT_TRUE(fake_drive_service_->LoadAccountMetadataForWapi( 110 ASSERT_TRUE(fake_drive_service_->LoadAccountMetadataForWapi(
111 "chromeos/gdata/account_metadata.json")); 111 "gdata/account_metadata.json"));
112 112
113 // Initialize FakeFileSystem. 113 // Initialize FakeFileSystem.
114 fake_file_system_.reset( 114 fake_file_system_.reset(
115 new test_util::FakeFileSystem(fake_drive_service_.get())); 115 new test_util::FakeFileSystem(fake_drive_service_.get()));
116 ASSERT_TRUE(fake_file_system_->InitializeForTesting()); 116 ASSERT_TRUE(fake_file_system_->InitializeForTesting());
117 117
118 scoped_refptr<base::SequencedWorkerPool> blocking_pool = 118 scoped_refptr<base::SequencedWorkerPool> blocking_pool =
119 content::BrowserThread::GetBlockingPool(); 119 content::BrowserThread::GetBlockingPool();
120 test_network_delegate_.reset(new net::TestNetworkDelegate); 120 test_network_delegate_.reset(new net::TestNetworkDelegate);
121 test_url_request_job_factory_.reset(new TestURLRequestJobFactory( 121 test_url_request_job_factory_.reset(new TestURLRequestJobFactory(
(...skipping 249 matching lines...) Expand 10 before | Expand all | Expand 10 after
371 "Range", "Wrong Range Header Value", false /* overwrite */); 371 "Range", "Wrong Range Header Value", false /* overwrite */);
372 request.Start(); 372 request.Start();
373 373
374 base::RunLoop().Run(); 374 base::RunLoop().Run();
375 375
376 EXPECT_EQ(net::URLRequestStatus::FAILED, request.status().status()); 376 EXPECT_EQ(net::URLRequestStatus::FAILED, request.status().status());
377 EXPECT_EQ(net::ERR_REQUEST_RANGE_NOT_SATISFIABLE, request.status().error()); 377 EXPECT_EQ(net::ERR_REQUEST_RANGE_NOT_SATISFIABLE, request.status().error());
378 } 378 }
379 379
380 } // namespace drive 380 } // namespace drive
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698