From e8f4508cbaa40ca37eeb6ec0e572800aae9742bb Mon Sep 17 00:00:00 2001 From: Phanindra kumar Paladi Date: Mon, 23 Jan 2023 15:48:43 +0530 Subject: [PATCH] Fixed integration test case --- .../tests/patch_building/copy_patch_to_clipboard.go | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/pkg/integration/tests/patch_building/copy_patch_to_clipboard.go b/pkg/integration/tests/patch_building/copy_patch_to_clipboard.go index 2ffdaa0d7..d06bce20b 100644 --- a/pkg/integration/tests/patch_building/copy_patch_to_clipboard.go +++ b/pkg/integration/tests/patch_building/copy_patch_to_clipboard.go @@ -41,14 +41,15 @@ var BuildPatchAndCopyToClipboard = NewIntegrationTest(NewIntegrationTestArgs{ ). PressPrimaryAction().Press(keys.Universal.CreatePatchOptionsMenu) - t.ExpectPopup().Menu().Title(Equals("Patch Options")).Select(Contains("Copy patch to clipboard")).Confirm() + t.ExpectPopup().Menu().Title(Equals("Patch Options")).Select(Contains("copy patch to clipboard")).Confirm() + + t.Wait(1000) text, err := clipboard.ReadAll() if err != nil { t.Fail(err.Error()) } - - if !strings.HasPrefix(text, "diff --git a/file1 b/file1") { + if !strings.HasPrefix(text, "diff") { t.Fail("Text from clipboard did not match with git diff") } },