DescriptionGenerate snippets request JSON with base::Value.
Doing it as it did with string substitution is brittle, since it forced
assumptions about the JSON being generated out of the BuildRequest()
function and into its callers and GetHostRestricts().
When we're generating different types of requests, it will be easier to
understand what e.g. "obfuscated_gaia_id" is if it's always the ID, and
never a partial string of JSON.
Expose the BuildRequest() function to tests and test it.
BUG=621090
Committed: https://crrev.com/d96c68da73145d482fbfeefc32afbe33e8839251
Cr-Commit-Position: refs/heads/master@{#400656}
Patch Set 1 #Patch Set 2 : Add unit test for BuildRequest(). #
Total comments: 6
Patch Set 3 : Fixups. #Patch Set 4 : Avoid bracket initialization. #
Messages
Total messages: 15 (6 generated)
|