diff --git a/package-lock.json b/package-lock.json index 193b2f4395..bbf1e37cf9 100644 --- a/package-lock.json +++ b/package-lock.json @@ -25,68 +25,18 @@ } }, "@markedjs/html-differ": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/@markedjs/html-differ/-/html-differ-2.0.0.tgz", - "integrity": "sha512-Hubtx56xtJKCTZucqhlusMrAt0jmGP+ilNERR6bWD+IkkDbVEmCRNH3cqwUN1gYJqrPsqPE9gbQ/Y+oN3qYaEA==", + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/@markedjs/html-differ/-/html-differ-2.0.1.tgz", + "integrity": "sha512-Sv1PMZ9RGt+MZqIk7p4wHiOWZo34p1s4x2AIIipmK4HeZK1Vn7Hlp+A7K73I3CQgLfvUu4ZyuU219LIal6sUrg==", "dev": true, "requires": { - "chalk": "^2.4.1", - "coa": "^2.0.1", - "diff": "1.0.8", - "lodash": "^4.17.10", - "parse5": "1.1.3", - "vow": "^0.4.18", + "chalk": "^2.4.2", + "coa": "^2.0.2", + "diff": "1.3.2", + "lodash": "^4.17.11", + "parse5": "1.5.1", + "vow": "^0.4.19", "vow-fs": "^0.3.6" - }, - "dependencies": { - "coa": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/coa/-/coa-2.0.1.tgz", - "integrity": "sha512-5wfTTO8E2/ja4jFSxePXlG5nRu5bBtL/r1HCIpJW/lzT6yDtKl0u0Z4o/Vpz32IpKmBn7HerheEZQgA9N2DarQ==", - "dev": true, - "requires": { - "q": "^1.1.2" - } - }, - "lodash": { - "version": "4.17.10", - "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.10.tgz", - "integrity": "sha512-UejweD1pDoXu+AD825lWwp4ZGtSwgnpZxb3JDViD7StjQz+Nb/6l093lx4OQ0foGWNRoc19mWy7BzL+UAK2iVg==", - "dev": true - }, - "q": { - "version": "1.5.1", - "resolved": "https://registry.npmjs.org/q/-/q-1.5.1.tgz", - "integrity": "sha1-fjL3W0E4EpHQRhHxvxQQmsAGUdc=", - "dev": true - }, - "vow": { - "version": "0.4.18", - "resolved": "https://registry.npmjs.org/vow/-/vow-0.4.18.tgz", - "integrity": "sha512-7QGozxlOhour77BCQbbyW5XFP8ioIz/DPK67IyO3DnJtF0WXrXueMwqrYFM9yqyfgENcyxL+vktz2oJeZfdWtw==", - "dev": true - }, - "vow-fs": { - "version": "0.3.6", - "resolved": "https://registry.npmjs.org/vow-fs/-/vow-fs-0.3.6.tgz", - "integrity": "sha1-LUxZviLivyYY3fWXq0uqkjvnIA0=", - "dev": true, - "requires": { - "glob": "^7.0.5", - "uuid": "^2.0.2", - "vow": "^0.4.7", - "vow-queue": "^0.4.1" - } - }, - "vow-queue": { - "version": "0.4.3", - "resolved": "https://registry.npmjs.org/vow-queue/-/vow-queue-0.4.3.tgz", - "integrity": "sha512-/poAKDTFL3zYbeQg7cl4BGcfP4sGgXKrHnRFSKj97dteUFu8oyXMwIcdwu8NSx/RmPGIuYx1Bik/y5vU4H/VKw==", - "dev": true, - "requires": { - "vow": "^0.4.17" - } - } } }, "@types/concat-stream": { @@ -113,6 +63,12 @@ "integrity": "sha512-NOLEgsT6UiDTjnWG5Hd2Mg25LRyz/oe8ql3wbjzgSFeRzRROhPmtlsvIrei4B46UjERF0td9SZ1ZXPLOdcrBHg==", "dev": true }, + "@types/q": { + "version": "1.5.1", + "resolved": "https://registry.npmjs.org/@types/q/-/q-1.5.1.tgz", + "integrity": "sha512-eqz8c/0kwNi/OEHQfvIuJVLTst3in0e7uTKeuY+WL/zfKn0xVujOTp42bS/vUUokhK5P2BppLd9JXMOMHcgbjA==", + "dev": true + }, "@types/qs": { "version": "6.5.1", "resolved": "https://registry.npmjs.org/@types/qs/-/qs-6.5.1.tgz", @@ -126,9 +82,9 @@ "dev": true }, "acorn": { - "version": "6.0.5", - "resolved": "https://registry.npmjs.org/acorn/-/acorn-6.0.5.tgz", - "integrity": "sha512-i33Zgp3XWtmZBMNvCr4azvOFeWVw1Rk6p3hfi3LUDvIFraOMywb1kAtrbi+med14m4Xfpqm3zRZMT+c0FNE7kg==", + "version": "6.1.1", + "resolved": "https://registry.npmjs.org/acorn/-/acorn-6.1.1.tgz", + "integrity": "sha512-jPTiwtOxaHNaAPg/dmrJ/beuzLRnXtB0kQPQ8JpotKJgTB6rX6c8mlf315941pyjBSaPg8NHXS9fhP4u17DpGA==", "dev": true }, "acorn-jsx": { @@ -138,9 +94,9 @@ "dev": true }, "ajv": { - "version": "6.7.0", - "resolved": "https://registry.npmjs.org/ajv/-/ajv-6.7.0.tgz", - "integrity": "sha512-RZXPviBTtfmtka9n9sy1N5M5b82CbxWIR6HIis4s3WQTXDJamc/0gpCWNGz6EWdWp4DOfjzJfhz/AS9zVPjjWg==", + "version": "6.10.0", + "resolved": "https://registry.npmjs.org/ajv/-/ajv-6.10.0.tgz", + "integrity": "sha512-nffhOpkymDECQyR0mnsUtoCE8RlX38G0rYP+wgLWFyZuUyuuojSSvi/+euOiQBIn63whYwYVIIH1TvE3tu4OEg==", "dev": true, "requires": { "fast-deep-equal": "^2.0.1", @@ -150,9 +106,9 @@ } }, "ansi-escapes": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/ansi-escapes/-/ansi-escapes-3.1.0.tgz", - "integrity": "sha512-UgAb8H9D41AQnu/PbWlCofQVcnV4Gs2bBJi9eZPxfU/hgglFh3SMDMENRIqdr7H6XFnXdoknctFByVsCOotTVw==", + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/ansi-escapes/-/ansi-escapes-3.2.0.tgz", + "integrity": "sha512-cBhpre4ma+U0T1oM5fXg7Dy1Jw7zzwv7lt/GoCpr+hDQJoYnKVPLL4dCvSEFMmQurOQvSrwT7SL/DAlhBI97RQ==", "dev": true }, "ansi-regex": { @@ -213,12 +169,6 @@ "concat-map": "0.0.1" } }, - "builtin-modules": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/builtin-modules/-/builtin-modules-1.1.1.tgz", - "integrity": "sha1-Jw8HbFpywC9bZaR9+Uxf46J4iS8=", - "dev": true - }, "callsites": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/callsites/-/callsites-3.0.0.tgz", @@ -232,34 +182,14 @@ "dev": true }, "chalk": { - "version": "2.4.1", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.1.tgz", - "integrity": "sha512-ObN6h1v2fTJSmUXoS3nMQ92LbDK9be4TV+6G+omQlGJFdcUX5heKi1LZ1YnRMIgwTLEj3E24bT6tYni50rlCfQ==", + "version": "2.4.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-2.4.2.tgz", + "integrity": "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==", "dev": true, "requires": { "ansi-styles": "^3.2.1", "escape-string-regexp": "^1.0.5", "supports-color": "^5.3.0" - }, - "dependencies": { - "ansi-styles": { - "version": "3.2.1", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", - "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", - "dev": true, - "requires": { - "color-convert": "^1.9.0" - } - }, - "supports-color": { - "version": "5.5.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz", - "integrity": "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==", - "dev": true, - "requires": { - "has-flag": "^3.0.0" - } - } } }, "chardet": { @@ -268,12 +198,6 @@ "integrity": "sha512-mT8iDcrh03qDGRRmoA2hmBJnxpllMR+0/0qlzjqZES6NdiWDcZkCNAk4rPFZ9Q85r27unkiNNg8ZOiwZXBHwcA==", "dev": true }, - "circular-json": { - "version": "0.3.3", - "resolved": "https://registry.npmjs.org/circular-json/-/circular-json-0.3.3.tgz", - "integrity": "sha512-UZK3NBx2Mca+b5LsG7bY183pHWt5Y1xts4P3Pz7ENTwGVnJOUWbRb3ocjvX7hx9tq/yTAdclXm9sZ38gNuem4A==", - "dev": true - }, "cli-cursor": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/cli-cursor/-/cli-cursor-2.1.0.tgz", @@ -289,6 +213,17 @@ "integrity": "sha1-/xnt6Kml5XkyQUewwR8PvLq+1jk=", "dev": true }, + "coa": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/coa/-/coa-2.0.2.tgz", + "integrity": "sha512-q5/jG+YQnSy4nRTV4F7lPepBJZ8qBNJJDBuJdoejDyLXgmL7IEo+Le2JDZudFTFt7mrCqIRaSjws4ygRCTCAXA==", + "dev": true, + "requires": { + "@types/q": "^1.5.1", + "chalk": "^2.4.1", + "q": "^1.1.2" + } + }, "color-convert": { "version": "1.9.3", "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz", @@ -412,14 +347,6 @@ "dev": true, "requires": { "ms": "^2.1.1" - }, - "dependencies": { - "ms": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.1.tgz", - "integrity": "sha512-tgp+dl5cGk28utYktBsrFqA7HKgrhgPsg6Z/EfhWI4gl1Hwq8B/GmY/0oXZ6nF8hDVesS/FpnYaD/kOWhYQvyg==", - "dev": true - } } }, "deep-is": { @@ -435,20 +362,26 @@ "dev": true }, "diff": { - "version": "1.0.8", - "resolved": "https://registry.npmjs.org/diff/-/diff-1.0.8.tgz", - "integrity": "sha1-NDJ2MI7Jkbe8giZ+1VvBQR+XFmY=", + "version": "1.3.2", + "resolved": "https://registry.npmjs.org/diff/-/diff-1.3.2.tgz", + "integrity": "sha1-/Qeh8fiRUZ2ZBaTJqJ3PWnC2YDc=", "dev": true }, "doctrine": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/doctrine/-/doctrine-2.1.0.tgz", - "integrity": "sha512-35mSku4ZXK0vfCuHEDAwt55dg2jNajHZ1odvF+8SSr82EsZY4QmXfuWso8oEd8zRhVObSN18aM0CjSdoBX7zIw==", + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/doctrine/-/doctrine-3.0.0.tgz", + "integrity": "sha512-yS+Q5i3hBf7GBkd4KG8a7eBNNWNGLTaEwwYWUijIYM7zrlYDM0BFXHjjPWlWZ1Rg7UaddZeIDmi9jF3HmqiQ2w==", "dev": true, "requires": { "esutils": "^2.0.2" } }, + "emoji-regex": { + "version": "7.0.3", + "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-7.0.3.tgz", + "integrity": "sha512-CwBLREIQ7LvYFB0WyRvwhq5N5qPhc6PMjD6bYggFlI5YyDgl+0vxq5VHbMOFqLg7hfWzmu8T5Z1QofhmTIhItA==", + "dev": true + }, "entities": { "version": "1.1.1", "resolved": "https://registry.npmjs.org/entities/-/entities-1.1.1.tgz", @@ -471,47 +404,46 @@ "dev": true }, "eslint": { - "version": "5.12.0", - "resolved": "https://registry.npmjs.org/eslint/-/eslint-5.12.0.tgz", - "integrity": "sha512-LntwyPxtOHrsJdcSwyQKVtHofPHdv+4+mFwEe91r2V13vqpM8yLr7b1sW+Oo/yheOPkWYsYlYJCkzlFAt8KV7g==", + "version": "5.15.1", + "resolved": "https://registry.npmjs.org/eslint/-/eslint-5.15.1.tgz", + "integrity": "sha512-NTcm6vQ+PTgN3UBsALw5BMhgO6i5EpIjQF/Xb5tIh3sk9QhrFafujUOczGz4J24JBlzWclSB9Vmx8d+9Z6bFCg==", "dev": true, "requires": { "@babel/code-frame": "^7.0.0", - "ajv": "^6.5.3", + "ajv": "^6.9.1", "chalk": "^2.1.0", "cross-spawn": "^6.0.5", "debug": "^4.0.1", - "doctrine": "^2.1.0", - "eslint-scope": "^4.0.0", + "doctrine": "^3.0.0", + "eslint-scope": "^4.0.2", "eslint-utils": "^1.3.1", "eslint-visitor-keys": "^1.0.0", - "espree": "^5.0.0", + "espree": "^5.0.1", "esquery": "^1.0.1", "esutils": "^2.0.2", - "file-entry-cache": "^2.0.0", + "file-entry-cache": "^5.0.1", "functional-red-black-tree": "^1.0.1", "glob": "^7.1.2", "globals": "^11.7.0", "ignore": "^4.0.6", "import-fresh": "^3.0.0", "imurmurhash": "^0.1.4", - "inquirer": "^6.1.0", + "inquirer": "^6.2.2", "js-yaml": "^3.12.0", "json-stable-stringify-without-jsonify": "^1.0.1", "levn": "^0.3.0", - "lodash": "^4.17.5", + "lodash": "^4.17.11", "minimatch": "^3.0.4", "mkdirp": "^0.5.1", "natural-compare": "^1.4.0", "optionator": "^0.8.2", "path-is-inside": "^1.0.2", - "pluralize": "^7.0.0", "progress": "^2.0.0", "regexpp": "^2.0.1", "semver": "^5.5.1", "strip-ansi": "^4.0.0", "strip-json-comments": "^2.0.1", - "table": "^5.0.2", + "table": "^5.2.3", "text-table": "^0.2.0" } }, @@ -539,17 +471,23 @@ "requires": { "ms": "2.0.0" } + }, + "ms": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", + "integrity": "sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g=", + "dev": true } } }, "eslint-module-utils": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/eslint-module-utils/-/eslint-module-utils-2.2.0.tgz", - "integrity": "sha1-snA2LNiLGkitMIl2zn+lTphBF0Y=", + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/eslint-module-utils/-/eslint-module-utils-2.3.0.tgz", + "integrity": "sha512-lmDJgeOOjk8hObTysjqH7wyMi+nsHwwvfBykwfhjR1LNdd7C2uFJBvx4OpWYpXOw4df1yE1cDEVd1yLHitk34w==", "dev": true, "requires": { "debug": "^2.6.8", - "pkg-dir": "^1.0.0" + "pkg-dir": "^2.0.0" }, "dependencies": { "debug": { @@ -560,6 +498,12 @@ "requires": { "ms": "2.0.0" } + }, + "ms": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", + "integrity": "sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g=", + "dev": true } } }, @@ -574,21 +518,21 @@ } }, "eslint-plugin-import": { - "version": "2.14.0", - "resolved": "https://registry.npmjs.org/eslint-plugin-import/-/eslint-plugin-import-2.14.0.tgz", - "integrity": "sha512-FpuRtniD/AY6sXByma2Wr0TXvXJ4nA/2/04VPlfpmUDPOpOY264x+ILiwnrk/k4RINgDAyFZByxqPUbSQ5YE7g==", + "version": "2.16.0", + "resolved": "https://registry.npmjs.org/eslint-plugin-import/-/eslint-plugin-import-2.16.0.tgz", + "integrity": "sha512-z6oqWlf1x5GkHIFgrSvtmudnqM6Q60KM4KvpWi5ubonMjycLjndvd5+8VAZIsTlHC03djdgJuyKG6XO577px6A==", "dev": true, "requires": { "contains-path": "^0.1.0", - "debug": "^2.6.8", + "debug": "^2.6.9", "doctrine": "1.5.0", - "eslint-import-resolver-node": "^0.3.1", - "eslint-module-utils": "^2.2.0", - "has": "^1.0.1", - "lodash": "^4.17.4", - "minimatch": "^3.0.3", + "eslint-import-resolver-node": "^0.3.2", + "eslint-module-utils": "^2.3.0", + "has": "^1.0.3", + "lodash": "^4.17.11", + "minimatch": "^3.0.4", "read-pkg-up": "^2.0.0", - "resolve": "^1.6.0" + "resolve": "^1.9.0" }, "dependencies": { "debug": { @@ -610,20 +554,11 @@ "isarray": "^1.0.0" } }, - "lodash": { - "version": "4.17.10", - "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.10.tgz", - "integrity": "sha512-UejweD1pDoXu+AD825lWwp4ZGtSwgnpZxb3JDViD7StjQz+Nb/6l093lx4OQ0foGWNRoc19mWy7BzL+UAK2iVg==", + "ms": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", + "integrity": "sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g=", "dev": true - }, - "resolve": { - "version": "1.8.1", - "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.8.1.tgz", - "integrity": "sha512-AicPrAC7Qu1JxPCZ9ZgCZlY35QgFnNqc+0LtbRNxnVw4TXvjQ72wnuL9JQcEBgXkI9JM8MsT9kaQoHcpCRJOYA==", - "dev": true, - "requires": { - "path-parse": "^1.0.5" - } } } }, @@ -687,9 +622,9 @@ } }, "eslint-scope": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/eslint-scope/-/eslint-scope-4.0.0.tgz", - "integrity": "sha512-1G6UTDi7Jc1ELFwnR58HV4fK9OQK4S6N985f166xqXxpjU6plxFISJa2Ba9KCQuFa8RCnj/lSFJbHo7UFDBnUA==", + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/eslint-scope/-/eslint-scope-4.0.2.tgz", + "integrity": "sha512-5q1+B/ogmHl8+paxtOKx38Z8LtWkVGuNt3+GQNErqwLl6ViNp/gdJGMCjZNxZ8j/VYjDNZ2Fo+eQc1TAVPIzbg==", "dev": true, "requires": { "esrecurse": "^4.1.0", @@ -709,12 +644,12 @@ "dev": true }, "espree": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/espree/-/espree-5.0.0.tgz", - "integrity": "sha512-1MpUfwsdS9MMoN7ZXqAr9e9UKdVHDcvrJpyx7mm1WuQlx/ygErEQBzgi5Nh5qBHIoYweprhtMkTCb9GhcAIcsA==", + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/espree/-/espree-5.0.1.tgz", + "integrity": "sha512-qWAZcWh4XE/RwzLJejfcofscgMc9CamR6Tn1+XRXNzrvUSSbiAjGOI/fggztjIi7y9VLPqnICMIPiGyr8JaZ0A==", "dev": true, "requires": { - "acorn": "^6.0.2", + "acorn": "^6.0.7", "acorn-jsx": "^5.0.0", "eslint-visitor-keys": "^1.0.0" } @@ -794,37 +729,40 @@ } }, "file-entry-cache": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/file-entry-cache/-/file-entry-cache-2.0.0.tgz", - "integrity": "sha1-w5KZDD5oR4PYOLjISkXYoEhFg2E=", + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/file-entry-cache/-/file-entry-cache-5.0.1.tgz", + "integrity": "sha512-bCg29ictuBaKUwwArK4ouCaqDgLZcysCFLmM/Yn/FDoqndh/9vNuQfXRDvTuXKLxfD/JtZQGKFT8MGcJBK644g==", "dev": true, "requires": { - "flat-cache": "^1.2.1", - "object-assign": "^4.0.1" + "flat-cache": "^2.0.1" } }, "find-up": { - "version": "1.1.2", - "resolved": "https://registry.npmjs.org/find-up/-/find-up-1.1.2.tgz", - "integrity": "sha1-ay6YIrGizgpgq2TWEOzK1TyyTQ8=", + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/find-up/-/find-up-2.1.0.tgz", + "integrity": "sha1-RdG35QbHF93UgndaK3eSCjwMV6c=", "dev": true, "requires": { - "path-exists": "^2.0.0", - "pinkie-promise": "^2.0.0" + "locate-path": "^2.0.0" } }, "flat-cache": { - "version": "1.3.4", - "resolved": "https://registry.npmjs.org/flat-cache/-/flat-cache-1.3.4.tgz", - "integrity": "sha512-VwyB3Lkgacfik2vhqR4uv2rvebqmDvFu4jlN/C1RzWoJEo8I7z4Q404oiqYCkq41mni8EzQnm95emU9seckwtg==", + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/flat-cache/-/flat-cache-2.0.1.tgz", + "integrity": "sha512-LoQe6yDuUMDzQAEH8sgmh4Md6oZnc/7PjtwjNFSzveXqSHt6ka9fPBuso7IGf9Rz4uqnSnWiFH2B/zj24a5ReA==", "dev": true, "requires": { - "circular-json": "^0.3.1", - "graceful-fs": "^4.1.2", - "rimraf": "~2.6.2", - "write": "^0.2.1" + "flatted": "^2.0.0", + "rimraf": "2.6.3", + "write": "1.0.3" } }, + "flatted": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/flatted/-/flatted-2.0.0.tgz", + "integrity": "sha512-R+H8IZclI8AAkSBRQJLVOsxwAoHd6WC40b4QTNWIjzAa6BXOBfQcM587MXDTVPeYaopFNWHUFLx7eNmHDSxMWg==", + "dev": true + }, "form-data": { "version": "2.3.2", "resolved": "https://registry.npmjs.org/form-data/-/form-data-2.3.2.tgz", @@ -890,15 +828,15 @@ "dev": true }, "globals": { - "version": "11.10.0", - "resolved": "https://registry.npmjs.org/globals/-/globals-11.10.0.tgz", - "integrity": "sha512-0GZF1RiPKU97IHUO5TORo9w1PwrH/NBPl+fS7oMLdaTRiYmYbwK4NWoZWrAdd0/abG9R2BU+OiwyQpTpE6pdfQ==", + "version": "11.11.0", + "resolved": "https://registry.npmjs.org/globals/-/globals-11.11.0.tgz", + "integrity": "sha512-WHq43gS+6ufNOEqlrDBxVEbb8ntfXrfAUU2ZOpCxrBdGKW3gyv8mCxAfIBD0DroPKGrJ2eSsXsLtY9MPntsyTw==", "dev": true }, "graceful-fs": { - "version": "4.1.11", - "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.1.11.tgz", - "integrity": "sha1-Dovf5NHduIVNZOBOp8AOKgJuVlg=", + "version": "4.1.15", + "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.1.15.tgz", + "integrity": "sha512-6uHUhOPEBgQ24HM+r6b/QwWfZq+yiFcipKFrOFiBEnWdy5sdzYoi+pJeQaPI5qOLRFqWmAXUPQNsielzdLoecA==", "dev": true }, "has": { @@ -993,39 +931,39 @@ "dev": true }, "inquirer": { - "version": "6.2.1", - "resolved": "https://registry.npmjs.org/inquirer/-/inquirer-6.2.1.tgz", - "integrity": "sha512-088kl3DRT2dLU5riVMKKr1DlImd6X7smDhpXUCkJDCKvTEJeRiXh0G132HG9u5a+6Ylw9plFRY7RuTnwohYSpg==", + "version": "6.2.2", + "resolved": "https://registry.npmjs.org/inquirer/-/inquirer-6.2.2.tgz", + "integrity": "sha512-Z2rREiXA6cHRR9KBOarR3WuLlFzlIfAEIiB45ll5SSadMg7WqOh1MKEjjndfuH5ewXdixWCxqnVfGOQzPeiztA==", "dev": true, "requires": { - "ansi-escapes": "^3.0.0", - "chalk": "^2.0.0", + "ansi-escapes": "^3.2.0", + "chalk": "^2.4.2", "cli-cursor": "^2.1.0", "cli-width": "^2.0.0", - "external-editor": "^3.0.0", + "external-editor": "^3.0.3", "figures": "^2.0.0", - "lodash": "^4.17.10", + "lodash": "^4.17.11", "mute-stream": "0.0.7", "run-async": "^2.2.0", - "rxjs": "^6.1.0", + "rxjs": "^6.4.0", "string-width": "^2.1.0", "strip-ansi": "^5.0.0", "through": "^2.3.6" }, "dependencies": { "ansi-regex": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.0.0.tgz", - "integrity": "sha512-iB5Dda8t/UqpPI/IjsejXu5jOGDrzn41wJyljwPH65VCIbk6+1BzFIMJGFwTNrYXT1CrD+B4l19U7awiQ8rk7w==", + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.0.tgz", + "integrity": "sha512-1apePfXM1UOSqw0o9IiFAovVz9M5S1Dg+4TrDwfMewQ6p/rmMueb7tWZjQ1rx4Loy1ArBggoqGpfqqdI4rondg==", "dev": true }, "strip-ansi": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.0.0.tgz", - "integrity": "sha512-Uu7gQyZI7J7gn5qLn1Np3G9vcYGTVqB+lFTytnDJv83dd8T22aGH451P3jueT2/QemInJDfxHB5Tde5OzgG1Ow==", + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.1.0.tgz", + "integrity": "sha512-TjxrkPONqO2Z8QDCpeE2j6n0M6EwxzyDgzEeGp+FbdvaJAt//ClYi6W5my+3ROlC/hZX2KACUwDfK49Ka5eDvg==", "dev": true, "requires": { - "ansi-regex": "^4.0.0" + "ansi-regex": "^4.1.0" } } } @@ -1036,15 +974,6 @@ "integrity": "sha1-d8mYQFJ6qOyxqLppe4BkWnqSap0=", "dev": true }, - "is-builtin-module": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/is-builtin-module/-/is-builtin-module-1.0.0.tgz", - "integrity": "sha1-VAVy0096wxGfj3bDDLwbHgN6/74=", - "dev": true, - "requires": { - "builtin-modules": "^1.0.0" - } - }, "is-fullwidth-code-point": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz", @@ -1085,12 +1014,6 @@ "integrity": "sha512-3/xSmG/d35hf80BEN66Y6g9Ca5l/Isdeg/j6zvbTYlTzeKinzmaTM4p9am5kYqOmE05D7s1t8FGjzdSnbUbceA==", "dev": true }, - "jasmine2-custom-message": { - "version": "0.9.3", - "resolved": "https://registry.npmjs.org/jasmine2-custom-message/-/jasmine2-custom-message-0.9.3.tgz", - "integrity": "sha512-ImGW7VN9GDDPpZCwuNEpipf4cFxg7k802GN82AnesziKNPmcYwxbh4lSVcu7LqHQoVnwORDBqX3vjYKKmOzdOw==", - "dev": true - }, "js-tokens": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-4.0.0.tgz", @@ -1158,14 +1081,6 @@ "requires": { "p-locate": "^2.0.0", "path-exists": "^3.0.0" - }, - "dependencies": { - "path-exists": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-3.0.0.tgz", - "integrity": "sha1-zg6+ql94yxiSXqfYENe1mwEP1RU=", - "dev": true - } } }, "lodash": { @@ -1256,9 +1171,9 @@ } }, "ms": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", - "integrity": "sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g=", + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.1.tgz", + "integrity": "sha512-tgp+dl5cGk28utYktBsrFqA7HKgrhgPsg6Z/EfhWI4gl1Hwq8B/GmY/0oXZ6nF8hDVesS/FpnYaD/kOWhYQvyg==", "dev": true }, "mute-stream": { @@ -1289,23 +1204,17 @@ } }, "normalize-package-data": { - "version": "2.4.0", - "resolved": "https://registry.npmjs.org/normalize-package-data/-/normalize-package-data-2.4.0.tgz", - "integrity": "sha512-9jjUFbTPfEy3R/ad/2oNbKtW9Hgovl5O1FvFWKkKblNXoN/Oou6+9+KKohPK13Yc3/TyunyWhJp6gvRNR/PPAw==", + "version": "2.5.0", + "resolved": "https://registry.npmjs.org/normalize-package-data/-/normalize-package-data-2.5.0.tgz", + "integrity": "sha512-/5CMN3T0R4XTj4DcGaexo+roZSdSFW/0AOOTROrjxzCG1wrWXEsGbRKevjlIL+ZDE4sZlJr5ED4YW0yqmkK+eA==", "dev": true, "requires": { "hosted-git-info": "^2.1.4", - "is-builtin-module": "^1.0.0", + "resolve": "^1.10.0", "semver": "2 || 3 || 4 || 5", "validate-npm-package-license": "^3.0.1" } }, - "object-assign": { - "version": "4.1.1", - "resolved": "https://registry.npmjs.org/object-assign/-/object-assign-4.1.1.tgz", - "integrity": "sha1-IQmtx5ZYh8/AXLvUQsrIv7s2CGM=", - "dev": true - }, "once": { "version": "1.4.0", "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", @@ -1393,19 +1302,16 @@ } }, "parse5": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/parse5/-/parse5-1.1.3.tgz", - "integrity": "sha1-i6tY0GUl8A5ON9dVEW64LnJB8UI=", + "version": "1.5.1", + "resolved": "https://registry.npmjs.org/parse5/-/parse5-1.5.1.tgz", + "integrity": "sha1-m387DeMr543CQBsXVzzK8Pb1nZQ=", "dev": true }, "path-exists": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-2.1.0.tgz", - "integrity": "sha1-D+tsZPD8UY2adU3V77YscCJ2H0s=", - "dev": true, - "requires": { - "pinkie-promise": "^2.0.0" - } + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-3.0.0.tgz", + "integrity": "sha1-zg6+ql94yxiSXqfYENe1mwEP1RU=", + "dev": true }, "path-is-absolute": { "version": "1.0.1", @@ -1426,9 +1332,9 @@ "dev": true }, "path-parse": { - "version": "1.0.5", - "resolved": "https://registry.npmjs.org/path-parse/-/path-parse-1.0.5.tgz", - "integrity": "sha1-PBrfhx6pzWyUMbbqK9dKD/BVxME=", + "version": "1.0.6", + "resolved": "https://registry.npmjs.org/path-parse/-/path-parse-1.0.6.tgz", + "integrity": "sha512-GSmOT2EbHrINBf9SR7CDELwlJ8AENk3Qn7OikK4nFYAu3Ote2+JYNVvkpAEQm3/TLNEJFD/xZJjzyxg3KBWOzw==", "dev": true }, "path-type": { @@ -1446,36 +1352,15 @@ "integrity": "sha1-7RQaasBDqEnqWISY59yosVMw6Qw=", "dev": true }, - "pinkie": { - "version": "2.0.4", - "resolved": "https://registry.npmjs.org/pinkie/-/pinkie-2.0.4.tgz", - "integrity": "sha1-clVrgM+g1IqXToDnckjoDtT3+HA=", - "dev": true - }, - "pinkie-promise": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/pinkie-promise/-/pinkie-promise-2.0.1.tgz", - "integrity": "sha1-ITXW36ejWMBprJsXh3YogihFD/o=", - "dev": true, - "requires": { - "pinkie": "^2.0.0" - } - }, "pkg-dir": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/pkg-dir/-/pkg-dir-1.0.0.tgz", - "integrity": "sha1-ektQio1bstYp1EcFb/TpyTFM89Q=", + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/pkg-dir/-/pkg-dir-2.0.0.tgz", + "integrity": "sha1-9tXREJ4Z1j7fQo4L1X4Sd3YVM0s=", "dev": true, "requires": { - "find-up": "^1.0.0" + "find-up": "^2.1.0" } }, - "pluralize": { - "version": "7.0.0", - "resolved": "https://registry.npmjs.org/pluralize/-/pluralize-7.0.0.tgz", - "integrity": "sha512-ARhBOdzS3e41FbkW/XWrTEtukqqLoK5+Z/4UeDaLuSW+39JPeFgs4gCGqsrJHVZX0fUrx//4OF0K1CUGwlIFow==", - "dev": true - }, "prelude-ls": { "version": "1.1.2", "resolved": "https://registry.npmjs.org/prelude-ls/-/prelude-ls-1.1.2.tgz", @@ -1509,6 +1394,12 @@ "integrity": "sha512-XRsRjdf+j5ml+y/6GKHPZbrF/8p2Yga0JPtdqTIY2Xe5ohJPD9saDJJLPvp9+NSBprVvevdXZybnj2cv8OEd0A==", "dev": true }, + "q": { + "version": "1.5.1", + "resolved": "https://registry.npmjs.org/q/-/q-1.5.1.tgz", + "integrity": "sha1-fjL3W0E4EpHQRhHxvxQQmsAGUdc=", + "dev": true + }, "qs": { "version": "6.5.1", "resolved": "https://registry.npmjs.org/qs/-/qs-6.5.1.tgz", @@ -1534,17 +1425,6 @@ "requires": { "find-up": "^2.0.0", "read-pkg": "^2.0.0" - }, - "dependencies": { - "find-up": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/find-up/-/find-up-2.1.0.tgz", - "integrity": "sha1-RdG35QbHF93UgndaK3eSCjwMV6c=", - "dev": true, - "requires": { - "locate-path": "^2.0.0" - } - } } }, "regexpp": { @@ -1560,12 +1440,12 @@ "dev": true }, "resolve": { - "version": "1.5.0", - "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.5.0.tgz", - "integrity": "sha512-hgoSGrc3pjzAPHNBg+KnFcK2HwlHTs/YrAGUr6qgTVUZmXv1UEXXl0bZNBKMA9fud6lRYFdPGz0xXxycPzmmiw==", + "version": "1.10.0", + "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.10.0.tgz", + "integrity": "sha512-3sUr9aq5OfSg2S9pNtPA9hL1FVEAjvfOC4leW0SNf/mpnaakz2a9femSd6LqAww2RaFctwyf1lCqnTHuF1rxDg==", "dev": true, "requires": { - "path-parse": "^1.0.5" + "path-parse": "^1.0.6" } }, "resolve-from": { @@ -1603,9 +1483,9 @@ } }, "rxjs": { - "version": "6.3.3", - "resolved": "https://registry.npmjs.org/rxjs/-/rxjs-6.3.3.tgz", - "integrity": "sha512-JTWmoY9tWCs7zvIk/CvRjhjGaOd+OVBM987mxFo+OW66cGpdKjZcpmc74ES1sB//7Kl/PAe8+wEakuhG4pcgOw==", + "version": "6.4.0", + "resolved": "https://registry.npmjs.org/rxjs/-/rxjs-6.4.0.tgz", + "integrity": "sha512-Z9Yfa11F6B9Sg/BK9MnqnQ+aQYicPLtilXBp2yUtDt2JRCE0h26d33EnfO3ZxoNxG0T92OUucP3Ct7cpfkdFfw==", "dev": true, "requires": { "tslib": "^1.9.0" @@ -1651,9 +1531,9 @@ "dev": true }, "slice-ansi": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/slice-ansi/-/slice-ansi-2.0.0.tgz", - "integrity": "sha512-4j2WTWjp3GsZ+AOagyzVbzp4vWGtZ0hEZ/gDY/uTvm6MTxUfTUIsnMIFb1bn8o0RuXiqUw15H1bue8f22Vw2oQ==", + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/slice-ansi/-/slice-ansi-2.1.0.tgz", + "integrity": "sha512-Qu+VC3EwYLldKa1fCxuuvULvSJOKEgk9pi8dZeCVK7TqBfUNTH4sFkk4joj8afVSfAYgJoSOetjx9QWOJ5mYoQ==", "dev": true, "requires": { "ansi-styles": "^3.2.0", @@ -1668,9 +1548,9 @@ "dev": true }, "spdx-correct": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/spdx-correct/-/spdx-correct-3.0.0.tgz", - "integrity": "sha512-N19o9z5cEyc8yQQPukRCZ9EUmb4HUpnrmaL/fxS2pBo2jbfcFRVuFZ/oFC+vZz0MNNk0h80iMn5/S6qGZOL5+g==", + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/spdx-correct/-/spdx-correct-3.1.0.tgz", + "integrity": "sha512-lr2EZCctC2BNR7j7WzJ2FpDznxky1sjfxvvYEyzxNyb6lZXHODmEoJeFu4JupYlkfha1KZpJyoqiJ7pgA1qq8Q==", "dev": true, "requires": { "spdx-expression-parse": "^3.0.0", @@ -1678,9 +1558,9 @@ } }, "spdx-exceptions": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/spdx-exceptions/-/spdx-exceptions-2.1.0.tgz", - "integrity": "sha512-4K1NsmrlCU1JJgUrtgEeTVyfx8VaYea9J9LvARxhbHtVtohPs/gFGG5yy49beySjlIMhhXZ4QqujIZEfS4l6Cg==", + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/spdx-exceptions/-/spdx-exceptions-2.2.0.tgz", + "integrity": "sha512-2XQACfElKi9SlVb1CYadKDXvoajPgBVPn/gOQLrTvHdElaVhr7ZEbqJaRnJLVNeaI4cMEAgVCeBMKF6MWRDCRA==", "dev": true }, "spdx-expression-parse": { @@ -1694,9 +1574,9 @@ } }, "spdx-license-ids": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/spdx-license-ids/-/spdx-license-ids-3.0.0.tgz", - "integrity": "sha512-2+EPwgbnmOIl8HjGBXXMd9NAu02vLjOO1nWw4kmeRDFyHn+M/ETfHxQUK0oXg8ctgVnl9t3rosNVsZ1jG61nDA==", + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/spdx-license-ids/-/spdx-license-ids-3.0.3.tgz", + "integrity": "sha512-uBIcIl3Ih6Phe3XHK1NqboJLdGfwr1UN3k6wSD1dZpmPsIkb8AGNbZYJ1fOBk834+Gxy8rpfDxrS6XLEMZMY2g==", "dev": true }, "sprintf-js": { @@ -1742,6 +1622,15 @@ "integrity": "sha1-PFMZQukIwml8DsNEhYwobHygpgo=", "dev": true }, + "supports-color": { + "version": "5.5.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz", + "integrity": "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==", + "dev": true, + "requires": { + "has-flag": "^3.0.0" + } + }, "sync-request": { "version": "6.0.0", "resolved": "https://registry.npmjs.org/sync-request/-/sync-request-6.0.0.tgz", @@ -1763,15 +1652,43 @@ } }, "table": { - "version": "5.2.0", - "resolved": "https://registry.npmjs.org/table/-/table-5.2.0.tgz", - "integrity": "sha512-hAdBBAMCZl4/U3eQhsPN2Z8wRJC98lpRhDW2I86VQbPBqyj4E681VhvUkfb90qUJ4rnRfu8t4/8SGHPsAH1ygg==", + "version": "5.2.3", + "resolved": "https://registry.npmjs.org/table/-/table-5.2.3.tgz", + "integrity": "sha512-N2RsDAMvDLvYwFcwbPyF3VmVSSkuF+G1e+8inhBLtHpvwXGw4QRPEZhihQNeEN0i1up6/f6ObCJXNdlRG3YVyQ==", "dev": true, "requires": { - "ajv": "^6.6.1", + "ajv": "^6.9.1", "lodash": "^4.17.11", - "slice-ansi": "2.0.0", - "string-width": "^2.1.1" + "slice-ansi": "^2.1.0", + "string-width": "^3.0.0" + }, + "dependencies": { + "ansi-regex": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.0.tgz", + "integrity": "sha512-1apePfXM1UOSqw0o9IiFAovVz9M5S1Dg+4TrDwfMewQ6p/rmMueb7tWZjQ1rx4Loy1ArBggoqGpfqqdI4rondg==", + "dev": true + }, + "string-width": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz", + "integrity": "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==", + "dev": true, + "requires": { + "emoji-regex": "^7.0.1", + "is-fullwidth-code-point": "^2.0.0", + "strip-ansi": "^5.1.0" + } + }, + "strip-ansi": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.1.0.tgz", + "integrity": "sha512-TjxrkPONqO2Z8QDCpeE2j6n0M6EwxzyDgzEeGp+FbdvaJAt//ClYi6W5my+3ROlC/hZX2KACUwDfK49Ka5eDvg==", + "dev": true, + "requires": { + "ansi-regex": "^4.1.0" + } + } } }, "text-table": { @@ -1890,6 +1807,33 @@ "spdx-expression-parse": "^3.0.0" } }, + "vow": { + "version": "0.4.19", + "resolved": "https://registry.npmjs.org/vow/-/vow-0.4.19.tgz", + "integrity": "sha512-S+0+CiQlbUhTNWMlJdqo/ARuXOttXdvw5ACGyh1W97NFHUdwt3Fzyaus03Kvdmo733dwnYS9AGJSDg0Zu8mNfA==", + "dev": true + }, + "vow-fs": { + "version": "0.3.6", + "resolved": "https://registry.npmjs.org/vow-fs/-/vow-fs-0.3.6.tgz", + "integrity": "sha1-LUxZviLivyYY3fWXq0uqkjvnIA0=", + "dev": true, + "requires": { + "glob": "^7.0.5", + "uuid": "^2.0.2", + "vow": "^0.4.7", + "vow-queue": "^0.4.1" + } + }, + "vow-queue": { + "version": "0.4.3", + "resolved": "https://registry.npmjs.org/vow-queue/-/vow-queue-0.4.3.tgz", + "integrity": "sha512-/poAKDTFL3zYbeQg7cl4BGcfP4sGgXKrHnRFSKj97dteUFu8oyXMwIcdwu8NSx/RmPGIuYx1Bik/y5vU4H/VKw==", + "dev": true, + "requires": { + "vow": "^0.4.17" + } + }, "vuln-regex-detector": { "version": "1.3.0", "resolved": "https://registry.npmjs.org/vuln-regex-detector/-/vuln-regex-detector-1.3.0.tgz", @@ -1921,9 +1865,9 @@ "dev": true }, "write": { - "version": "0.2.1", - "resolved": "https://registry.npmjs.org/write/-/write-0.2.1.tgz", - "integrity": "sha1-X8A4KOJkzqP+kUVUdvejxWbLB1c=", + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/write/-/write-1.0.3.tgz", + "integrity": "sha512-/lg70HAjtkUgWPVZhZcm+T4hkL8Zbtp1nFNOn3lRrxnlv50SRBv7cR7RqR+GMsd3hUXy9hWBo4CHTbFTcOYwig==", "dev": true, "requires": { "mkdirp": "^0.5.1" diff --git a/package.json b/package.json index 4898340dc3..a1ef0139a6 100644 --- a/package.json +++ b/package.json @@ -30,18 +30,17 @@ ], "devDependencies": { "commonmark": "0.x", - "eslint": "^5.12.0", + "eslint": "^5.15.1", "eslint-config-standard": "^12.0.0", - "eslint-plugin-import": "^2.14.0", + "eslint-plugin-import": "^2.16.0", "eslint-plugin-node": "^8.0.1", "eslint-plugin-promise": "^4.0.1", "eslint-plugin-standard": "^4.0.0", "eslint-plugin-vuln-regex-detector": "^1.0.4", "front-matter": "^3.0.1", "glob-to-regexp": "^0.4.0", - "@markedjs/html-differ": "^2.0.0", + "@markedjs/html-differ": "^2.0.1", "jasmine": "^3.3.1", - "jasmine2-custom-message": "^0.9.3", "markdown": "0.x", "markdown-it": "8.x", "uglify-js": "^3.4.9" @@ -56,6 +55,7 @@ "test:old": "node test", "test:lint": "eslint bin/marked .", "test:redos": "eslint --plugin vuln-regex-detector --rule '\"vuln-regex-detector/no-vuln-regex\": 2' lib/marked.js", + "test:node4": "npx node@4 ./node_modules/jasmine/bin/jasmine.js --config=jasmine.json", "bench": "node test --bench", "lint": "eslint --fix bin/marked .", "build": "uglifyjs lib/marked.js -cm --comments /Copyright/ -o marked.min.js", diff --git a/test/helpers/helpers.js b/test/helpers/helpers.js index d9244a880b..c5ef733e91 100644 --- a/test/helpers/helpers.js +++ b/test/helpers/helpers.js @@ -1,5 +1,44 @@ -var marked = require('../../lib/marked.js'); +const marked = require('../../'); +const HtmlDiffer = require('@markedjs/html-differ').HtmlDiffer; +const htmlDiffer = new HtmlDiffer({ignoreSelfClosingSlash: true}); -beforeEach(function () { +const EXCERPT_LENGTH = 30; + +beforeEach(() => { marked.setOptions(marked.getDefaults()); + + jasmine.addMatchers({ + toRender: () => { + return { + compare: (spec, expected) => { + const result = {}; + const actual = marked(spec.markdown, spec.options); + result.pass = htmlDiffer.isEqual(expected, actual); + + if (result.pass) { + result.message = spec.markdown + '\n------\n\nExpected: Should Fail'; + } else { + var expectedHtml = expected.replace(/\s/g, ''); + var actualHtml = actual.replace(/\s/g, ''); + + for (var i = 0; i < expectedHtml.length; i++) { + if (actualHtml[i] !== expectedHtml[i]) { + actualHtml = actualHtml.substring( + Math.max(i - EXCERPT_LENGTH, 0), + Math.min(i + EXCERPT_LENGTH, actualHtml.length)); + + expectedHtml = expectedHtml.substring( + Math.max(i - EXCERPT_LENGTH, 0), + Math.min(i + EXCERPT_LENGTH, expectedHtml.length)); + + break; + } + } + result.message = 'Expected:\n' + expectedHtml + '\n\nActual:\n' + actualHtml; + } + return result; + } + }; + } + }); }); diff --git a/test/index.js b/test/index.js index 29b19bc5de..7e8f5e3af3 100644 --- a/test/index.js +++ b/test/index.js @@ -176,6 +176,17 @@ function testFile(engine, file, filename, index) { l = html.length; + if (l === 0 && text.length > 0) { + text = text.substring(0, Math.min(30, text.length)); + + console.log(' failed in %dms at offset %d. Near: "%s".\n', prettyElapsedTime(elapsed), 0, text); + + console.log('\nActual:\n%s\n', text.trim() || text); + console.log('\nExpected:\n\n'); + + return false; + } + for (j = 0; j < l; j++) { if (text[j] !== html[j]) { text = text.substring( @@ -188,7 +199,7 @@ function testFile(engine, file, filename, index) { console.log(' failed in %dms at offset %d. Near: "%s".\n', prettyElapsedTime(elapsed), j, text); - console.log('\nGot:\n%s\n', text.trim() || text); + console.log('\nActual:\n%s\n', text.trim() || text); console.log('\nExpected:\n%s\n', html.trim() || html); return false; @@ -346,11 +357,11 @@ function time(options) { */ function fix() { - ['compiled_tests', 'original', 'new'].forEach(function(dir) { + ['compiled_tests', 'original', 'new', 'redos'].forEach(function(dir) { try { fs.mkdirSync(path.resolve(__dirname, dir)); } catch (e) { - ; + // directory already exists } }); @@ -393,20 +404,6 @@ function fix() { .replace(/&__QUOT__;/g, '"') .replace(/&__APOS__;/g, '\''); - // add heading id's - html = html.replace(/<(h[1-6])>([^<]+)<\/\1>/g, function(s, h, text) { - var id = text - .replace(/'/g, '\'') - .replace(/"/g, '"') - .replace(/>/g, '>') - .replace(/</g, '<') - .replace(/&/g, '&'); - - id = id.toLowerCase().replace(/[^\w]+/g, '-'); - - return '<' + h + ' id="' + id + '">' + text + '' + h + '>'; - }); - fs.writeFileSync(file, html); }); @@ -435,6 +432,12 @@ function fix() { fs.writeFileSync(path.resolve(__dirname, 'compiled_tests', file), fs.readFileSync(path.resolve(__dirname, 'new', file))); }); + + // cp redos/* tests/ + fs.readdirSync(path.resolve(__dirname, 'redos')).forEach(function(file) { + fs.writeFileSync(path.resolve(__dirname, 'compiled_tests', file), + fs.readFileSync(path.resolve(__dirname, 'redos', file))); + }); } /** diff --git a/test/json-to-files.js b/test/json-to-files.js new file mode 100644 index 0000000000..d7e72aafe0 --- /dev/null +++ b/test/json-to-files.js @@ -0,0 +1,62 @@ +const path = require('path'); +const fs = require('fs'); + +const folder = process.argv[2]; +const jsonFile = process.argv[3]; + +if (!folder || !jsonFile) { + console.log('node ./json-to-files.js {path to folder} {path to json file}'); + process.exit(1); +} + +const specs = require(jsonFile); + +const files = specs.reduce((obj, spec) => { + if (!obj[spec.section]) { + obj[spec.section] = { + md: [], + html: [], + options: {} + }; + } + + obj[spec.section].md.push(spec.markdown); + obj[spec.section].html.push(spec.html); + Object.assign(obj[spec.section].options, spec.options); + + return obj; +}, {}); + +try { + fs.mkdirSync(folder, {recursive: true}); +} catch (ex) { + // already exists +} + +for (const section in files) { + const file = files[section]; + const name = section.toLowerCase().replace(' ', '_'); + const frontMatter = Object.keys(file.options).map(opt => { + let value = file.options[opt]; + if (typeof value !== 'string') { + value = JSON.stringify(value); + } + return `${opt}: ${value}`; + }).join('\n'); + + let markdown = file.md.join('\n\n'); + if (frontMatter) { + markdown = `---\n${frontMatter}\n---\n\n${markdown}`; + } + const html = file.html.join('\n\n'); + + const mdFile = path.resolve(folder, `${name}.md`); + const htmlFile = path.resolve(folder, `${name}.html`); + + if (fs.existsSync(mdFile) || fs.existsSync(htmlFile)) { + throw new Error(`${name} already exists.`); + } + + fs.writeFileSync(mdFile, markdown); + fs.writeFileSync(htmlFile, html); +} diff --git a/test/new/autolinks.html b/test/new/autolinks.html new file mode 100644 index 0000000000..8fa4837e61 --- /dev/null +++ b/test/new/autolinks.html @@ -0,0 +1,15 @@ +
(See https://www.example.com/fhqwhgads.)
+ +((http://foo.com))
+ +((http://foo.com.))
+ + + + + + + + + + \ No newline at end of file diff --git a/test/new/autolinks.md b/test/new/autolinks.md new file mode 100644 index 0000000000..1f5f739c49 --- /dev/null +++ b/test/new/autolinks.md @@ -0,0 +1,15 @@ +(See https://www.example.com/fhqwhgads.) + +((http://foo.com)) + +((http://foo.com.)) + +HTTP://FOO.COM + +hTtP://fOo.CoM + +~~hello@email.com~~ + +**me@example.com** + +__test@test.com__ \ No newline at end of file diff --git a/test/new/code_spans.html b/test/new/code_spans.html new file mode 100644 index 0000000000..ca220d8043 --- /dev/null +++ b/test/new/code_spans.html @@ -0,0 +1,3 @@ +someone@example.com
``test`
\ No newline at end of file diff --git a/test/new/code_spans.md b/test/new/code_spans.md new file mode 100644 index 0000000000..845a116ae7 --- /dev/null +++ b/test/new/code_spans.md @@ -0,0 +1,3 @@ +`someone@example.com` + +``*test`* \ No newline at end of file diff --git a/test/new/emphasis_extra tests.html b/test/new/emphasis_extra tests.html new file mode 100644 index 0000000000..0e2609cdbd --- /dev/null +++ b/test/new/emphasis_extra tests.html @@ -0,0 +1 @@ +test. test: test! test? test-
\ No newline at end of file diff --git a/test/new/emphasis_extra tests.md b/test/new/emphasis_extra tests.md new file mode 100644 index 0000000000..bf8afdc7d1 --- /dev/null +++ b/test/new/emphasis_extra tests.md @@ -0,0 +1 @@ +_test_. _test_: _test_! _test_? _test_- \ No newline at end of file diff --git a/test/new/links.html b/test/new/links.html index 092ea471a0..c3cbaa0cd8 100644 --- a/test/new/links.html +++ b/test/new/links.html @@ -1,5 +1,3 @@ -URL
-URL
-URL
-URL
-URL
+Link: constructor.
+ + diff --git a/test/new/links.md b/test/new/links.md index 1850be4e9f..f53cbf13d1 100644 --- a/test/new/links.md +++ b/test/new/links.md @@ -1,12 +1,5 @@ ---- -sanitize: true ---- -[URL](javascript:alert) +Link: [constructor][]. -[URL](vbscript:alert) +[One](https://example.com/1) ([Two](https://example.com/2)) [Three](https://example.com/3) -[URL](javascript:alert(1)) - -[URL](javascript:document;alert(1)) - -[URL](data:text/html;base64,PHNjcmlwdD5hbGVydCgnWFNTJyk8L3NjcmlwdD4K) +[constructor]: https://example.org/ diff --git a/test/new/redos_html_closing.html b/test/new/redos_html_closing.html deleted file mode 100644 index e69de29bb2..0000000000 diff --git a/test/new/redos_nolink.html b/test/new/redos_nolink.html deleted file mode 100644 index e69de29bb2..0000000000 diff --git a/test/new/sanitize_links.html b/test/new/sanitize_links.html new file mode 100644 index 0000000000..092ea471a0 --- /dev/null +++ b/test/new/sanitize_links.html @@ -0,0 +1,5 @@ +URL
+URL
+URL
+URL
+URL
diff --git a/test/new/sanitize_links.md b/test/new/sanitize_links.md new file mode 100644 index 0000000000..1850be4e9f --- /dev/null +++ b/test/new/sanitize_links.md @@ -0,0 +1,12 @@ +--- +sanitize: true +--- +[URL](javascript:alert) + +[URL](vbscript:alert) + +[URL](javascript:alert(1)) + +[URL](javascript:document;alert(1)) + +[URL](data:text/html;base64,PHNjcmlwdD5hbGVydCgnWFNTJyk8L3NjcmlwdD4K) diff --git a/test/new/table_cells.html b/test/new/table_cells.html new file mode 100644 index 0000000000..694f7dddea --- /dev/null +++ b/test/new/table_cells.html @@ -0,0 +1,27 @@ +1 |
---|
1 |
1 |
---|
| |
1 |
---|
1\1 |
1 |
---|
\\ |
1 |
---|
\\| |
1 | 2 |
---|---|
2 |
1 | 2 |
---|---|
1|\ | 2|\ |
1 | 2 |
---|---|
2 |
1 | 2 |
---|---|
1|\ | 2|\ |
1 | 2 |
---|---|
2 |
1 | 2 |
---|---|
1 | 2| |
1 | 2 |
---|---|
1 | 2| |
1 | 2 |
---|---|
1 | 2| |
1 | 2 |
---|---|
1 | 2| |
A single backtick in a code span: `
A backtick-delimited string in a code span: `foo`
<tag "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" "" ""<" />a'a
diff --git a/test/new/redos_html_closing.md b/test/redos/redos_html_closing.md similarity index 100% rename from test/new/redos_html_closing.md rename to test/redos/redos_html_closing.md diff --git a/test/redos/redos_nolink.html b/test/redos/redos_nolink.html new file mode 100644 index 0000000000..5915375324 --- /dev/null +++ b/test/redos/redos_nolink.html @@ -0,0 +1 @@ +![[[][[][[][[][[][[][[][[][[][[][[][[][[][[][[][[][[][[][[][[][[][[][[][[][[][[][[][[][[][[][[][[][[][[][[][[][[][[][[][[][[][[][[]!\
diff --git a/test/new/redos_nolink.md b/test/redos/redos_nolink.md similarity index 100% rename from test/new/redos_nolink.md rename to test/redos/redos_nolink.md diff --git a/test/specs/commonmark/commonmark-spec.js b/test/specs/commonmark/commonmark-spec.js deleted file mode 100644 index ec270bb831..0000000000 --- a/test/specs/commonmark/commonmark-spec.js +++ /dev/null @@ -1,454 +0,0 @@ -var marked = require('../../../lib/marked.js'); -var cmSpec = require('./commonmark.0.28.json'); -var HtmlDiffer = require('@markedjs/html-differ').HtmlDiffer, - htmlDiffer = new HtmlDiffer({ignoreSelfClosingSlash: true}); -var since = require('jasmine2-custom-message'); - -var Messenger = function() {}; - -Messenger.prototype.message = function(spec, expected, actual) { - return 'CommonMark (' + spec.section + '):\n' + spec.markdown + '\n------\n\nExpected:\n' + expected + '\n------\n\nMarked:\n' + actual; -}; - -Messenger.prototype.test = function(spec, section, ignore) { - if (spec.section === section) { - var shouldFail = ~ignore.indexOf(spec.example); - it('should ' + (shouldFail ? 'fail' : 'pass') + ' example ' + spec.example, function() { - var expected = spec.html; - var actual = marked(spec.markdown, { headerIds: false, xhtml: true }); - since(messenger.message(spec, expected, actual)).expect( - htmlDiffer.isEqual(expected, actual) - ).toEqual(!shouldFail); - }); - } -}; - -var messenger = new Messenger(); -/* -|Section |Count |Percent | -|:---------------------------------------|:---------:|-------:| -|Tabs | 10 of 11 | 91%| -|Precedence | 1 of 1 | 100%| -|Thematic breaks | 19 of 19 | 100%| -|ATX headings | 14 of 18 | 78%| -|Setext headings | 21 of 26 | 81%| -|Indented code blocks | 12 of 12 | 100%| -|Fenced code blocks | 21 of 28 | 75%| -|HTML blocks | 43 of 43 | 100%| -|Link reference definitions | 22 of 23 | 96%| -|Paragraphs | 8 of 8 | 100%| -|Blank lines | 1 of 1 | 100%| -|Block quotes | 21 of 25 | 84%| -|List items | 32 of 48 | 67%| -|Lists | 12 of 24 | 50%| -|Inlines | 1 of 1 | 100%| -|Backslash escapes | 10 of 13 | 77%| -|Entity and numeric character references | 9 of 12 | 75%| -|Code spans | 11 of 17 | 65%| -|Emphasis and strong emphasis | 79 of 128 | 61%| -|Links | 69 of 84 | 82%| -|Images | 15 of 22 | 68%| -|Autolinks | 15 of 19 | 79%| -|Raw HTML | 19 of 21 | 90%| -|Hard line breaks | 15 of 15 | 100%| -|Soft line breaks | 2 of 2 | 100%| -|Textual content | 3 of 3 | 100%| -*/ - -describe('CommonMark 0.28 Tabs', function() { - var section = 'Tabs'; - - // These examples probably should pass but don't for some reason. - // This is the easiest way to demonstrate limitations or defects - // within Marked. Toggle comments for next two lines to see which examples - // are known failures. Note: If all arrays are empty, it means Marked is - // 100% compliant with that section of the given specification. - // - // var shouldPassButFails = []; - var shouldPassButFails = [7]; - - // Identifies examples that the Marked core team has determined beyond - // the ability or desire to correct; thereby, implicitly requesting - // outside help and assistance. - var willNotBeAttemptedByCoreTeam = []; - - // Combine known failures and skips. - var ignore = shouldPassButFails.concat(willNotBeAttemptedByCoreTeam); - - cmSpec.forEach(function(spec) { - // Run test. - messenger.test(spec, section, ignore); - }); -}); - -describe('CommonMark 0.28 Precedence', function() { - var section = 'Precedence'; - - // var shouldPassButFails = []; - var shouldPassButFails = []; - - var willNotBeAttemptedByCoreTeam = []; - - var ignore = shouldPassButFails.concat(willNotBeAttemptedByCoreTeam); - - cmSpec.forEach(function(spec) { - messenger.test(spec, section, ignore); - }); -}); - -describe('CommonMark 0.28 Thematic breaks', function() { - var section = 'Thematic breaks'; - - // var shouldPassButFails = []; - var shouldPassButFails = []; - - var willNotBeAttemptedByCoreTeam = []; - - var ignore = shouldPassButFails.concat(willNotBeAttemptedByCoreTeam); - - cmSpec.forEach(function(spec) { - messenger.test(spec, section, ignore); - }); -}); - -describe('CommonMark 0.28 ATX headings', function() { - var section = 'ATX headings'; - - // var shouldPassButFails = []; - var shouldPassButFails = [40, 45, 46, 49]; - - var willNotBeAttemptedByCoreTeam = []; - - var ignore = shouldPassButFails.concat(willNotBeAttemptedByCoreTeam); - - cmSpec.forEach(function(spec) { - messenger.test(spec, section, ignore); - }); -}); - -describe('CommonMark 0.28 Setext headings', function() { - var section = 'Setext headings'; - - // var shouldPassButFails = []; - var shouldPassButFails = [51, 52, 56, 62, 64]; - - var willNotBeAttemptedByCoreTeam = []; - - var ignore = shouldPassButFails.concat(willNotBeAttemptedByCoreTeam); - - cmSpec.forEach(function(spec) { - messenger.test(spec, section, ignore); - }); -}); - -describe('CommonMark 0.28 Indented code blocks', function() { - var section = 'Indented code blocks'; - - // var shouldPassButFails = []; - var shouldPassButFails = []; - - var willNotBeAttemptedByCoreTeam = []; - - var ignore = shouldPassButFails.concat(willNotBeAttemptedByCoreTeam); - - cmSpec.forEach(function(spec) { - messenger.test(spec, section, ignore); - }); -}); - -describe('CommonMark 0.28 Fenced code blocks', function() { - var section = 'Fenced code blocks'; - - var shouldPassButFails = []; - - var willNotBeAttemptedByCoreTeam = []; - - var ignore = shouldPassButFails.concat(willNotBeAttemptedByCoreTeam); - - cmSpec.forEach(function(spec) { - messenger.test(spec, section, ignore); - }); -}); - -describe('CommonMark 0.28 HTML blocks', function() { - var section = 'HTML blocks'; - - var shouldPassButFails = []; - - var willNotBeAttemptedByCoreTeam = []; - - var ignore = shouldPassButFails.concat(willNotBeAttemptedByCoreTeam); - - cmSpec.forEach(function(spec) { - messenger.test(spec, section, ignore); - }); -}); - -describe('CommonMark 0.28 Link reference definitions', function() { - var section = 'Link reference definitions'; - - // var shouldPassButFails = []; - var shouldPassButFails = [167]; - - var willNotBeAttemptedByCoreTeam = []; - - var ignore = shouldPassButFails.concat(willNotBeAttemptedByCoreTeam); - - cmSpec.forEach(function(spec) { - messenger.test(spec, section, ignore); - }); -}); - -describe('CommonMark 0.28 Paragraphs', function() { - var section = 'Paragraphs'; - - // var shouldPassButFails = []; - var shouldPassButFails = []; - - var willNotBeAttemptedByCoreTeam = []; - - var ignore = shouldPassButFails.concat(willNotBeAttemptedByCoreTeam); - - cmSpec.forEach(function(spec) { - messenger.test(spec, section, ignore); - }); -}); - -describe('CommonMark 0.28 Blank lines', function() { - var section = 'Blank lines'; - - // var shouldPassButFails = []; - var shouldPassButFails = []; - - var willNotBeAttemptedByCoreTeam = []; - - var ignore = shouldPassButFails.concat(willNotBeAttemptedByCoreTeam); - - cmSpec.forEach(function(spec) { - messenger.test(spec, section, ignore); - }); -}); - -describe('CommonMark 0.28 Block quotes', function() { - var section = 'Block quotes'; - - // var shouldPassButFails = []; - var shouldPassButFails = [198, 199, 200]; - - var willNotBeAttemptedByCoreTeam = []; - - var ignore = shouldPassButFails.concat(willNotBeAttemptedByCoreTeam); - - cmSpec.forEach(function(spec) { - messenger.test(spec, section, ignore); - }); -}); - -describe('CommonMark 0.28 List items', function() { - var section = 'List items'; - - // var shouldPassButFails = []; - var shouldPassButFails = [237, 236, 227, 218, 243, 259, 241, 239, 247, 225, 220, 258, 260]; - - var willNotBeAttemptedByCoreTeam = []; - - var ignore = shouldPassButFails.concat(willNotBeAttemptedByCoreTeam); - - cmSpec.forEach(function(spec) { - messenger.test(spec, section, ignore); - }); -}); - -describe('CommonMark 0.28 Lists', function() { - var section = 'Lists'; - - // var shouldPassButFails = []; - var shouldPassButFails = [282, 270, 280, 278, 273, 274, 264, 265, 279, 267, 269]; - - var willNotBeAttemptedByCoreTeam = []; - - var ignore = shouldPassButFails.concat(willNotBeAttemptedByCoreTeam); - - cmSpec.forEach(function(spec) { - messenger.test(spec, section, ignore); - }); -}); - -describe('CommonMark 0.28 Inlines', function() { - var section = 'Inlines'; - - // var shouldPassButFails = []; - var shouldPassButFails = []; - - var willNotBeAttemptedByCoreTeam = []; - - var ignore = shouldPassButFails.concat(willNotBeAttemptedByCoreTeam); - - cmSpec.forEach(function(spec) { - messenger.test(spec, section, ignore); - }); -}); - -describe('CommonMark 0.28 Backslash escapes', function() { - var section = 'Backslash escapes'; - - // var shouldPassButFails = []; - var shouldPassButFails = [300, 301]; - - var willNotBeAttemptedByCoreTeam = []; - - var ignore = shouldPassButFails.concat(willNotBeAttemptedByCoreTeam); - - cmSpec.forEach(function(spec) { - messenger.test(spec, section, ignore); - }); -}); - -describe('CommonMark 0.28 Entity and numeric character references', function() { - var section = 'Entity and numeric character references'; - - // var shouldPassButFails = []; - var shouldPassButFails = [311, 309, 310]; - - var willNotBeAttemptedByCoreTeam = []; - - var ignore = shouldPassButFails.concat(willNotBeAttemptedByCoreTeam); - - cmSpec.forEach(function(spec) { - messenger.test(spec, section, ignore); - }); -}); - -describe('CommonMark 0.28 Code spans', function() { - var section = 'Code spans'; - - var shouldPassButFails = [322, 323]; - - var willNotBeAttemptedByCoreTeam = []; - - var ignore = shouldPassButFails.concat(willNotBeAttemptedByCoreTeam); - - cmSpec.forEach(function(spec) { - messenger.test(spec, section, ignore); - }); -}); - -describe('CommonMark 0.28 Emphasis and strong emphasis', function() { - var section = 'Emphasis and strong emphasis'; - - // var shouldPassButFails = []; - var shouldPassButFails = [334, 342, 348, 349, 352, 353, 360, 368, 369, 371, 372, 378, 380, 381, 382, 387, 388, 392, 393, 394, 395, 396, 402, 403, 409, 419, 420, 421, 422, 423, 424, 431, 432, 433, 434, 435, 436, 443, 444, 445, 448, 449, 453, 454, 455, 457, 458]; - - var willNotBeAttemptedByCoreTeam = []; - - var ignore = shouldPassButFails.concat(willNotBeAttemptedByCoreTeam); - - cmSpec.forEach(function(spec) { - messenger.test(spec, section, ignore); - }); -}); - -describe('CommonMark 0.28 Links', function() { - var section = 'Links'; - - // var shouldPassButFails = []; - var shouldPassButFails = [474, 478, 483, 489, 490, 491, 495, 496, 497, 499, 503, 504, 507, 508, 509]; - - var willNotBeAttemptedByCoreTeam = []; - - var ignore = shouldPassButFails.concat(willNotBeAttemptedByCoreTeam); - - cmSpec.forEach(function(spec) { - messenger.test(spec, section, ignore); - }); -}); - -describe('CommonMark 0.28 Images', function() { - var section = 'Images'; - - // var shouldPassButFails = []; - var shouldPassButFails = [544, 545, 546, 547, 548, 556, 560]; - - var willNotBeAttemptedByCoreTeam = []; - - var ignore = shouldPassButFails.concat(willNotBeAttemptedByCoreTeam); - - cmSpec.forEach(function(spec) { - messenger.test(spec, section, ignore); - }); -}); - -describe('CommonMark 0.28 Autolinks', function() { - var section = 'Autolinks'; - - // var shouldPassButFails = []; - var shouldPassButFails = [582, 573, 579, 583]; - - var willNotBeAttemptedByCoreTeam = []; - - var ignore = shouldPassButFails.concat(willNotBeAttemptedByCoreTeam); - - cmSpec.forEach(function(spec) { - messenger.test(spec, section, ignore); - }); -}); - -describe('CommonMark 0.28 Raw HTML', function() { - var section = 'Raw HTML'; - - // var shouldPassButFails = []; - var shouldPassButFails = [597, 598]; - - var willNotBeAttemptedByCoreTeam = []; - - var ignore = shouldPassButFails.concat(willNotBeAttemptedByCoreTeam); - - cmSpec.forEach(function(spec) { - messenger.test(spec, section, ignore); - }); -}); - -describe('CommonMark 0.28 Hard line breaks', function() { - var section = 'Hard line breaks'; - - // var shouldPassButFails = []; - var shouldPassButFails = []; - - var willNotBeAttemptedByCoreTeam = []; - - var ignore = shouldPassButFails.concat(willNotBeAttemptedByCoreTeam); - - cmSpec.forEach(function(spec) { - messenger.test(spec, section, ignore); - }); -}); - -describe('CommonMark 0.28 Soft line breaks', function() { - var section = 'Soft line breaks'; - - // var shouldPassButFails = []; - var shouldPassButFails = []; - - var willNotBeAttemptedByCoreTeam = []; - - var ignore = shouldPassButFails.concat(willNotBeAttemptedByCoreTeam); - - cmSpec.forEach(function(spec) { - messenger.test(spec, section, ignore); - }); -}); - -describe('CommonMark 0.28 Textual content', function() { - var section = 'Textual content'; - - // var shouldPassButFails = []; - var shouldPassButFails = []; - - var willNotBeAttemptedByCoreTeam = []; - - var ignore = shouldPassButFails.concat(willNotBeAttemptedByCoreTeam); - - cmSpec.forEach(function(spec) { - messenger.test(spec, section, ignore); - }); -}); diff --git a/test/specs/commonmark/commonmark.0.28.json b/test/specs/commonmark/commonmark.0.28.json index ec9a9fe15b..5b5001cd79 100644 --- a/test/specs/commonmark/commonmark.0.28.json +++ b/test/specs/commonmark/commonmark.0.28.json @@ -53,7 +53,8 @@ "html": " foo\n
\nfoo\n# bar
\n", "markdown": "foo\n # bar\n", "example": 40, - "start_line": 860 + "start_line": 860, + "shouldFail": true }, { "end_line": 877, @@ -357,7 +359,8 @@ "html": "Foo\n---
\n", "markdown": "Foo\n ---\n", "example": 56, - "start_line": 1092 + "start_line": 1092, + "shouldFail": true }, { "end_line": 1114, @@ -493,7 +501,8 @@ "html": "\n\n", "markdown": "> foo\nbar\n===\n", "example": 62, - "start_line": 1170 + "start_line": 1170, + "shouldFail": true }, { "end_line": 1191, @@ -509,7 +518,8 @@ "html": "foo\nbar\n===
\n
\n\n\n
\n- foo
\n
\n\n\nfoo\n
bar\n
\n",
"markdown": "> foo\n bar\n",
"example": 199,
- "start_line": 3396
+ "start_line": 3396,
+ "shouldFail": true
},
{
"end_line": 3419,
@@ -1597,7 +1610,8 @@
"html": "\n\n\n
foo
\n
\n",
"markdown": "> ```\nfoo\n```\n",
"example": 200,
- "start_line": 3409
+ "start_line": 3409,
+ "shouldFail": true
},
{
"end_line": 3433,
@@ -1741,7 +1755,8 @@
"html": "two
\n", "markdown": "- one\n\n two\n", "example": 218, - "start_line": 3749 + "start_line": 3749, + "shouldFail": true }, { "end_line": 3772, @@ -1757,7 +1772,8 @@ "html": " two\n
\n",
"markdown": " - one\n\n two\n",
"example": 220,
- "start_line": 3775
+ "start_line": 3775,
+ "shouldFail": true
},
{
"end_line": 3799,
@@ -1797,7 +1813,8 @@
"html": "foo
\nbar
\nFoo
\nbar\n\n\nbaz\n
\nindented code\n
\nparagraph
\nmore code\n
\n indented code\n
\nparagraph
\nmore code\n
\nbar
\n", "markdown": "- foo\n\n bar\n", "example": 239, - "start_line": 4108 + "start_line": 4108, + "shouldFail": true }, { "end_line": 4136, @@ -1925,7 +1946,8 @@ "html": "bar\n
\nbaz\n
\nfoo
\n", "markdown": "-\n\n foo\n", "example": 243, - "start_line": 4193 + "start_line": 4193, + "shouldFail": true }, { "end_line": 4217, @@ -1973,7 +1996,8 @@ "html": "The number of windows in my house is\n14. The number of doors is 6.
\n", "markdown": "The number of windows in my house is\n14. The number of doors is 6.\n", "example": 267, - "start_line": 4920 + "start_line": 4920, + "shouldFail": true }, { "end_line": 4938, @@ -2149,7 +2179,8 @@ "html": "foo
\nbar
\nbaz
\nbaz
\nbim
\na
\nb
\nc
\na
\nb
\nd
\nb\n\n\n
\nb
\nc
\n\n\nb
\n
c\n
\nfoo\n
\n",
"markdown": "``` foo\\+bar\nfoo\n```\n",
"example": 301,
- "start_line": 5511
+ "start_line": 5511,
+ "shouldFail": true
},
{
"end_line": 5546,
@@ -2469,7 +2509,8 @@
"html": "\n",
"markdown": "[foo](/föö \"föö\")\n",
"example": 309,
- "start_line": 5620
+ "start_line": 5620,
+ "shouldFail": true
},
{
"end_line": 5633,
@@ -2477,7 +2518,8 @@
"html": "\n",
"markdown": "[foo]\n\n[foo]: /föö \"föö\"\n",
"example": 310,
- "start_line": 5627
+ "start_line": 5627,
+ "shouldFail": true
},
{
"end_line": 5643,
@@ -2485,7 +2527,8 @@
"html": "foo\n
\n",
"markdown": "``` föö\nfoo\n```\n",
"example": 311,
- "start_line": 5636
+ "start_line": 5636,
+ "shouldFail": true
},
{
"end_line": 5653,
@@ -2573,7 +2616,8 @@
"html": "*foo*
[not a link](/foo
)
* a *
\n", "markdown": "* a *\n", "example": 334, - "start_line": 6091 + "start_line": 6091, + "shouldFail": true }, { "end_line": 6104, @@ -2733,7 +2779,8 @@ "html": "пристаням_стремятся_
\n", "markdown": "пристаням_стремятся_\n", "example": 342, - "start_line": 6159 + "start_line": 6159, + "shouldFail": true }, { "end_line": 6173, @@ -2781,7 +2828,8 @@ "html": "*(*foo)
\n", "markdown": "*(*foo)\n", "example": 348, - "start_line": 6224 + "start_line": 6224, + "shouldFail": true }, { "end_line": 6238, @@ -2789,7 +2837,8 @@ "html": "(foo)
\n", "markdown": "*(*foo*)*\n", "example": 349, - "start_line": 6234 + "start_line": 6234, + "shouldFail": true }, { "end_line": 6247, @@ -2813,7 +2862,8 @@ "html": "_(_foo)
\n", "markdown": "_(_foo)\n", "example": 352, - "start_line": 6266 + "start_line": 6266, + "shouldFail": true }, { "end_line": 6279, @@ -2821,7 +2871,8 @@ "html": "(foo)
\n", "markdown": "_(_foo_)_\n", "example": 353, - "start_line": 6275 + "start_line": 6275, + "shouldFail": true }, { "end_line": 6288, @@ -2877,7 +2928,8 @@ "html": "a**"foo"**
\n", "markdown": "a**\"foo\"**\n", "example": 360, - "start_line": 6339 + "start_line": 6339, + "shouldFail": true }, { "end_line": 6352, @@ -2941,7 +2993,8 @@ "html": "пристаням__стремятся__
\n", "markdown": "пристаням__стремятся__\n", "example": 368, - "start_line": 6410 + "start_line": 6410, + "shouldFail": true }, { "end_line": 6421, @@ -2949,7 +3002,8 @@ "html": "foo, bar, baz
\n", "markdown": "__foo, __bar__, baz__\n", "example": 369, - "start_line": 6417 + "start_line": 6417, + "shouldFail": true }, { "end_line": 6432, @@ -2965,7 +3019,8 @@ "html": "**foo bar **
\n", "markdown": "**foo bar **\n", "example": 371, - "start_line": 6441 + "start_line": 6441, + "shouldFail": true }, { "end_line": 6458, @@ -2973,7 +3028,8 @@ "html": "**(**foo)
\n", "markdown": "**(**foo)\n", "example": 372, - "start_line": 6454 + "start_line": 6454, + "shouldFail": true }, { "end_line": 6468, @@ -3021,7 +3077,8 @@ "html": "__(__foo)
\n", "markdown": "__(__foo)\n", "example": 378, - "start_line": 6511 + "start_line": 6511, + "shouldFail": true }, { "end_line": 6525, @@ -3037,7 +3094,8 @@ "html": "__foo__bar
\n", "markdown": "__foo__bar\n", "example": 380, - "start_line": 6530 + "start_line": 6530, + "shouldFail": true }, { "end_line": 6541, @@ -3045,7 +3103,8 @@ "html": "__пристаням__стремятся
\n", "markdown": "__пристаням__стремятся\n", "example": 381, - "start_line": 6537 + "start_line": 6537, + "shouldFail": true }, { "end_line": 6548, @@ -3053,7 +3112,8 @@ "html": "foo__bar__baz
\n", "markdown": "__foo__bar__baz__\n", "example": 382, - "start_line": 6544 + "start_line": 6544, + "shouldFail": true }, { "end_line": 6559, @@ -3093,7 +3153,8 @@ "html": "foo bar baz
\n", "markdown": "_foo _bar_ baz_\n", "example": 387, - "start_line": 6593 + "start_line": 6593, + "shouldFail": true }, { "end_line": 6604, @@ -3101,7 +3162,8 @@ "html": "foo bar
\n", "markdown": "__foo_ bar_\n", "example": 388, - "start_line": 6600 + "start_line": 6600, + "shouldFail": true }, { "end_line": 6611, @@ -3133,7 +3195,8 @@ "html": "foo bar
\n", "markdown": "***foo** bar*\n", "example": 392, - "start_line": 6645 + "start_line": 6645, + "shouldFail": true }, { "end_line": 6656, @@ -3141,7 +3204,8 @@ "html": "foo bar
\n", "markdown": "*foo **bar***\n", "example": 393, - "start_line": 6652 + "start_line": 6652, + "shouldFail": true }, { "end_line": 6663, @@ -3149,7 +3213,8 @@ "html": "foobar
\n", "markdown": "*foo**bar***\n", "example": 394, - "start_line": 6659 + "start_line": 6659, + "shouldFail": true }, { "end_line": 6672, @@ -3157,7 +3222,8 @@ "html": "foo bar baz bim bop
\n", "markdown": "*foo **bar *baz* bim** bop*\n", "example": 395, - "start_line": 6668 + "start_line": 6668, + "shouldFail": true }, { "end_line": 6679, @@ -3165,7 +3231,8 @@ "html": "foo bar
\n", "markdown": "*foo [*bar*](/url)*\n", "example": 396, - "start_line": 6675 + "start_line": 6675, + "shouldFail": true }, { "end_line": 6688, @@ -3213,7 +3280,8 @@ "html": "foo bar baz
\n", "markdown": "__foo __bar__ baz__\n", "example": 402, - "start_line": 6730 + "start_line": 6730, + "shouldFail": true }, { "end_line": 6741, @@ -3221,7 +3289,8 @@ "html": "foo bar
\n", "markdown": "____foo__ bar__\n", "example": 403, - "start_line": 6737 + "start_line": 6737, + "shouldFail": true }, { "end_line": 6748, @@ -3269,7 +3338,8 @@ "html": "foo bar baz\nbim bop
\n", "markdown": "**foo *bar **baz**\nbim* bop**\n", "example": 409, - "start_line": 6781 + "start_line": 6781, + "shouldFail": true }, { "end_line": 6794, @@ -3349,7 +3419,8 @@ "html": "*foo
\n", "markdown": "**foo*\n", "example": 419, - "start_line": 6862 + "start_line": 6862, + "shouldFail": true }, { "end_line": 6873, @@ -3357,7 +3428,8 @@ "html": "foo*
\n", "markdown": "*foo**\n", "example": 420, - "start_line": 6869 + "start_line": 6869, + "shouldFail": true }, { "end_line": 6880, @@ -3365,7 +3437,8 @@ "html": "*foo
\n", "markdown": "***foo**\n", "example": 421, - "start_line": 6876 + "start_line": 6876, + "shouldFail": true }, { "end_line": 6887, @@ -3373,7 +3446,8 @@ "html": "***foo
\n", "markdown": "****foo*\n", "example": 422, - "start_line": 6883 + "start_line": 6883, + "shouldFail": true }, { "end_line": 6894, @@ -3381,7 +3455,8 @@ "html": "foo*
\n", "markdown": "**foo***\n", "example": 423, - "start_line": 6890 + "start_line": 6890, + "shouldFail": true }, { "end_line": 6901, @@ -3389,7 +3464,8 @@ "html": "foo***
\n", "markdown": "*foo****\n", "example": 424, - "start_line": 6897 + "start_line": 6897, + "shouldFail": true }, { "end_line": 6911, @@ -3445,7 +3521,8 @@ "html": "_foo
\n", "markdown": "__foo_\n", "example": 431, - "start_line": 6949 + "start_line": 6949, + "shouldFail": true }, { "end_line": 6964, @@ -3453,7 +3530,8 @@ "html": "foo_
\n", "markdown": "_foo__\n", "example": 432, - "start_line": 6960 + "start_line": 6960, + "shouldFail": true }, { "end_line": 6971, @@ -3461,7 +3539,8 @@ "html": "_foo
\n", "markdown": "___foo__\n", "example": 433, - "start_line": 6967 + "start_line": 6967, + "shouldFail": true }, { "end_line": 6978, @@ -3469,7 +3548,8 @@ "html": "___foo
\n", "markdown": "____foo_\n", "example": 434, - "start_line": 6974 + "start_line": 6974, + "shouldFail": true }, { "end_line": 6985, @@ -3477,7 +3557,8 @@ "html": "foo_
\n", "markdown": "__foo___\n", "example": 435, - "start_line": 6981 + "start_line": 6981, + "shouldFail": true }, { "end_line": 6992, @@ -3485,7 +3566,8 @@ "html": "foo___
\n", "markdown": "_foo____\n", "example": 436, - "start_line": 6988 + "start_line": 6988, + "shouldFail": true }, { "end_line": 7002, @@ -3541,7 +3623,8 @@ "html": "foo
\n", "markdown": "******foo******\n", "example": 443, - "start_line": 7047 + "start_line": 7047, + "shouldFail": true }, { "end_line": 7060, @@ -3549,7 +3632,8 @@ "html": "foo
\n", "markdown": "***foo***\n", "example": 444, - "start_line": 7056 + "start_line": 7056, + "shouldFail": true }, { "end_line": 7067, @@ -3557,7 +3641,8 @@ "html": "foo
\n", "markdown": "_____foo_____\n", "example": 445, - "start_line": 7063 + "start_line": 7063, + "shouldFail": true }, { "end_line": 7076, @@ -3581,7 +3666,8 @@ "html": "**foo bar baz
\n", "markdown": "**foo **bar baz**\n", "example": 448, - "start_line": 7088 + "start_line": 7088, + "shouldFail": true }, { "end_line": 7099, @@ -3589,7 +3675,8 @@ "html": "*foo bar baz
\n", "markdown": "*foo *bar baz*\n", "example": 449, - "start_line": 7095 + "start_line": 7095, + "shouldFail": true }, { "end_line": 7108, @@ -3621,7 +3708,8 @@ "html": "\n", "markdown": "**\n", "example": 453, - "start_line": 7125 + "start_line": 7125, + "shouldFail": true }, { "end_line": 7136, @@ -3629,7 +3717,8 @@ "html": "\n", "markdown": "__\n", "example": 454, - "start_line": 7132 + "start_line": 7132, + "shouldFail": true }, { "end_line": 7143, @@ -3637,7 +3726,8 @@ "html": "a *
[foo bar](/uri)
\n", "markdown": "[foo [bar](/uri)](/uri)\n", "example": 489, - "start_line": 7538 + "start_line": 7538, + "shouldFail": true }, { "end_line": 7549, @@ -3917,7 +4013,8 @@ "html": "[foo [bar baz](/uri)](/uri)
\n", "markdown": "[foo *[bar [baz](/uri)](/uri)*](/uri)\n", "example": 490, - "start_line": 7545 + "start_line": 7545, + "shouldFail": true }, { "end_line": 7556, @@ -3925,7 +4022,8 @@ "html": "\n", "markdown": "![[[foo](uri1)](uri2)](uri3)\n", "example": 491, - "start_line": 7552 + "start_line": 7552, + "shouldFail": true }, { "end_line": 7566, @@ -3957,7 +4055,8 @@ "html": "[foo
[foo](/uri)
[foohttp://example.com/?search=](uri)
\n", "markdown": "[foo[foo
[foo][ref]
[foohttp://example.com/?search=][ref]
\n", "markdown": "[foo<http://foo.bar/baz bim>
\n", "markdown": "< http://foo.bar >
\n", "markdown": "< http://foo.bar >\n", "example": 579, - "start_line": 8559 + "start_line": 8559, + "shouldFail": true }, { "end_line": 8570, @@ -4653,7 +4769,8 @@ "html": "http://example.com
\n", "markdown": "http://example.com\n", "example": 582, - "start_line": 8580 + "start_line": 8580, + "shouldFail": true }, { "end_line": 8591, @@ -4661,7 +4778,8 @@ "html": "foo@bar.example.com
\n", "markdown": "foo@bar.example.com\n", "example": 583, - "start_line": 8587 + "start_line": 8587, + "shouldFail": true }, { "end_line": 8673, @@ -4773,7 +4891,8 @@ "html": "foo <!-- not a comment -- two hyphens -->
\n", "markdown": "foo \n", "example": 597, - "start_line": 8792 + "start_line": 8792, + "shouldFail": true }, { "end_line": 8808, @@ -4781,7 +4900,8 @@ "html": "foo <!--> foo -->
\nfoo <!-- foo--->
\n", "markdown": "foo foo -->\n\nfoo \n", "example": 598, - "start_line": 8801 + "start_line": 8801, + "shouldFail": true }, { "end_line": 8817, @@ -4991,4 +5111,4 @@ "example": 624, "start_line": 9070 } -] \ No newline at end of file +] diff --git a/test/specs/gfm/gfm-spec.js b/test/specs/gfm/gfm-spec.js deleted file mode 100644 index 83340db0fa..0000000000 --- a/test/specs/gfm/gfm-spec.js +++ /dev/null @@ -1,96 +0,0 @@ -var marked = require('../../../lib/marked.js'); -var gfmSpec = require('./gfm.0.28.json'); -var HtmlDiffer = require('@markedjs/html-differ').HtmlDiffer, - htmlDiffer = new HtmlDiffer({ignoreSelfClosingSlash: true}); -var since = require('jasmine2-custom-message'); - -var Messenger = function() {}; - -Messenger.prototype.message = function(spec, expected, actual) { - return 'CommonMark (' + spec.section + '):\n' + spec.markdown + '\n------\n\nExpected:\n' + expected + '\n------\n\nMarked:\n' + actual; -}; - -Messenger.prototype.test = function(spec, section, ignore) { - if (spec.section === section && ignore.indexOf(spec.example) < 0) { - var shouldFail = ~ignore.indexOf(spec.example); - it('should ' + (shouldFail ? 'fail' : 'pass') + ' example ' + spec.example, function() { - var expected = spec.html; - var actual = marked(spec.markdown, { headerIds: false, xhtml: false }); - since(messenger.message(spec, expected, actual)).expect( - htmlDiffer.isEqual(expected, actual) - ).toEqual(!shouldFail); - }); - } -}; - -var messenger = new Messenger(); - -describe('GFM 0.28 Tables', function() { - var section = 'Tables'; - - var shouldPassButFails = []; - - var willNotBeAttemptedByCoreTeam = []; - - var ignore = shouldPassButFails.concat(willNotBeAttemptedByCoreTeam); - - gfmSpec.forEach(function(spec) { - messenger.test(spec, section, ignore); - }); -}); - -describe('GFM 0.28 Task list items', function() { - var section = 'Task list items'; - - var shouldPassButFails = []; - - var willNotBeAttemptedByCoreTeam = []; - - var ignore = shouldPassButFails.concat(willNotBeAttemptedByCoreTeam); - - gfmSpec.forEach(function(spec) { - messenger.test(spec, section, ignore); - }); -}); - -describe('GFM 0.28 Strikethrough', function() { - var section = 'Strikethrough'; - - var shouldPassButFails = []; - - var willNotBeAttemptedByCoreTeam = []; - - var ignore = shouldPassButFails.concat(willNotBeAttemptedByCoreTeam); - - gfmSpec.forEach(function(spec) { - messenger.test(spec, section, ignore); - }); -}); - -describe('GFM 0.28 Autolinks', function() { - var section = 'Autolinks'; - - var shouldPassButFails = [607]; - - var willNotBeAttemptedByCoreTeam = []; - - var ignore = shouldPassButFails.concat(willNotBeAttemptedByCoreTeam); - - gfmSpec.forEach(function(spec) { - messenger.test(spec, section, ignore); - }); -}); - -describe('GFM 0.28 Disallowed Raw HTML', function() { - var section = 'Disallowed Raw HTML'; - - var shouldPassButFails = [629]; - - var willNotBeAttemptedByCoreTeam = []; - - var ignore = shouldPassButFails.concat(willNotBeAttemptedByCoreTeam); - - gfmSpec.forEach(function(spec) { - messenger.test(spec, section, ignore); - }); -}); diff --git a/test/specs/gfm/gfm.0.28.json b/test/specs/gfm/gfm.0.28.json index d045f8af62..f9c28eb2ab 100644 --- a/test/specs/gfm/gfm.0.28.json +++ b/test/specs/gfm/gfm.0.28.json @@ -141,12 +141,14 @@ "section": "Autolinks", "html": "\n\na.b-c_d@a.b-
\na.b-c_d@a.b_
", "markdown": "a.b-c_d@a.b\n\na.b-c_d@a.b.\n\na.b-c_d@a.b-\n\na.b-c_d@a.b_", - "example": 607 + "example": 607, + "shouldFail": true }, { "section": "Disallowed Raw HTML", "html": "<title> <style>
\n\n <xmp> is disallowed. <XMP> is also disallowed.\n", "markdown": "