frontend linting

This commit is contained in:
realaravinth
2021-10-08 15:24:29 +05:30
parent f7afc72d81
commit 53720ff740
91 changed files with 2158 additions and 1677 deletions

View File

@@ -15,22 +15,22 @@
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
import isBlankString from './isBlankString';
import {mockAlert} from '../setUpTests';
import isBlankString from "./isBlankString";
import {mockAlert} from "../setUpTests";
import setup from '../components/error/setUpTests';
import setup from "../components/error/setUpTests";
'use strict';
"use strict";
mockAlert();
it('getFromUrl workds', () => {
document.querySelector('body').appendChild(setup());
expect(isBlankString('test', 'username')).toBe(false);
it("getFromUrl workds", () => {
document.querySelector("body").appendChild(setup());
expect(isBlankString("test", "username")).toBe(false);
try {
isBlankString(' ', 'username');
isBlankString(" ", "username");
} catch (e) {
expect(e.message).toContain(`can't be empty`);
expect(e.message).toContain("can't be empty");
}
});