ChangeIT: Fix calls to exception.expect(...)

The tests were calling exception.equals(...) which compiles without
any warning, but is obviously wrong.

Change-Id: I34a51bb2916ebf183dc35352d622211e5aa5f19f
This commit is contained in:
David Pursehouse
2016-03-01 11:28:17 +09:00
parent b5b4eeb20e
commit f7021c2643

View File

@@ -282,7 +282,7 @@ public class ChangeIT extends AbstractDaemonTest {
assertThat(committer.email).isEqualTo(admin.email);
// Rebasing the second change again should fail
exception.equals(ResourceConflictException.class);
exception.expect(ResourceConflictException.class);
exception.expectMessage("Change is already up to date");
gApi.changes()
.id(changeId)
@@ -345,7 +345,7 @@ public class ChangeIT extends AbstractDaemonTest {
@Test
public void rebaseUpToDateChange() throws Exception {
PushOneCommit.Result r = createChange();
exception.equals(ResourceConflictException.class);
exception.expect(ResourceConflictException.class);
exception.expectMessage("Change is already up to date");
gApi.changes()
.id(r.getChangeId())