diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2022-06-09 18:09:21 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2022-06-09 18:09:21 +0300 |
commit | d2675fa4de909714fcc6dc1bdd7bee9ce5e3af34 (patch) | |
tree | 0c0fbdd55fbb3a1616b10775113bf8320c9529c8 /spec/frontend/blob | |
parent | 48d25238c386a89e8a6af218eeb290936a8f7595 (diff) |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'spec/frontend/blob')
-rw-r--r-- | spec/frontend/blob/components/table_contents_spec.js | 4 | ||||
-rw-r--r-- | spec/frontend/blob/viewer/index_spec.js | 6 |
2 files changed, 5 insertions, 5 deletions
diff --git a/spec/frontend/blob/components/table_contents_spec.js b/spec/frontend/blob/components/table_contents_spec.js index 358ac31819c..2cbac809a0d 100644 --- a/spec/frontend/blob/components/table_contents_spec.js +++ b/spec/frontend/blob/components/table_contents_spec.js @@ -11,7 +11,7 @@ function createComponent() { } async function setLoaded(loaded) { - document.querySelector('.blob-viewer').setAttribute('data-loaded', loaded); + document.querySelector('.blob-viewer').dataset.loaded = loaded; await nextTick(); } @@ -53,7 +53,7 @@ describe('Markdown table of contents component', () => { it('does not show dropdown when viewing non-rich content', async () => { createComponent(); - document.querySelector('.blob-viewer').setAttribute('data-type', 'simple'); + document.querySelector('.blob-viewer').dataset.type = 'simple'; await setLoaded(true); diff --git a/spec/frontend/blob/viewer/index_spec.js b/spec/frontend/blob/viewer/index_spec.js index 5f6baf3f63d..b2559af182b 100644 --- a/spec/frontend/blob/viewer/index_spec.js +++ b/spec/frontend/blob/viewer/index_spec.js @@ -80,9 +80,9 @@ describe('Blob viewer', () => { return asyncClick() .then(() => asyncClick()) .then(() => { - expect( - document.querySelector('.blob-viewer[data-type="simple"]').getAttribute('data-loaded'), - ).toBe('true'); + expect(document.querySelector('.blob-viewer[data-type="simple"]').dataset.loaded).toBe( + 'true', + ); }); }); |