Skip to content

Commit 8bf9939

Browse files
committed
another attempt at tests
1 parent 5b7aae8 commit 8bf9939

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

integrations/pull_merge_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -194,7 +194,7 @@ func TestCantMergeWorkInProgress(t *testing.T) {
194194
req := NewRequest(t, "GET", resp.Header().Get("Location"))
195195
resp = session.MakeRequest(t, req, http.StatusOK)
196196
htmlDoc := NewHTMLParser(t, resp.Body)
197-
text := strings.TrimSpace(htmlDoc.doc.Find(".attached.merge-section.no-header .item").Last().Text())
197+
text := strings.TrimSpace(htmlDoc.doc.Find(".merge-section > .item").Last().Text())
198198
assert.NotEmpty(t, text, "Can't find WIP text")
199199

200200
// remove <strong /> from lang

integrations/pull_status_test.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -114,7 +114,7 @@ func TestPullCreate_EmptyChangesWithCommits(t *testing.T) {
114114
resp := session.MakeRequest(t, req, http.StatusOK)
115115
doc := NewHTMLParser(t, resp.Body)
116116

117-
text := strings.TrimSpace(doc.doc.Find(".item").Text())
118-
assert.EqualValues(t, "This pull request can be merged automatically.", text)
117+
text := strings.TrimSpace(doc.doc.Find(".merge-section").Text())
118+
assert.Contains(t, "This pull request can be merged automatically.", text)
119119
})
120120
}

0 commit comments

Comments
 (0)