Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve merge bot commit message #400

Closed
wants to merge 3 commits into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
@@ -394,7 +394,8 @@ public void run(Path scratchPath) {
if (error == null) {
log.info("Pushing successful merge");
if (!isAncestor) {
repo.commit("Merge", "duke", "duke@openjdk.org");
repo.commit("Automatic merge of " + fromBranch + " into " + toBranch,
"duke", "duke@openjdk.org");
}
repo.push(toBranch, target.url().toString(), false);
} else {
@@ -109,7 +109,7 @@ void mergeMasterBranch(TestInfo testInfo) throws IOException {
var known = Set.of(toHashA, fromHashB, toHashC);
var merge = toCommits.stream().filter(c -> !known.contains(c.hash())).findAny().get();
assertTrue(merge.isMerge());
assertEquals(List.of("Merge"), merge.message());
assertEquals(List.of("Automatic merge of master into master"), merge.message());
assertEquals("duke", merge.author().name());
assertEquals("duke@openjdk.org", merge.author().email());

@@ -538,7 +538,7 @@ void testMergeHourly(TestInfo testInfo) throws IOException {
var known = Set.of(toHashA, fromHashB, toHashC);
var merge = toCommits.stream().filter(c -> !known.contains(c.hash())).findAny().get();
assertTrue(merge.isMerge());
assertEquals(List.of("Merge"), merge.message());
assertEquals(List.of("Automatic merge of master into master"), merge.message());
assertEquals("duke", merge.author().name());
assertEquals("duke@openjdk.org", merge.author().email());

@@ -653,7 +653,7 @@ void testMergeDaily(TestInfo testInfo) throws IOException {
var known = Set.of(toHashA, fromHashB, toHashC);
var merge = toCommits.stream().filter(c -> !known.contains(c.hash())).findAny().get();
assertTrue(merge.isMerge());
assertEquals(List.of("Merge"), merge.message());
assertEquals(List.of("Automatic merge of master into master"), merge.message());
assertEquals("duke", merge.author().name());
assertEquals("duke@openjdk.org", merge.author().email());

@@ -774,7 +774,7 @@ void testMergeWeekly(TestInfo testInfo) throws IOException {
var known = Set.of(toHashA, fromHashB, toHashC);
var merge = toCommits.stream().filter(c -> !known.contains(c.hash())).findAny().get();
assertTrue(merge.isMerge());
assertEquals(List.of("Merge"), merge.message());
assertEquals(List.of("Automatic merge of master into master"), merge.message());
assertEquals("duke", merge.author().name());
assertEquals("duke@openjdk.org", merge.author().email());

@@ -895,7 +895,7 @@ void testMergeMonthly(TestInfo testInfo) throws IOException {
var known = Set.of(toHashA, fromHashB, toHashC);
var merge = toCommits.stream().filter(c -> !known.contains(c.hash())).findAny().get();
assertTrue(merge.isMerge());
assertEquals(List.of("Merge"), merge.message());
assertEquals(List.of("Automatic merge of master into master"), merge.message());
assertEquals("duke", merge.author().name());
assertEquals("duke@openjdk.org", merge.author().email());

@@ -1016,7 +1016,7 @@ void testMergeYearly(TestInfo testInfo) throws IOException {
var known = Set.of(toHashA, fromHashB, toHashC);
var merge = toCommits.stream().filter(c -> !known.contains(c.hash())).findAny().get();
assertTrue(merge.isMerge());
assertEquals(List.of("Merge"), merge.message());
assertEquals(List.of("Automatic merge of master into master"), merge.message());
assertEquals("duke", merge.author().name());
assertEquals("duke@openjdk.org", merge.author().email());