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

Issue 8252011: Add a basic backwards compatibility unittest. (Closed)

Created:
9 years, 2 months ago by dgarrett
Modified:
9 years, 2 months ago
CC:
chromium-reviews, sra
Visibility:
Public.

Description

Add a basic backwards compatibility unittest. This verifies we can still apply old patches, but does not verify that old clients can apply new patches. That seems important, but I'm not sure how to do it without storing old client binaries in version control. Also refactors a number of unit tests to allow code sharing for reading files into memory. This is done via a new base class. Uses test binaries submitted seperatly because of build tools problems. BUG=None TEST=New Unittest Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=105982

Patch Set 1 #

Patch Set 2 : Add (hopeful) windows header fix. #

Patch Set 3 : Fix file listings to fix windows build #

Total comments: 4

Patch Set 4 : Fix review nits. #

Total comments: 6
Unified diffs Side-by-side diffs Delta from patch set Stats (+125 lines, -130 lines) Patch
A courgette/base_test_unittest.h View 1 2 3 1 chunk +26 lines, -0 lines 2 comments Download
A courgette/base_test_unittest.cc View 1 chunk +27 lines, -0 lines 2 comments Download
M courgette/bsdiff_memory_unittest.cc View 1 chunk +3 lines, -31 lines 0 comments Download
M courgette/courgette.gyp View 1 2 3 chunks +6 lines, -1 line 0 comments Download
M courgette/encode_decode_unittest.cc View 1 chunk +2 lines, -34 lines 0 comments Download
M courgette/encoded_program_fuzz_unittest.cc View 1 2 chunks +2 lines, -32 lines 0 comments Download
M courgette/image_info_unittest.cc View 1 2 3 1 chunk +2 lines, -32 lines 0 comments Download
A courgette/versioning_unittest.cc View 1 chunk +57 lines, -0 lines 2 comments Download

Messages

Total messages: 9 (0 generated)
dgarrett
This adds the backwards compatibility unittest that caused problems before, and addresses the issue of ...
9 years, 2 months ago (2011-10-13 22:49:16 UTC) #1
Michael Krebs
http://codereview.chromium.org/8252011/diff/3009/courgette/base_test_unittest.h File courgette/base_test_unittest.h (right): http://codereview.chromium.org/8252011/diff/3009/courgette/base_test_unittest.h#newcode20 courgette/base_test_unittest.h:20: void SetUp(); I believe this and TearDown() should be ...
9 years, 2 months ago (2011-10-17 21:22:14 UTC) #2
dgarrett
Good? http://codereview.chromium.org/8252011/diff/3009/courgette/base_test_unittest.h File courgette/base_test_unittest.h (right): http://codereview.chromium.org/8252011/diff/3009/courgette/base_test_unittest.h#newcode20 courgette/base_test_unittest.h:20: void SetUp(); On 2011/10/17 21:22:14, Michael Krebs wrote: ...
9 years, 2 months ago (2011-10-17 21:50:59 UTC) #3
Michael Krebs
lgtm
9 years, 2 months ago (2011-10-17 22:04:11 UTC) #4
commit-bot: I haz the power
No LGTM from valid reviewers yet.
9 years, 2 months ago (2011-10-17 22:27:52 UTC) #5
sra1
lgtm
9 years, 2 months ago (2011-10-17 22:56:19 UTC) #6
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/dgarrett@chromium.org/8252011/7001
9 years, 2 months ago (2011-10-17 22:58:13 UTC) #7
commit-bot: I haz the power
Change committed as 105982
9 years, 2 months ago (2011-10-18 01:08:37 UTC) #8
Paweł Hajdan Jr.
9 years, 2 months ago (2011-10-19 08:46:39 UTC) #9
Drive-by with testing nits, please fix 'em.

http://codereview.chromium.org/8252011/diff/7001/courgette/base_test_unittest.cc
File courgette/base_test_unittest.cc (right):

http://codereview.chromium.org/8252011/diff/7001/courgette/base_test_unittest...
courgette/base_test_unittest.cc:10: PathService::Get(base::DIR_SOURCE_ROOT,
&test_dir_);
Please check return value.

http://codereview.chromium.org/8252011/diff/7001/courgette/base_test_unittest...
courgette/base_test_unittest.cc:24:
EXPECT_TRUE(file_util::ReadFileToString(file_path, &file_bytes));
Not sure if this test is valuable at all.

http://codereview.chromium.org/8252011/diff/7001/courgette/base_test_unittest.h
File courgette/base_test_unittest.h (right):

http://codereview.chromium.org/8252011/diff/7001/courgette/base_test_unittest...
courgette/base_test_unittest.h:5: #include <string>
What's that? It's included twice in this file, and this one is above the header
guards. Probably not intended.

http://codereview.chromium.org/8252011/diff/7001/courgette/base_test_unittest...
courgette/base_test_unittest.h:26: #endif // COURGETTE_BASE_TEST_UNITTEST_H_
nit: Two spaces before // please.

http://codereview.chromium.org/8252011/diff/7001/courgette/versioning_unittes...
File courgette/versioning_unittest.cc (right):

http://codereview.chromium.org/8252011/diff/7001/courgette/versioning_unittes...
courgette/versioning_unittest.cc:16: const char* patch_file,
nit: Indentation is off.

http://codereview.chromium.org/8252011/diff/7001/courgette/versioning_unittes...
courgette/versioning_unittest.cc:23: 
nit: Remove empty line.

Powered by Google App Engine
This is Rietveld 408576698