add account settings page, rest of otp support, stdio credential helper, other misc
[squeep-authentication-module] / test / lint-html.js
index 4b5cd4757f0123d7f5968aae7798b3111879d754..70e336136dfab4f6fd055ea63974060f75fb83fe 100644 (file)
@@ -1,13 +1,7 @@
 'use strict';
-
-const assert = require('assert');
+const { makeHtmlLint } = require('@squeep/html-template-helper');
+const { HtmlValidate } = require('html-validate');
 const stubLogger = require('./stub-logger');
-const { lint } = require('html-minifier-lint'); // eslint-disable-line node/no-unpublished-require
-
-function lintHtml(html) {
-  const result = lint(html);
-  stubLogger.debug('lintHtml', '', { result, html });
-  assert(!result);
-}
-
-module.exports = lintHtml;
+const htmlValidate = new HtmlValidate();
+const lintHtml = makeHtmlLint(stubLogger, htmlValidate);
+module.exports = lintHtml;
\ No newline at end of file