aboutsummaryrefslogtreecommitdiffstats
path: root/integrations/timetracking_test.go
diff options
context:
space:
mode:
authorsilverwind <me@silverwind.io>2020-12-10 17:19:18 +0100
committerGitHub <noreply@github.com>2020-12-10 17:19:18 +0100
commit1cb1fb8a2e86cc66a3f40f24d6f831eec90daba5 (patch)
tree43cc516c92e376f1d039226d3c026e21f91b8c7b /integrations/timetracking_test.go
parentbc1cf6e5d365265d18144a2afae25ca04df691b8 (diff)
downloadgitea-1cb1fb8a2e86cc66a3f40f24d6f831eec90daba5.tar.gz
gitea-1cb1fb8a2e86cc66a3f40f24d6f831eec90daba5.zip
Remove JS globals related to timetracking and due date (#13921)
Refactor to avoid these globals. Should work exactly as before.
Diffstat (limited to 'integrations/timetracking_test.go')
-rw-r--r--integrations/timetracking_test.go8
1 files changed, 4 insertions, 4 deletions
diff --git a/integrations/timetracking_test.go b/integrations/timetracking_test.go
index cd3002e1ac..7cf5f9bc8f 100644
--- a/integrations/timetracking_test.go
+++ b/integrations/timetracking_test.go
@@ -40,8 +40,8 @@ func testViewTimetrackingControls(t *testing.T, session *TestSession, user, repo
htmlDoc := NewHTMLParser(t, resp.Body)
- htmlDoc.AssertElement(t, ".timetrack .start-add .start", canTrackTime)
- htmlDoc.AssertElement(t, ".timetrack .start-add .add-time", canTrackTime)
+ htmlDoc.AssertElement(t, ".timetrack .issue-start-time", canTrackTime)
+ htmlDoc.AssertElement(t, ".timetrack .issue-add-time", canTrackTime)
req = NewRequestWithValues(t, "POST", path.Join(user, repo, "issues", issue, "times", "stopwatch", "toggle"), map[string]string{
"_csrf": htmlDoc.GetCSRF(),
@@ -56,8 +56,8 @@ func testViewTimetrackingControls(t *testing.T, session *TestSession, user, repo
events := htmlDoc.doc.Find(".event > span.text")
assert.Contains(t, events.Last().Text(), "started working")
- htmlDoc.AssertElement(t, ".timetrack .stop-cancel .stop", true)
- htmlDoc.AssertElement(t, ".timetrack .stop-cancel .cancel", true)
+ htmlDoc.AssertElement(t, ".timetrack .issue-stop-time", true)
+ htmlDoc.AssertElement(t, ".timetrack .issue-cancel-time", true)
// Sleep for 1 second to not get wrong order for stopping timer
time.Sleep(time.Second)