From 4f834304715229dc6a94060e6b2a146a329b1f1c Mon Sep 17 00:00:00 2001 From: Tao Bao Date: Thu, 19 Apr 2018 12:35:14 -0700 Subject: applypatch: Dump patch info on mismatching patching result. After splitting the previously flaky ApplyPatchModesTest#PatchModeEmmcTarget tests, PatchModeEmmcTargetWithMultiplePatches now becomes the sole victim. This CL dumps additional info to narrow down the cause. Bug: 67849209 Test: `recovery_component_test` on marlin. Test: It dumps additional info after using corrupt bonus.file. Change-Id: Ic5436de457cc882a51d03f49d5cee70077f7d3df --- tests/component/applypatch_test.cpp | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'tests') diff --git a/tests/component/applypatch_test.cpp b/tests/component/applypatch_test.cpp index aa0959bf5..f19f28c60 100644 --- a/tests/component/applypatch_test.cpp +++ b/tests/component/applypatch_test.cpp @@ -344,6 +344,11 @@ TEST_F(ApplyPatchModesTest, PatchModeEmmcTargetWithMultiplePatches) { patch1.c_str(), patch2.c_str(), patch3.c_str() }; + // TODO(b/67849209): Remove after addressing the flakiness. + printf("Calling applypatch_modes with the following args:\n"); + for (const auto& arg : args) { + printf(" %s\n", arg); + } ASSERT_EQ(0, applypatch_modes(args.size(), args.data())); } -- cgit v1.2.3