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

Issue 8372034: Created an interface for DownloadFile, for use in unit tests. (Closed)

Created:
9 years, 1 month ago by ahendrickson
Modified:
9 years, 1 month ago
CC:
chromium-reviews, achuith+watch_chromium.org, jam, dpranke-watch+content_chromium.org, joi+watch-content_chromium.org, rginda+watch_chromium.org, darin-cc_chromium.org, rdsmith+dwatch_chromium.org, Paweł Hajdan Jr.
Visibility:
Public.

Description

Created an interface for DownloadFile, for use in unit tests. Bug=None Test=None Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=110377

Patch Set 1 #

Patch Set 2 : Fixed linked_ptr issue, cleaned up download file interface. #

Patch Set 3 : More cleanup. SaveFile's member functions no longer virtual. #

Patch Set 4 : More Clang style issues. #

Patch Set 5 : Merged with trunk #

Patch Set 6 : Renamed the DownloadFile interface & implementation classes. #

Patch Set 7 : Fixed bug in download file error injection in a unit test. #

Patch Set 8 : Merged with trunk. #

Patch Set 9 : Moved DownloadFile interface and implementation to separate files. #

Patch Set 10 : Cleaned up download file interface and unit test class. #

Total comments: 23

Patch Set 11 : Merged with trunk. #

Patch Set 12 : Cleanup per Randy's comments. Now using MockDownloadFile. #

Patch Set 13 : Removed unused GMockDownloadFile. #

Patch Set 14 : Merged with trunk #

Patch Set 15 : Fixed Posix compile problems. #

Patch Set 16 : Fixed typo #

Total comments: 2
Unified diffs Side-by-side diffs Delta from patch set Stats (+675 lines, -217 lines) Patch
M chrome/browser/download/download_manager_unittest.cc View 1 2 3 4 5 6 7 8 9 10 11 12 16 chunks +76 lines, -86 lines 0 comments Download
M content/browser/download/base_file.h View 1 2 3 4 5 6 7 8 9 10 2 chunks +1 line, -1 line 0 comments Download
M content/browser/download/download_create_info.h View 1 2 3 4 5 6 7 8 1 chunk +1 line, -0 lines 0 comments Download
M content/browser/download/download_file.h View 1 2 3 4 5 6 7 8 9 10 11 2 chunks +49 lines, -36 lines 0 comments Download
M content/browser/download/download_file.cc View 1 2 3 4 5 6 7 8 3 chunks +14 lines, -56 lines 0 comments Download
A content/browser/download/download_file_impl.h View 1 2 3 4 5 6 7 8 9 10 11 1 chunk +66 lines, -0 lines 0 comments Download
A content/browser/download/download_file_impl.cc View 1 2 3 4 5 6 7 8 9 1 chunk +109 lines, -0 lines 0 comments Download
M content/browser/download/download_file_manager.cc View 1 2 3 4 5 6 7 8 9 10 11 8 chunks +13 lines, -12 lines 0 comments Download
M content/browser/download/download_file_unittest.cc View 1 2 3 4 5 6 7 8 8 chunks +14 lines, -14 lines 0 comments Download
M content/browser/download/download_resource_handler.h View 1 2 3 4 5 6 7 8 1 chunk +1 line, -0 lines 0 comments Download
M content/browser/download/drag_download_file.cc View 1 2 3 4 5 6 7 8 1 chunk +1 line, -0 lines 0 comments Download
A content/browser/download/mock_download_file.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 1 chunk +116 lines, -0 lines 2 comments Download
A content/browser/download/mock_download_file.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 1 chunk +134 lines, -0 lines 0 comments Download
M content/browser/download/save_file.h View 1 2 3 4 5 6 7 8 9 10 11 2 chunks +16 lines, -1 line 0 comments Download
M content/browser/download/save_file.cc View 1 2 3 4 5 6 7 8 9 10 11 2 chunks +49 lines, -1 line 0 comments Download
M content/browser/download/save_file_manager.cc View 1 2 3 4 5 6 7 8 9 10 11 8 chunks +10 lines, -10 lines 0 comments Download
M content/browser/renderer_host/buffered_resource_handler.cc View 1 2 3 4 5 6 7 8 1 chunk +1 line, -0 lines 0 comments Download
M content/content_browser.gypi View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +2 lines, -0 lines 0 comments Download
M content/content_tests.gypi View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +2 lines, -0 lines 0 comments Download

Messages

Total messages: 15 (0 generated)
ahendrickson
9 years, 1 month ago (2011-11-09 16:51:39 UTC) #1
Randy Smith (Not in Mondays)
So the amount of friending going on here makes me more than a bit uncomfortable. ...
9 years, 1 month ago (2011-11-10 02:36:38 UTC) #2
ahendrickson
OK, I refactored the DownloadFileWithMockStream class, and was able to remove a lot of the ...
9 years, 1 month ago (2011-11-10 20:19:50 UTC) #3
Randy Smith (Not in Mondays)
Thank you very much! This patch set makes my purist abstract heart much happier (and ...
9 years, 1 month ago (2011-11-10 21:58:42 UTC) #4
ahendrickson
http://codereview.chromium.org/8372034/diff/17001/chrome/browser/download/download_manager_unittest.cc File chrome/browser/download/download_manager_unittest.cc (left): http://codereview.chromium.org/8372034/diff/17001/chrome/browser/download/download_manager_unittest.cc#oldcode60 chrome/browser/download/download_manager_unittest.cc:60: download_manager_(new MockDownloadManager( On 2011/11/10 21:58:43, rdsmith wrote: > Why ...
9 years, 1 month ago (2011-11-13 00:50:21 UTC) #5
Randy Smith (Not in Mondays)
http://codereview.chromium.org/8372034/diff/24003/content/browser/download/mock_download_file.h File content/browser/download/mock_download_file.h (right): http://codereview.chromium.org/8372034/diff/24003/content/browser/download/mock_download_file.h#newcode22 content/browser/download/mock_download_file.h:22: class MockDownloadFile : virtual public DownloadFile { What are ...
9 years, 1 month ago (2011-11-14 21:58:38 UTC) #6
ahendrickson
http://codereview.chromium.org/8372034/diff/24003/content/browser/download/mock_download_file.h File content/browser/download/mock_download_file.h (right): http://codereview.chromium.org/8372034/diff/24003/content/browser/download/mock_download_file.h#newcode22 content/browser/download/mock_download_file.h:22: class MockDownloadFile : virtual public DownloadFile { On 2011/11/14 ...
9 years, 1 month ago (2011-11-16 19:39:11 UTC) #7
Randy Smith (Not in Mondays)
On 2011/11/16 19:39:11, ahendrickson wrote: > http://codereview.chromium.org/8372034/diff/24003/content/browser/download/mock_download_file.h > File content/browser/download/mock_download_file.h (right): > > http://codereview.chromium.org/8372034/diff/24003/content/browser/download/mock_download_file.h#newcode22 > ...
9 years, 1 month ago (2011-11-16 19:57:31 UTC) #8
Randy Smith (Not in Mondays)
LGTM.
9 years, 1 month ago (2011-11-16 19:58:19 UTC) #9
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/ahendrickson@chromium.org/8372034/24003
9 years, 1 month ago (2011-11-16 20:04:10 UTC) #10
commit-bot: I haz the power
Presubmit check for 8372034-24003 failed and returned exit status 1. Running presubmit commit checks ...
9 years, 1 month ago (2011-11-16 20:04:18 UTC) #11
ahendrickson
darin: PTAL at content/browser/renderer_host/buffered_resource_handler.cc I added a header that was necessary for DownloadSaveInfo(), that used ...
9 years, 1 month ago (2011-11-16 20:14:21 UTC) #12
darin (slow to review)
On 2011/11/16 20:14:21, ahendrickson wrote: > darin: PTAL at content/browser/renderer_host/buffered_resource_handler.cc > > I added a ...
9 years, 1 month ago (2011-11-16 21:23:02 UTC) #13
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/ahendrickson@chromium.org/8372034/24003
9 years, 1 month ago (2011-11-16 21:30:17 UTC) #14
commit-bot: I haz the power
9 years, 1 month ago (2011-11-16 22:31:43 UTC) #15
Change committed as 110377

Powered by Google App Engine
This is Rietveld 408576698