Skip to content

test(for_current_branch): fix hardcoded date breaking tests

Tomas Vik requested to merge hardcoded-date-breaking-tests into main

The pipeline response fixture had a hardcoded date "updated_at": "2016-08-11T11:32:35.169Z",. The dayjs logic that we use to display how long it has been since the pipeline finished (const timeAgo = dayjs(pipeline.updated_at).fromNow()) started reporting 5 years instead of 4 years yesterday evening 🤦.

This now breaks tests on your main branch: https://gitlab.com/gitlab-org/gitlab-vscode-extension/-/jobs/1025785814

test-integration___1025785814____Jobs___GitLab_org___gitlab-vscode-extension___GitLab

This change always sets the pipeline finish date to 4 years in the past so the tests can expect text Pipeline #47 passed · Finished 4 years ago.

Edited by Tomas Vik

Merge request reports