use of com.google.gerrit.acceptance.TestAccount in project gerrit by GerritCodeReview.
the class ChangeNotificationsIT method newPatchSetOnReviewableChangeAddingReviewer.
@Test
public void newPatchSetOnReviewableChangeAddingReviewer() throws Exception {
StagedChange sc = stageReviewableChange();
TestAccount newReviewer = sc.testAccount("newReviewer");
pushTo(sc, "refs/for/master%r=" + newReviewer.username(), sc.owner);
assertThat(sender).sent("newpatchset", sc).to(sc.reviewer, newReviewer).cc(sc.ccer).cc(StagedUsers.REVIEWER_BY_EMAIL, StagedUsers.CC_BY_EMAIL).bcc(sc.starrer).bcc(NEW_PATCHSETS).noOneElse();
assertThat(sender).didNotSend();
}
use of com.google.gerrit.acceptance.TestAccount in project gerrit by GerritCodeReview.
the class ChangeNotificationsIT method addReviewerToWipChange.
private void addReviewerToWipChange(Adder adder) throws Exception {
StagedChange sc = stageWipChange();
TestAccount reviewer = accountCreator.create("added", "added@example.com", "added", null);
addReviewer(adder, sc.changeId, sc.owner, reviewer.email());
assertThat(sender).didNotSend();
}
use of com.google.gerrit.acceptance.TestAccount in project gerrit by GerritCodeReview.
the class ChangeNotificationsIT method abandonReviewableChangeByOtherCcingSelfNotifyOwner.
@Test
public void abandonReviewableChangeByOtherCcingSelfNotifyOwner() throws Exception {
StagedChange sc = stageReviewableChange();
TestAccount other = accountCreator.create("other", "other@example.com", "other", null);
abandon(sc.changeId, other, CC_ON_OWN_COMMENTS, OWNER);
assertThat(sender).sent("abandon", sc).to(sc.owner).cc(other).noOneElse();
assertThat(sender).didNotSend();
}
use of com.google.gerrit.acceptance.TestAccount in project gerrit by GerritCodeReview.
the class ChangeNotificationsIT method commentOnWipChangeByBot.
@Test
public void commentOnWipChangeByBot() throws Exception {
StagedChange sc = stageWipChange();
TestAccount bot = sc.testAccount("bot");
review(bot, sc.changeId, ENABLED, null, "autogenerated:tag");
assertThat(sender).sent("comment", sc).to(sc.owner).noOneElse();
assertThat(sender).didNotSend();
}
use of com.google.gerrit.acceptance.TestAccount in project gerrit by GerritCodeReview.
the class ChangeNotificationsIT method commentOnReviewableChangeByOtherCcingSelf.
@Test
public void commentOnReviewableChangeByOtherCcingSelf() throws Exception {
TestAccount other = accountCreator.create("other", "other@example.com", "other", null);
StagedChange sc = stageReviewableChange();
review(other, sc.changeId, CC_ON_OWN_COMMENTS);
assertThat(sender).sent("comment", sc).to(sc.owner).cc(sc.reviewer, sc.ccer, other).cc(StagedUsers.REVIEWER_BY_EMAIL, StagedUsers.CC_BY_EMAIL).bcc(sc.starrer).bcc(ALL_COMMENTS).noOneElse();
assertThat(sender).didNotSend();
}
Aggregations