1
0
mirror of https://github.com/jesseduffield/lazygit.git synced 2025-01-26 05:37:18 +02:00
lazygit/pkg/integration/tests/config/remote_named_star.go
Nils Andresen 245563bc99 (#2288) quote remoteName before compiling regex
If the remote name contains special regex-chars,
the compilation of the regex might fail.
Quoting the remoteName ensures that all special chars
in the remoteName are properly escaped before compiling
the regex.
2022-11-24 12:56:28 +00:00

27 lines
576 B
Go

package config
import (
"github.com/jesseduffield/lazygit/pkg/config"
. "github.com/jesseduffield/lazygit/pkg/integration/components"
)
var RemoteNamedStar = NewIntegrationTest(NewIntegrationTestArgs{
Description: "Having a config remote.*",
ExtraCmdArgs: "",
Skip: false,
SetupRepo: func(shell *Shell) {
shell.
SetConfig("remote.*.prune", "true").
CreateNCommits(2)
},
SetupConfig: func(cfg *config.AppConfig) {},
Run: func(
shell *Shell,
input *Input,
assert *Assert,
keys config.KeybindingConfig,
) {
assert.AtLeastOneCommit()
},
})