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

fix azure repos targetRefName #3349

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ private[azurerepos] object PullRequestPayload {
def from(data: NewPullRequestData): PullRequestPayload =
PullRequestPayload(
sourceRefName = withPrefix(data.head),
targetRefName = data.base.name,
targetRefName = withPrefix(data.base.name),
title = data.title,
labels = Option.when(data.labels.nonEmpty)(data.labels),
description = data.body
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -209,7 +209,7 @@ class AzureReposApiAlgTest extends CatsEffectSuite with Http4sDsl[MockEff] {
title = "Update cats-effect to 3.3.14",
body = "Updates org.typelevel:cats-effect from 3.3.13 to 3.3.14.",
head = "refs/heads/update/cats-effect-3.3.14",
base = Branch("refs/heads/main"),
base = Branch("main"),
labels = List.empty,
assignees = List.empty,
reviewers = List.empty
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ class JsonCodecTest extends FunSuite {
val expected =
json"""{
"sourceRefName" : "refs/heads/source",
"targetRefName" : "main",
"targetRefName" : "refs/heads/main",
"title" : "Test MR title",
"labels" : null,
"description" : "Test MR body"
Expand All @@ -38,7 +38,7 @@ class JsonCodecTest extends FunSuite {
val expected =
json"""{
"sourceRefName" : "refs/heads/source",
"targetRefName" : "main",
"targetRefName" : "refs/heads/main",
"title" : "Test MR title",
"labels" : [ "foo", "bar" ],
"description" : "Test MR body"
Expand Down