aboutsummaryrefslogtreecommitdiff
path: root/js/tests/helpers/fixture.js
diff options
context:
space:
mode:
authorPatrick H. Lauke <[email protected]>2021-05-04 12:46:06 +0100
committerGitHub <[email protected]>2021-05-04 12:46:06 +0100
commit8865a8ab1c7157ab81bf49afa62b75f36daee46d (patch)
tree97ef78f2ea8e07aab50014176d061fe3c1d49134 /js/tests/helpers/fixture.js
parent018ee6a3b50b958ddb49657086cd9168abf5a485 (diff)
parent7ea6578773cb1b7f5cfb8fb41321b3fa10349daf (diff)
downloadbootstrap-jo-docs-thanks-page.tar.xz
bootstrap-jo-docs-thanks-page.zip
Merge branch 'main' into jo-docs-thanks-pagejo-docs-thanks-page
Diffstat (limited to 'js/tests/helpers/fixture.js')
-rw-r--r--js/tests/helpers/fixture.js9
1 files changed, 9 insertions, 0 deletions
diff --git a/js/tests/helpers/fixture.js b/js/tests/helpers/fixture.js
index 0bfc26f46..3d6f395e8 100644
--- a/js/tests/helpers/fixture.js
+++ b/js/tests/helpers/fixture.js
@@ -39,3 +39,12 @@ export const jQueryMock = {
})
}
}
+
+export const clearBodyAndDocument = () => {
+ const attributes = ['data-bs-padding-right', 'style']
+
+ attributes.forEach(attr => {
+ document.documentElement.removeAttribute(attr)
+ document.body.removeAttribute(attr)
+ })
+}