• Istiaque Ahmed's avatar
    Remove ContentVerifyJob::TestDelegate. · 72816eaa
    Istiaque Ahmed authored
    The delegate used to create separate code paths in ContentVerifyJob,
    which makes the code harder to read and also creates a parallel
    reality in tests. Remove it entirely since tests using the delegate
    can work with the TestObserver in ContentVerifyJob.
    
    Remove two tests: ContentVerifierTest:FailOnRead/FailOnDone, that
    heavily used the TestDelegate. These tests were *artificially*
    (different from how production code does) creating error conditions
    from ContentVerifyJob::BytesRead and ContentVerifyJob::DoneReading.
    
    Extract test utilities related to content verification to a
    separate file (e/b/content_verifier/test_utils.h)
    
    Bug: 796395
    Change-Id: Ib59e9f0c7a4aac9b6a883d7f42647cecc603fa79
    Reviewed-on: https://chromium-review.googlesource.com/888327
    Commit-Queue: Istiaque Ahmed <lazyboy@chromium.org>
    Reviewed-by: default avatarDevlin <rdevlin.cronin@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#533050}
    72816eaa
BUILD.gn 11.7 KB