Use getters for AppState and UserConfig instead of accessing the fields directly

This will allow us to make them private.
This commit is contained in:
Stefan Haller 2024-07-14 14:22:36 +02:00
parent 54765d2236
commit 55d8e801f1
63 changed files with 76 additions and 76 deletions

View file

@ -9,8 +9,8 @@ var CommitWipWithPrefix = NewIntegrationTest(NewIntegrationTestArgs{
Description: "Commit with skip hook and config commitPrefix is defined. Prefix is ignored when creating WIP commits.",
ExtraCmdArgs: []string{},
Skip: false,
SetupConfig: func(testConfig *config.AppConfig) {
testConfig.UserConfig.Git.CommitPrefixes = map[string]config.CommitPrefixConfig{"repo": {Pattern: "^\\w+\\/(\\w+-\\w+).*", Replace: "[$1]: "}}
SetupConfig: func(cfg *config.AppConfig) {
cfg.GetUserConfig().Git.CommitPrefixes = map[string]config.CommitPrefixConfig{"repo": {Pattern: "^\\w+\\/(\\w+-\\w+).*", Replace: "[$1]: "}}
},
SetupRepo: func(shell *Shell) {
shell.NewBranch("feature/TEST-002")