summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDavid Pursehouse <dpursehouse@collab.net>2018-06-19 22:36:24 +0900
committerDavid Pursehouse <dpursehouse@collab.net>2018-06-19 23:18:53 +0900
commit44c5d542b58b8bdfd394db599facfc33fc1e9863 (patch)
treef4f374a6fd990175475ae4b9d2521417a6a5d324
parentbb3677476d34ff90da8c5f49a68fcf7d52139504 (diff)
AbstractIndexTests: Use correct command to index project
The correct command is "project", singular, not "projects" plural. Fix this, and add assertions on the SSH command status which would have caught this mistake earlier. The test still needs further investigation, since it was passing despite the project not actually being indexed (due to the wrong command that was fixed here). Change-Id: I24c1492fc74d5412e8a488d73456a9f541c45440
-rw-r--r--gerrit-acceptance-tests/src/test/java/com/google/gerrit/acceptance/ssh/AbstractIndexTests.java4
1 files changed, 3 insertions, 1 deletions
diff --git a/gerrit-acceptance-tests/src/test/java/com/google/gerrit/acceptance/ssh/AbstractIndexTests.java b/gerrit-acceptance-tests/src/test/java/com/google/gerrit/acceptance/ssh/AbstractIndexTests.java
index 9b5a503a21..1097ce2b9a 100644
--- a/gerrit-acceptance-tests/src/test/java/com/google/gerrit/acceptance/ssh/AbstractIndexTests.java
+++ b/gerrit-acceptance-tests/src/test/java/com/google/gerrit/acceptance/ssh/AbstractIndexTests.java
@@ -49,6 +49,7 @@ public abstract class AbstractIndexTests extends AbstractDaemonTest {
String cmd = Joiner.on(" ").join("gerrit", "index", "changes", changeLegacyId);
adminSshSession.exec(cmd);
+ adminSshSession.assertSuccess();
assertChangeQuery("message:second", change.getChange(), true);
}
@@ -66,8 +67,9 @@ public abstract class AbstractIndexTests extends AbstractDaemonTest {
assertChangeQuery("message:second", change.getChange(), false);
enableChangeIndexWrites();
- String cmd = Joiner.on(" ").join("gerrit", "index", "projects", project.get());
+ String cmd = Joiner.on(" ").join("gerrit", "index", "project", project.get());
adminSshSession.exec(cmd);
+ adminSshSession.assertSuccess();
assertChangeQuery("message:second", change.getChange(), true);
}