Linting in tests

This commit is contained in:
Daniël van Noord
2021-04-30 20:26:52 +02:00
parent c7a3a0a329
commit 091b1f100e
11 changed files with 125 additions and 125 deletions

View File

@@ -5,29 +5,29 @@ import { l } from '../../GlobalsForTesting';
import { CMOptions } from '../../../src/Config/VariablesAndData';
import ToggleToolWarnPos from '../../../src/Config/Toggles/ToggleToolWarnPos';
describe('ToggleToolWarnPos', function () {
describe('ToggleToolWarnPos', () => {
global.l = l;
beforeEach(function () {
beforeEach(() => {
global.domids = {};
ToggleToolWarnPos();
});
describe('ToolWarnPos = 0', function () {
before(function () {
describe('ToolWarnPos = 0', () => {
before(() => {
CMOptions.ToolWarnPos = 0;
});
it('Toggle style correctly', function () {
it('Toggle style correctly', () => {
assert.equal(domids.CMDispTooltipWarningParent.style.top, 'auto'); // eslint-disable-line no-undef
assert.equal(domids.CMDispTooltipWarningParent.style.margin, '4px -4px'); // eslint-disable-line no-undef
assert.equal(domids.CMDispTooltipWarningParent.style.padding, '3px 4px'); // eslint-disable-line no-undef
});
});
describe('ToolWarnPos = 1', function () {
before(function () {
describe('ToolWarnPos = 1', () => {
before(() => {
CMOptions.ToolWarnPos = 1;
});
it('Toggle style correctly', function () {
it('Toggle style correctly', () => {
assert.equal(domids.CMDispTooltipWarningParent.style.right, 'auto'); // eslint-disable-line no-undef
assert.equal(domids.CMDispTooltipWarningParent.style.margin, '4px'); // eslint-disable-line no-undef
assert.equal(domids.CMDispTooltipWarningParent.style.padding, '4px 3px'); // eslint-disable-line no-undef