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

Issue 2872283002: Reduce dependencies on rtc::FileSystem in FileRotatingStream tests, adding helpers in webrtc::test:: (Closed)

Created:
3 years, 7 months ago by nisse-webrtc
Modified:
3 years, 7 months ago
CC:
webrtc-reviews_webrtc.org, tterriberry_mozilla.com, kwiberg-webrtc, tkchin_webrtc
Target Ref:
refs/heads/master
Project:
webrtc
Visibility:
Public.

Description

Reduce dependencies on rtc::FileSystem in FileRotatingStream tests. Use webrtc::test::OutputPath instead of Filesystem::GetAppTempFolder. Added functions RemoveFile and RemoveDir in the webrtc::test namespace, to replace use of Filesystem::DeleteFolderAndContents. This makes Filesystem::DeleteFolderAndContents unused, to be deleted together with related code in a followup cl. BUG=webrtc:7345 Review-Url: https://codereview.webrtc.org/2872283002 Cr-Commit-Position: refs/heads/master@{#18173} Committed: https://chromium.googlesource.com/external/webrtc/+/dd7b5f32b59d9def668b9e9487589a572f20f6e0

Patch Set 1 #

Patch Set 2 : Put back delimiter at end of |path_dir_|. #

Patch Set 3 : Delete log files and directory at end of test. #

Patch Set 4 : Call Close before attempting to remove log files. #

Total comments: 4

Patch Set 5 : Use RemoveDirectoryA and DeleteFileA on windows. #

Patch Set 6 : Fix syntax error breaking windows build. #

Total comments: 7

Patch Set 7 : Addressed nits. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+55 lines, -21 lines) Patch
M webrtc/base/filerotatingstream.h View 1 2 1 chunk +1 line, -1 line 0 comments Download
M webrtc/base/filerotatingstream_unittest.cc View 1 2 3 4 5 6 3 chunks +32 lines, -20 lines 0 comments Download
M webrtc/test/testsupport/fileutils.h View 1 2 1 chunk +6 lines, -0 lines 0 comments Download
M webrtc/test/testsupport/fileutils.cc View 1 2 3 4 5 6 1 chunk +16 lines, -0 lines 0 comments Download

Messages

Total messages: 27 (11 generated)
nisse-webrtc
PTAL. If we can land this, quite a lot of code in base/fileutils.cc becomes unused. ...
3 years, 7 months ago (2017-05-10 12:02:38 UTC) #2
kjellander_webrtc
On 2017/05/10 12:02:38, nisse-webrtc wrote: > PTAL. If we can land this, quite a lot ...
3 years, 7 months ago (2017-05-10 13:55:52 UTC) #3
nisse-webrtc
On 2017/05/10 13:55:52, kjellander_webrtc wrote: > On 2017/05/10 12:02:38, nisse-webrtc wrote: > > PTAL. If ...
3 years, 7 months ago (2017-05-11 08:04:24 UTC) #4
nisse-webrtc
Tommi, can you have a look? I have little idea on how the posixish _unlink ...
3 years, 7 months ago (2017-05-11 09:18:25 UTC) #6
nisse-webrtc
Ping?
3 years, 7 months ago (2017-05-12 08:51:25 UTC) #7
kjellander_webrtc
lgtm but consider updating the title+description since we're now adding features to fileutils.h
3 years, 7 months ago (2017-05-12 09:02:24 UTC) #8
tommi
Could DeleteFolderAndContents simply be moved into the place it's currently being used from? https://codereview.webrtc.org/2872283002/diff/60001/webrtc/test/testsupport/fileutils.cc File ...
3 years, 7 months ago (2017-05-12 10:47:16 UTC) #10
nisse-webrtc
On 2017/05/12 10:47:16, tommi (wëbrtc) wrote: > Could DeleteFolderAndContents simply be moved into the place ...
3 years, 7 months ago (2017-05-12 11:06:15 UTC) #11
nisse-webrtc
https://codereview.webrtc.org/2872283002/diff/60001/webrtc/test/testsupport/fileutils.cc File webrtc/test/testsupport/fileutils.cc (right): https://codereview.webrtc.org/2872283002/diff/60001/webrtc/test/testsupport/fileutils.cc#newcode237 webrtc/test/testsupport/fileutils.cc:237: return _rmdir(directory_name.c_str()) == 0; On 2017/05/12 10:47:15, tommi (wëbrtc) ...
3 years, 7 months ago (2017-05-12 11:19:00 UTC) #12
nisse-webrtc
Ping? I think this is ready, by I'd need OWNER's approval by Peter or Tommi.
3 years, 7 months ago (2017-05-16 13:06:07 UTC) #17
tommi
lgtm https://codereview.webrtc.org/2872283002/diff/100001/webrtc/base/filerotatingstream_unittest.cc File webrtc/base/filerotatingstream_unittest.cc (right): https://codereview.webrtc.org/2872283002/diff/100001/webrtc/base/filerotatingstream_unittest.cc#newcode27 webrtc/base/filerotatingstream_unittest.cc:27: stream->Close(); nit: it feels kinda strange to do ...
3 years, 7 months ago (2017-05-16 14:34:22 UTC) #18
nisse-webrtc
Addressed nits, attempting to land now. https://codereview.webrtc.org/2872283002/diff/100001/webrtc/base/filerotatingstream_unittest.cc File webrtc/base/filerotatingstream_unittest.cc (right): https://codereview.webrtc.org/2872283002/diff/100001/webrtc/base/filerotatingstream_unittest.cc#newcode27 webrtc/base/filerotatingstream_unittest.cc:27: stream->Close(); On 2017/05/16 ...
3 years, 7 months ago (2017-05-17 07:38:32 UTC) #19
commit-bot: I haz the power
CQ is trying da patch. Follow status at: https://chromium-cq-status.appspot.com/v2/patch-status/codereview.webrtc.org/2872283002/120001
3 years, 7 months ago (2017-05-17 07:38:46 UTC) #22
commit-bot: I haz the power
Committed patchset #7 (id:120001) as https://chromium.googlesource.com/external/webrtc/+/dd7b5f32b59d9def668b9e9487589a572f20f6e0
3 years, 7 months ago (2017-05-17 08:08:42 UTC) #25
charujain1
A revert of this CL (patchset #7 id:120001) has been created in https://codereview.webrtc.org/2892453003/ by charujain@google.com. ...
3 years, 7 months ago (2017-05-17 11:52:05 UTC) #26
ehmaldonado_webrtc
3 years, 7 months ago (2017-05-17 12:22:01 UTC) #27
Message was sent while issue was closed.
A revert of this CL (patchset #7 id:120001) has been created in
https://codereview.webrtc.org/2885393002/ by ehmaldonado@webrtc.org.

The reason for reverting is: Fails to compile successfully. 
.

Powered by Google App Engine
This is Rietveld 408576698