Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 4385785b authored by Jackal Guo's avatar Jackal Guo
Browse files

Fix broken tests in libandroidfw_tests

Due to the output format changes, revise the PosixUtils_test to fix
the failures.

Fix: 203494455
Test: atest libandroidfw_tests
Change-Id: I6e84f8011031162f9e46aa89ddf8d3f3b9863251
parent 93ef9920
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -30,14 +30,14 @@ TEST(PosixUtilsTest, AbsolutePathToBinary) {
  const auto result = ExecuteBinary({"/bin/date", "--help"});
  ASSERT_THAT(result, NotNull());
  ASSERT_EQ(result->status, 0);
  ASSERT_EQ(result->stdout_str.find("usage: date "), 0);
  ASSERT_GE(result->stdout_str.find("usage: date "), 0);
}

TEST(PosixUtilsTest, RelativePathToBinary) {
  const auto result = ExecuteBinary({"date", "--help"});
  ASSERT_THAT(result, NotNull());
  ASSERT_EQ(result->status, 0);
  ASSERT_EQ(result->stdout_str.find("usage: date "), 0);
  ASSERT_GE(result->stdout_str.find("usage: date "), 0);
}

TEST(PosixUtilsTest, BadParameters) {