From c8f26aca6859aa052f240f0414395b939d7eb48d Mon Sep 17 00:00:00 2001 From: Stefan Haller Date: Sat, 15 Apr 2023 12:39:30 +0200 Subject: [PATCH] Rename From to AtLeast --- pkg/integration/components/test.go | 2 +- pkg/integration/components/test_test.go | 12 ++++++------ .../drop_todo_commit_with_update_ref.go | 2 +- ..._todo_commit_with_update_ref_show_branch_heads.go | 2 +- 4 files changed, 9 insertions(+), 9 deletions(-) diff --git a/pkg/integration/components/test.go b/pkg/integration/components/test.go index 847781c8e..f4838ad86 100644 --- a/pkg/integration/components/test.go +++ b/pkg/integration/components/test.go @@ -60,7 +60,7 @@ type GitVersionRestriction struct { } // Verifies the version is at least the given version (inclusive) -func From(version string) GitVersionRestriction { +func AtLeast(version string) GitVersionRestriction { return GitVersionRestriction{from: version} } diff --git a/pkg/integration/components/test_test.go b/pkg/integration/components/test_test.go index 062382c2d..d15f86b0c 100644 --- a/pkg/integration/components/test_test.go +++ b/pkg/integration/components/test_test.go @@ -96,18 +96,18 @@ func TestGitVersionRestriction(t *testing.T) { expectedShouldRun bool }{ { - testName: "From, current is newer", - gitVersion: From("2.24.9"), + testName: "AtLeast, current is newer", + gitVersion: AtLeast("2.24.9"), expectedShouldRun: true, }, { - testName: "From, current is same", - gitVersion: From("2.25.0"), + testName: "AtLeast, current is same", + gitVersion: AtLeast("2.25.0"), expectedShouldRun: true, }, { - testName: "From, current is older", - gitVersion: From("2.26.0"), + testName: "AtLeast, current is older", + gitVersion: AtLeast("2.26.0"), expectedShouldRun: false, }, { diff --git a/pkg/integration/tests/interactive_rebase/drop_todo_commit_with_update_ref.go b/pkg/integration/tests/interactive_rebase/drop_todo_commit_with_update_ref.go index ace5bed40..e8d1e170a 100644 --- a/pkg/integration/tests/interactive_rebase/drop_todo_commit_with_update_ref.go +++ b/pkg/integration/tests/interactive_rebase/drop_todo_commit_with_update_ref.go @@ -9,7 +9,7 @@ var DropTodoCommitWithUpdateRef = NewIntegrationTest(NewIntegrationTestArgs{ Description: "Drops a commit during interactive rebase when there is an update-ref in the git-rebase-todo file", ExtraCmdArgs: "", Skip: false, - GitVersion: From("2.38.0"), + GitVersion: AtLeast("2.38.0"), SetupConfig: func(config *config.AppConfig) {}, SetupRepo: func(shell *Shell) { shell. diff --git a/pkg/integration/tests/interactive_rebase/drop_todo_commit_with_update_ref_show_branch_heads.go b/pkg/integration/tests/interactive_rebase/drop_todo_commit_with_update_ref_show_branch_heads.go index cb42ce989..6321891a7 100644 --- a/pkg/integration/tests/interactive_rebase/drop_todo_commit_with_update_ref_show_branch_heads.go +++ b/pkg/integration/tests/interactive_rebase/drop_todo_commit_with_update_ref_show_branch_heads.go @@ -9,7 +9,7 @@ var DropTodoCommitWithUpdateRefShowBranchHeads = NewIntegrationTest(NewIntegrati Description: "Drops a commit during interactive rebase when there is an update-ref in the git-rebase-todo file (with experimentalShowBranchHeads on)", ExtraCmdArgs: "", Skip: false, - GitVersion: From("2.38.0"), + GitVersion: AtLeast("2.38.0"), SetupConfig: func(config *config.AppConfig) { config.UserConfig.Gui.ExperimentalShowBranchHeads = true },