From 814309dfe54fbdbb66fa0d1b680d792a8c93b914 Mon Sep 17 00:00:00 2001 From: Peter Wagenet Date: Tue, 1 Feb 2022 15:30:30 -0800 Subject: [PATCH] Switch to rest-params --- .eslintrc.js | 1 - tests/test_helpers.ts | 8 ++++---- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/.eslintrc.js b/.eslintrc.js index 63c9d620..492cce86 100644 --- a/.eslintrc.js +++ b/.eslintrc.js @@ -48,7 +48,6 @@ module.exports = { // TODO: stop disabling these rules 'prefer-const': 'off', - 'prefer-rest-params': 'off', 'no-prototype-builtins': 'off', '@typescript-eslint/ban-types': 'off', '@typescript-eslint/ban-ts-comment': 'off', diff --git a/tests/test_helpers.ts b/tests/test_helpers.ts index c54d434c..6acf0cb9 100644 --- a/tests/test_helpers.ts +++ b/tests/test_helpers.ts @@ -25,19 +25,19 @@ let test = QUnit.test; function module(name: string, options?: any) { options = options || {}; QUnit.module(name, { - beforeEach: function () { + beforeEach: function (...args: unknown[]) { configure('async', customAsync); bb.begin(); if (options.setup) { - options.setup.apply(this, arguments); + options.setup.apply(this, args); } }, - afterEach: function () { + afterEach: function (...args: unknown[]) { bb.end(); if (options.teardown) { - options.teardown.apply(this, arguments); + options.teardown.apply(this, args); } }, });