From 7ada587bf38af5b08127c1e8a2a6e5ba32f13e8b Mon Sep 17 00:00:00 2001 From: Patrik Kullman Date: Thu, 14 May 2020 10:59:29 +0200 Subject: [PATCH] fix: linting issues, drop unused test helpers Signed-off-by: Patrik Kullman --- test/helpers/index.js | 29 ----------------------------- test/hooks/use-mouse-pan_test.js | 1 - test/hooks/use-touch-pan_test.js | 1 - 3 files changed, 31 deletions(-) diff --git a/test/helpers/index.js b/test/helpers/index.js index 82e4a62..31ffb8d 100644 --- a/test/helpers/index.js +++ b/test/helpers/index.js @@ -1,35 +1,6 @@ import { assert } from '@open-wc/testing'; export const - mount = str => { - const template = document.createElement('template'); - template.innerHTML = str; - host.appendChild(template.content.cloneNode(true)); - return () => { - host.innerHTML = ''; - }; - }, - - afterMutations = () => { - return new Promise(resolve => { - const mo = new MutationObserver(() => { - mo.disconnect(); - resolve(); - }); - mo.observe(host, { - childList: true, - subtree: true - }); - }); - }, - - later = (fn = Function.prototype) => { - return new Promise(resolve => { - setTimeout(() => { - resolve(fn()); - }, 80); - }); - }, HAS_NEW_TOUCH = (() => { try { diff --git a/test/hooks/use-mouse-pan_test.js b/test/hooks/use-mouse-pan_test.js index 8a61e54..7bd0c49 100644 --- a/test/hooks/use-mouse-pan_test.js +++ b/test/hooks/use-mouse-pan_test.js @@ -24,7 +24,6 @@ suite('use-mouse-pan', () => { test('it', async () => { expect(text()).to.equal('init, 0, 0'); - console.log(element.shadowRoot.firstElementChild); makeMouseEvent('mousedown', { x: 10, diff --git a/test/hooks/use-touch-pan_test.js b/test/hooks/use-touch-pan_test.js index a63dc4a..b9a66a3 100644 --- a/test/hooks/use-touch-pan_test.js +++ b/test/hooks/use-touch-pan_test.js @@ -1,4 +1,3 @@ -/* global host */ import { component, html } from 'haunted';