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

Issue 2275353002: Removes TestVector from ct_log_verifier_unittest (Closed)

Created:
4 years, 3 months ago by Rob Percival
Modified:
4 years, 3 months ago
Reviewers:
Ryan Sleevi
CC:
chromium-reviews, rsleevi+watch_chromium.org, certificate-transparency-chrome_googlegroups.com, cbentzel+watch_chromium.org, Eran Messeri
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Removes TestVector from ct_log_verifier_unittest Its only purpose was to bundle together a hex string and the number of bytes it represents. The number of bytes (length_bytes) is redundant though, as it is easily calculated by strlen(str) / 2, and is not used anyway. The one thing that appeared to use it was HexToBytes, but this contained a bug that meant it both misinterpreted and ignored it. This also optimizes GetEmptyTreeHash by only calculating it once, which reduces total test duration by ~1 second. BUG=631087 Committed: https://crrev.com/540ba6cbe242920544a1f43019e4f4a3c6f81bf8 Cr-Commit-Position: refs/heads/master@{#414552}

Patch Set 1 #

Patch Set 2 : Removes comment referring to TestVector #

Total comments: 8

Patch Set 3 : Addresses Ryan Sleevi's comments #

Total comments: 3

Patch Set 4 : Addresses final comment #

Patch Set 5 : Fixes "truncation of constant value" warning #

Unified diffs Side-by-side diffs Delta from patch set Stats (+34 lines, -51 lines) Patch
M net/cert/ct_log_verifier_unittest.cc View 1 2 3 4 5 chunks +34 lines, -51 lines 0 comments Download

Dependent Patchsets:

Messages

Total messages: 21 (9 generated)
Rob Percival
PTAL - improvement on https://codereview.chromium.org/2183073002/
4 years, 3 months ago (2016-08-25 16:22:55 UTC) #4
Ryan Sleevi
https://codereview.chromium.org/2275353002/diff/20001/net/cert/ct_log_verifier_unittest.cc File net/cert/ct_log_verifier_unittest.cc (right): https://codereview.chromium.org/2275353002/diff/20001/net/cert/ct_log_verifier_unittest.cc#newcode98 net/cert/ct_log_verifier_unittest.cc:98: std::string HexToBytes(const std::string& hex_data) { DESIGN: You're (almost) always ...
4 years, 3 months ago (2016-08-25 18:32:11 UTC) #5
Rob Percival
I think your comment about removing HexToBytes entirely (on https://codereview.chromium.org/2182533002) is a good idea. I'll ...
4 years, 3 months ago (2016-08-25 19:35:14 UTC) #6
Ryan Sleevi
https://codereview.chromium.org/2275353002/diff/20001/net/cert/ct_log_verifier_unittest.cc File net/cert/ct_log_verifier_unittest.cc (right): https://codereview.chromium.org/2275353002/diff/20001/net/cert/ct_log_verifier_unittest.cc#newcode98 net/cert/ct_log_verifier_unittest.cc:98: std::string HexToBytes(const std::string& hex_data) { On 2016/08/25 19:35:13, Rob ...
4 years, 3 months ago (2016-08-25 20:15:20 UTC) #7
Rob Percival
https://codereview.chromium.org/2275353002/diff/20001/net/cert/ct_log_verifier_unittest.cc File net/cert/ct_log_verifier_unittest.cc (right): https://codereview.chromium.org/2275353002/diff/20001/net/cert/ct_log_verifier_unittest.cc#newcode98 net/cert/ct_log_verifier_unittest.cc:98: std::string HexToBytes(const std::string& hex_data) { On 2016/08/25 20:15:20, Ryan ...
4 years, 3 months ago (2016-08-25 20:26:40 UTC) #8
Ryan Sleevi
Once your (other) CL lands, I'll take a pass, because I think the constant use ...
4 years, 3 months ago (2016-08-25 20:32:46 UTC) #9
Ryan Sleevi
lgtm
4 years, 3 months ago (2016-08-25 20:32:50 UTC) #10
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2275353002/60001
4 years, 3 months ago (2016-08-25 20:59:07 UTC) #13
commit-bot: I haz the power
Try jobs failed on following builders: win_chromium_compile_dbg_ng on master.tryserver.chromium.win (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.win/builders/win_chromium_compile_dbg_ng/builds/246142) win_chromium_rel_ng on master.tryserver.chromium.win (JOB_FAILED, ...
4 years, 3 months ago (2016-08-25 21:10:14 UTC) #15
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2275353002/80001
4 years, 3 months ago (2016-08-25 21:22:53 UTC) #18
commit-bot: I haz the power
Committed patchset #5 (id:80001)
4 years, 3 months ago (2016-08-25 22:08:34 UTC) #19
commit-bot: I haz the power
4 years, 3 months ago (2016-08-25 22:11:55 UTC) #21
Message was sent while issue was closed.
Patchset 5 (id:??) landed as
https://crrev.com/540ba6cbe242920544a1f43019e4f4a3c6f81bf8
Cr-Commit-Position: refs/heads/master@{#414552}

Powered by Google App Engine
This is Rietveld 408576698