1
0
mirror of https://github.com/jesseduffield/lazygit.git synced 2025-01-24 05:36:19 +02:00
lazygit/pkg/integration/tests/branch/open_pull_request_no_upstream.go
2023-09-18 13:40:52 +10:00

26 lines
721 B
Go

package branch
import (
"github.com/jesseduffield/lazygit/pkg/config"
. "github.com/jesseduffield/lazygit/pkg/integration/components"
)
var OpenPullRequestNoUpstream = NewIntegrationTest(NewIntegrationTestArgs{
Description: "Open up a pull request with a missing upstream branch",
ExtraCmdArgs: []string{},
Skip: false,
SetupConfig: func(config *config.AppConfig) {},
SetupRepo: func(shell *Shell) {},
Run: func(t *TestDriver, keys config.KeybindingConfig) {
t.Views().
Branches().
Focus().
Press(keys.Branches.CreatePullRequest)
t.ExpectPopup().Alert().
Title(Equals("Error")).
Content(Contains("Cannot open a pull request for a branch with no upstream")).
Confirm()
},
})