summaryrefslogtreecommitdiff
path: root/payload_consumer/postinstall_runner_action_unittest.cc
diff options
context:
space:
mode:
authorAlex Deymo <deymo@google.com>2016-02-18 11:00:40 -0800
committerAlex Deymo <deymo@google.com>2016-02-29 18:04:36 -0800
commit390efedcb7e17587da765b6d682077cb7fa46ee1 (patch)
tree8a8016f57fbcc5c5848ef95536b653171e05cb2d /payload_consumer/postinstall_runner_action_unittest.cc
parent14fd1ec41d1da4e849b724b762ca111a30c6628c (diff)
Parse postinstall parameters from the payload metadata.
Payload v2 includes a description of the post-install command it should run, while in payload v1 we use the default values. This patch mounts the partition on the new top-level directory called /postinstall that should already be created. Bug: 27177071 TEST=FEATURES=test emerge-link update_engine Change-Id: Iaedf3b01e5e1ad57c68bd316b4b6e79cbab35bb6
Diffstat (limited to 'payload_consumer/postinstall_runner_action_unittest.cc')
-rw-r--r--payload_consumer/postinstall_runner_action_unittest.cc3
1 files changed, 2 insertions, 1 deletions
diff --git a/payload_consumer/postinstall_runner_action_unittest.cc b/payload_consumer/postinstall_runner_action_unittest.cc
index c4c68b1f..85535d79 100644
--- a/payload_consumer/postinstall_runner_action_unittest.cc
+++ b/payload_consumer/postinstall_runner_action_unittest.cc
@@ -191,6 +191,7 @@ void PostinstallRunnerActionTest::DoTest(
part.name = "part";
part.target_path = dev;
part.run_postinstall = true;
+ part.postinstall_path = kPostinstallDefaultScript;
InstallPlan install_plan;
install_plan.partitions = {part};
install_plan.download_url = "http://devserver:8080/update";
@@ -215,7 +216,7 @@ void PostinstallRunnerActionTest::DoTest(
EXPECT_TRUE(delegate.code_set_);
EXPECT_EQ(should_succeed, delegate.code_ == ErrorCode::kSuccess);
if (should_succeed)
- EXPECT_TRUE(install_plan == collector_action.object());
+ EXPECT_EQ(install_plan, collector_action.object());
const base::FilePath kPowerwashMarkerPath(powerwash_marker_file);
string actual_cmd;