diff --git a/.circleci/config.yml b/.circleci/config.yml index 1e8e25755..cf67d6952 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -22,6 +22,8 @@ jobs: - run: name: Compatibility Test + # Only run e2e-tests if the PR + # is published by the Sortable Organization command: | if [ -z "$CIRCLE_PR_NUMBER" ]; then diff --git a/package-lock.json b/package-lock.json index 76a585b54..9f1264049 100644 --- a/package-lock.json +++ b/package-lock.json @@ -765,112 +765,6 @@ "to-fast-properties": "^2.0.0" } }, - "@cypress/listr-verbose-renderer": { - "version": "0.4.1", - "resolved": "https://registry.npmjs.org/@cypress/listr-verbose-renderer/-/listr-verbose-renderer-0.4.1.tgz", - "integrity": "sha1-p3SS9LEdzHxEajSz4ochr9M8ZCo=", - "dev": true, - "requires": { - "chalk": "^1.1.3", - "cli-cursor": "^1.0.2", - "date-fns": "^1.27.2", - "figures": "^1.7.0" - }, - "dependencies": { - "ansi-styles": { - "version": "2.2.1", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-2.2.1.tgz", - "integrity": "sha1-tDLdM1i2NM914eRmQ2gkBTPB3b4=", - "dev": true - }, - "chalk": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-1.1.3.tgz", - "integrity": "sha1-qBFcVeSnAv5NFQq9OHKCKn4J/Jg=", - "dev": true, - "requires": { - "ansi-styles": "^2.2.1", - "escape-string-regexp": "^1.0.2", - "has-ansi": "^2.0.0", - "strip-ansi": "^3.0.0", - "supports-color": "^2.0.0" - } - }, - "supports-color": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-2.0.0.tgz", - "integrity": "sha1-U10EXOa2Nj+kARcIRimZXp3zJMc=", - "dev": true - } - } - }, - "@cypress/request": { - "version": "2.88.5", - "resolved": "https://registry.npmjs.org/@cypress/request/-/request-2.88.5.tgz", - "integrity": "sha512-TzEC1XMi1hJkywWpRfD2clreTa/Z+lOrXDCxxBTBPEcY5azdPi56A6Xw+O4tWJnaJH3iIE7G5aDXZC6JgRZLcA==", - "dev": true, - "requires": { - "aws-sign2": "~0.7.0", - "aws4": "^1.8.0", - "caseless": "~0.12.0", - "combined-stream": "~1.0.6", - "extend": "~3.0.2", - "forever-agent": "~0.6.1", - "form-data": "~2.3.2", - "har-validator": "~5.1.3", - "http-signature": "~1.2.0", - "is-typedarray": "~1.0.0", - "isstream": "~0.1.2", - "json-stringify-safe": "~5.0.1", - "mime-types": "~2.1.19", - "oauth-sign": "~0.9.0", - "performance-now": "^2.1.0", - "qs": "~6.5.2", - "safe-buffer": "^5.1.2", - "tough-cookie": "~2.5.0", - "tunnel-agent": "^0.6.0", - "uuid": "^3.3.2" - }, - "dependencies": { - "punycode": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/punycode/-/punycode-2.1.1.tgz", - "integrity": "sha512-XRsRjdf+j5ml+y/6GKHPZbrF/8p2Yga0JPtdqTIY2Xe5ohJPD9saDJJLPvp9+NSBprVvevdXZybnj2cv8OEd0A==", - "dev": true - }, - "tough-cookie": { - "version": "2.5.0", - "resolved": "https://registry.npmjs.org/tough-cookie/-/tough-cookie-2.5.0.tgz", - "integrity": "sha512-nlLsUzgm1kfLXSXfRZMc1KLAugd4hqJHDTvc2hDIwS3mZAfMEuMbc03SujMF+GEcpaX/qboeycw6iO8JwVv2+g==", - "dev": true, - "requires": { - "psl": "^1.1.28", - "punycode": "^2.1.1" - } - } - } - }, - "@cypress/xvfb": { - "version": "1.2.4", - "resolved": "https://registry.npmjs.org/@cypress/xvfb/-/xvfb-1.2.4.tgz", - "integrity": "sha512-skbBzPggOVYCbnGgV+0dmBdW/s77ZkAOXIC1knS8NagwDjBrNC1LuXtQJeiN6l+m7lzmHtaoUw/ctJKdqkG57Q==", - "dev": true, - "requires": { - "debug": "^3.1.0", - "lodash.once": "^4.1.1" - }, - "dependencies": { - "debug": { - "version": "3.2.6", - "resolved": "https://registry.npmjs.org/debug/-/debug-3.2.6.tgz", - "integrity": "sha512-mel+jf7nrtEl5Pn1Qx46zARXKDpBbvzezse7p7LqINmdoIk8PYP5SySaxEmYv6TZ0JyEKA1hsCId6DIhgITtWQ==", - "dev": true, - "requires": { - "ms": "^2.1.1" - } - } - } - }, "@mrmlnc/readdir-enhanced": { "version": "2.2.1", "resolved": "https://registry.npmjs.org/@mrmlnc/readdir-enhanced/-/readdir-enhanced-2.2.1.tgz", @@ -887,15 +781,6 @@ "integrity": "sha512-shAmDyaQC4H92APFoIaVDHCx5bStIocgvbwQyxPRrbUY20V1EYTbSDchWbuwlMG3V17cprZhA6+78JfB+3DTPw==", "dev": true }, - "@samverschueren/stream-to-observable": { - "version": "0.3.0", - "resolved": "https://registry.npmjs.org/@samverschueren/stream-to-observable/-/stream-to-observable-0.3.0.tgz", - "integrity": "sha512-MI4Xx6LHs4Webyvi6EbspgyAb4D2Q2VtnCQ1blOJcoLS6mVa8lNN2rkIy1CVxfTUpoyIbCTkXES1rLXztFD1lg==", - "dev": true, - "requires": { - "any-observable": "^0.3.0" - } - }, "@types/error-stack-parser": { "version": "1.3.18", "resolved": "https://registry.npmjs.org/@types/error-stack-parser/-/error-stack-parser-1.3.18.tgz", @@ -952,18 +837,6 @@ "@types/node": "*" } }, - "@types/sinonjs__fake-timers": { - "version": "6.0.1", - "resolved": "https://registry.npmjs.org/@types/sinonjs__fake-timers/-/sinonjs__fake-timers-6.0.1.tgz", - "integrity": "sha512-yYezQwGWty8ziyYLdZjwxyMb0CZR49h8JALHGrxjQHWlqGgc8kLdHEgWrgL0uZ29DMvEVBDnHU2Wg36zKSIUtA==", - "dev": true - }, - "@types/sizzle": { - "version": "2.3.2", - "resolved": "https://registry.npmjs.org/@types/sizzle/-/sizzle-2.3.2.tgz", - "integrity": "sha512-7EJYyKTL7tFR8+gDbB6Wwz/arpGa0Mywk1TJbNzKzHtzbwVmY4HR9WqS5VV7dsBUKQmPNr192jHr/VpBluj/hg==", - "dev": true - }, "acorn": { "version": "6.1.1", "resolved": "https://registry.npmjs.org/acorn/-/acorn-6.1.1.tgz", @@ -1033,18 +906,6 @@ "color-convert": "^1.9.0" } }, - "any-observable": { - "version": "0.3.0", - "resolved": "https://registry.npmjs.org/any-observable/-/any-observable-0.3.0.tgz", - "integrity": "sha512-/FQM1EDkTsf63Ub2C6O7GuYFDsSXUwsaZDurV0np41ocwq0jthUAYCmhBX9f+KwlaCgIuWyr/4WlUQUBfKfZog==", - "dev": true - }, - "arch": { - "version": "2.1.2", - "resolved": "https://registry.npmjs.org/arch/-/arch-2.1.2.tgz", - "integrity": "sha512-NTBIIbAfkJeIletyABbVtdPgeKfDafR+1mZV/AyyfC1UkVkp9iUjV+wwmqtUgphHYajbI86jejBJp5e+jkGTiQ==", - "dev": true - }, "archiver": { "version": "2.1.1", "resolved": "https://registry.npmjs.org/archiver/-/archiver-2.1.1.tgz", @@ -2240,12 +2101,6 @@ "safe-buffer": "^5.1.1" } }, - "bluebird": { - "version": "3.7.2", - "resolved": "https://registry.npmjs.org/bluebird/-/bluebird-3.7.2.tgz", - "integrity": "sha512-XpNj6GDQzdfW+r2Wnn7xiSAd7TM3jzkxGXBGTtWKuSXv1xUV+azxAm8jdWZN06QTQk+2N2XB9jRDkvbmQmcRtg==", - "dev": true - }, "bowser": { "version": "1.6.0", "resolved": "https://registry.npmjs.org/bowser/-/bowser-1.6.0.tgz", @@ -2378,12 +2233,6 @@ "unset-value": "^1.0.0" } }, - "cachedir": { - "version": "2.3.0", - "resolved": "https://registry.npmjs.org/cachedir/-/cachedir-2.3.0.tgz", - "integrity": "sha512-A+Fezp4zxnit6FanDmv9EqXNAi3vt9DWp51/71UEhXukb7QUuvtv9344h91dyAxuTLoSYJFU299qzR3tzwPAhw==", - "dev": true - }, "call-me-maybe": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/call-me-maybe/-/call-me-maybe-1.0.1.tgz", @@ -2455,12 +2304,6 @@ "integrity": "sha1-V00xLt2Iu13YkS6Sht1sCu1KrII=", "dev": true }, - "check-more-types": { - "version": "2.24.0", - "resolved": "https://registry.npmjs.org/check-more-types/-/check-more-types-2.24.0.tgz", - "integrity": "sha1-FCD/sQ/URNz8ebQ4kbv//TKoRgA=", - "dev": true - }, "chrome-emulated-devices-list": { "version": "0.1.1", "resolved": "https://registry.npmjs.org/chrome-emulated-devices-list/-/chrome-emulated-devices-list-0.1.1.tgz", @@ -2514,69 +2357,6 @@ } } }, - "cli-cursor": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/cli-cursor/-/cli-cursor-1.0.2.tgz", - "integrity": "sha1-ZNo/fValRBLll5S9Ytw1KV6PKYc=", - "dev": true, - "requires": { - "restore-cursor": "^1.0.1" - } - }, - "cli-table3": { - "version": "0.5.1", - "resolved": "https://registry.npmjs.org/cli-table3/-/cli-table3-0.5.1.tgz", - "integrity": "sha512-7Qg2Jrep1S/+Q3EceiZtQcDPWxhAvBw+ERf1162v4sikJrvojMHFqXt8QIVha8UlH9rgU0BeWPytZ9/TzYqlUw==", - "dev": true, - "requires": { - "colors": "^1.1.2", - "object-assign": "^4.1.0", - "string-width": "^2.1.1" - }, - "dependencies": { - "ansi-regex": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-3.0.0.tgz", - "integrity": "sha1-7QMXwyIGT3lGbAKWa922Bas32Zg=", - "dev": true - }, - "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", - "integrity": "sha1-o7MKXE8ZkYMWeqq5O+764937ZU8=", - "dev": true - }, - "string-width": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-2.1.1.tgz", - "integrity": "sha512-nOqH59deCq9SRHlxq1Aw85Jnt4w6KvLKqWVik6oA9ZklXLNIOlqg4F2yrT1MVaTjAqvVwdfeZ7w7aCvJD7ugkw==", - "dev": true, - "requires": { - "is-fullwidth-code-point": "^2.0.0", - "strip-ansi": "^4.0.0" - } - }, - "strip-ansi": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-4.0.0.tgz", - "integrity": "sha1-qEeQIusaw2iocTibY1JixQXuNo8=", - "dev": true, - "requires": { - "ansi-regex": "^3.0.0" - } - } - } - }, - "cli-truncate": { - "version": "0.2.1", - "resolved": "https://registry.npmjs.org/cli-truncate/-/cli-truncate-0.2.1.tgz", - "integrity": "sha1-nxXPuwcFAFNpIWxiasfQWrkN1XQ=", - "dev": true, - "requires": { - "slice-ansi": "0.0.4", - "string-width": "^1.0.1" - } - }, "code-point-at": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/code-point-at/-/code-point-at-1.1.0.tgz", @@ -2614,13 +2394,6 @@ "integrity": "sha1-p9BVi9icQveV3UIyj3QIMcpTvCU=", "dev": true }, - "colors": { - "version": "1.4.0", - "resolved": "https://registry.npmjs.org/colors/-/colors-1.4.0.tgz", - "integrity": "sha512-a+UqTh4kgZg/SlGvfbzDHpgRu7AAQOmmqRHJnxhRZICKFUT91brVhNNt58CMWU9PsBbv3PDCZUHbVxuDiH2mtA==", - "dev": true, - "optional": true - }, "combined-stream": { "version": "1.0.8", "resolved": "https://registry.npmjs.org/combined-stream/-/combined-stream-1.0.8.tgz", @@ -2636,12 +2409,6 @@ "integrity": "sha512-7j2y+40w61zy6YC2iRNpUe/NwhNyoXrYpHMrSunaMG64nRnaf96zO/KMQR4OyN/UnE5KLyEBnKHd4aG3rskjpQ==", "dev": true }, - "common-tags": { - "version": "1.8.0", - "resolved": "https://registry.npmjs.org/common-tags/-/common-tags-1.8.0.tgz", - "integrity": "sha512-6P6g0uetGpW/sdyUy/iQQCbFF0kWVMSIVSyYz7Zgjcgh8mgw8PQzDNZeyZ5DQ2gM7LBoZPHmnjz8rUthkBG5tw==", - "dev": true - }, "component-emitter": { "version": "1.3.0", "resolved": "https://registry.npmjs.org/component-emitter/-/component-emitter-1.3.0.tgz", @@ -2666,18 +2433,6 @@ "integrity": "sha1-2Klr13/Wjfd5OnMDajug1UBdR3s=", "dev": true }, - "concat-stream": { - "version": "1.6.2", - "resolved": "https://registry.npmjs.org/concat-stream/-/concat-stream-1.6.2.tgz", - "integrity": "sha512-27HBghJxjiZtIk3Ycvn/4kbJk/1uZuJFfuPEns6LaEvpvG1f0hTea8lilrouyo9mVc2GWdcEZ8OLoGmSADlrCw==", - "dev": true, - "requires": { - "buffer-from": "^1.0.0", - "inherits": "^2.0.3", - "readable-stream": "^2.2.2", - "typedarray": "^0.0.6" - } - }, "convert-source-map": { "version": "1.6.0", "resolved": "https://registry.npmjs.org/convert-source-map/-/convert-source-map-1.6.0.tgz", @@ -2749,19 +2504,6 @@ "readable-stream": "^2.0.0" } }, - "cross-spawn": { - "version": "6.0.5", - "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-6.0.5.tgz", - "integrity": "sha512-eTVLrBSt7fjbDygz805pMnstIs2VTBNkRm0qxZd+M7A5XDdxVRWO5MxGBXZhjY4cqLYLdtrGqRf8mBPmzwSpWQ==", - "dev": true, - "requires": { - "nice-try": "^1.0.4", - "path-key": "^2.0.1", - "semver": "^5.5.0", - "shebang-command": "^1.2.0", - "which": "^1.2.9" - } - }, "crypto-md5": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/crypto-md5/-/crypto-md5-1.0.0.tgz", @@ -2791,116 +2533,6 @@ } } }, - "cypress": { - "version": "4.12.1", - "resolved": "https://registry.npmjs.org/cypress/-/cypress-4.12.1.tgz", - "integrity": "sha512-9SGIPEmqU8vuRA6xst2CMTYd9sCFCxKSzrHt0wr+w2iAQMCIIsXsQ5Gplns1sT6LDbZcmLv6uehabAOl3fhc9Q==", - "dev": true, - "requires": { - "@cypress/listr-verbose-renderer": "^0.4.1", - "@cypress/request": "^2.88.5", - "@cypress/xvfb": "^1.2.4", - "@types/sinonjs__fake-timers": "^6.0.1", - "@types/sizzle": "^2.3.2", - "arch": "^2.1.2", - "bluebird": "^3.7.2", - "cachedir": "^2.3.0", - "chalk": "^2.4.2", - "check-more-types": "^2.24.0", - "cli-table3": "~0.5.1", - "commander": "^4.1.1", - "common-tags": "^1.8.0", - "debug": "^4.1.1", - "eventemitter2": "^6.4.2", - "execa": "^1.0.0", - "executable": "^4.1.1", - "extract-zip": "^1.7.0", - "fs-extra": "^8.1.0", - "getos": "^3.2.1", - "is-ci": "^2.0.0", - "is-installed-globally": "^0.3.2", - "lazy-ass": "^1.6.0", - "listr": "^0.14.3", - "lodash": "^4.17.19", - "log-symbols": "^3.0.0", - "minimist": "^1.2.5", - "moment": "^2.27.0", - "ospath": "^1.2.2", - "pretty-bytes": "^5.3.0", - "ramda": "~0.26.1", - "request-progress": "^3.0.0", - "supports-color": "^7.1.0", - "tmp": "~0.1.0", - "untildify": "^4.0.0", - "url": "^0.11.0", - "yauzl": "^2.10.0" - }, - "dependencies": { - "ci-info": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/ci-info/-/ci-info-2.0.0.tgz", - "integrity": "sha512-5tK7EtrZ0N+OLFMthtqOj4fI2Jeb88C4CAZPu25LDVUgXJ0A3Js4PMGqrn0JU1W0Mh1/Z8wZzYPxqUrXeBboCQ==", - "dev": true - }, - "commander": { - "version": "4.1.1", - "resolved": "https://registry.npmjs.org/commander/-/commander-4.1.1.tgz", - "integrity": "sha512-NOKm8xhkzAjzFx8B2v5OAHT+u5pRQc2UCa2Vq9jYL/31o2wi9mxBA7LIFs3sV5VSC49z6pEhfbMULvShKj26WA==", - "dev": true - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, - "is-ci": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/is-ci/-/is-ci-2.0.0.tgz", - "integrity": "sha512-YfJT7rkpQB0updsdHLGWrvhBJfcfzNNawYDNIyQXJz0IViGf75O8EBPKSdvw2rF+LGCsX4FZ8tcr3b19LcZq4w==", - "dev": true, - "requires": { - "ci-info": "^2.0.0" - } - }, - "lodash": { - "version": "4.17.19", - "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.19.tgz", - "integrity": "sha512-JNvd8XER9GQX0v2qJgsaN/mzFCNA5BRe/j8JN9d+tWyGLSodKQHKFicdwNYzWwI3wjRnaKPsGj1XkBjx/F96DQ==", - "dev": true - }, - "minimist": { - "version": "1.2.5", - "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.5.tgz", - "integrity": "sha512-FM9nNUYrRBAELZQT3xeZQ7fmMOBg6nWNmJKTcgsJeaLstP/UODVpGsr5OhXhhXg6f+qtJ8uiZ+PUxkDWcgIXLw==", - "dev": true - }, - "moment": { - "version": "2.27.0", - "resolved": "https://registry.npmjs.org/moment/-/moment-2.27.0.tgz", - "integrity": "sha512-al0MUK7cpIcglMv3YF13qSgdAIqxHTO7brRtaz3DlSULbqfazqkc5kEjNrLDOM7fsjshoFIihnU8snrP7zUvhQ==", - "dev": true - }, - "supports-color": { - "version": "7.1.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.1.0.tgz", - "integrity": "sha512-oRSIpR8pxT1Wr2FquTNnGet79b3BWljqOuoW/h4oBhxJ/HUbX5nX6JSruTkvXDCFMwDPvsaTTbvMLKZWSy0R5g==", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } - }, - "tmp": { - "version": "0.1.0", - "resolved": "https://registry.npmjs.org/tmp/-/tmp-0.1.0.tgz", - "integrity": "sha512-J7Z2K08jbGcdA1kkQpJSqLF6T0tdQqpR2pnSUXsIchbPdTI9v3e85cLW0d6WDhwuAleOV71j2xWs8qMPfK7nKw==", - "dev": true, - "requires": { - "rimraf": "^2.6.3" - } - } - } - }, "dashdash": { "version": "1.14.1", "resolved": "https://registry.npmjs.org/dashdash/-/dashdash-1.14.1.tgz", @@ -2910,12 +2542,6 @@ "assert-plus": "^1.0.0" } }, - "date-fns": { - "version": "1.30.1", - "resolved": "https://registry.npmjs.org/date-fns/-/date-fns-1.30.1.tgz", - "integrity": "sha512-hBSVCvSmWC+QypYObzwGOd9wqdDpOt+0wl0KbU+R+uuZBS1jN8VsD1ss3irQDknRj5NvxiTF6oj/nDRnN/UQNw==", - "dev": true - }, "debug": { "version": "4.1.1", "resolved": "https://registry.npmjs.org/debug/-/debug-4.1.1.tgz", @@ -3184,42 +2810,6 @@ "integrity": "sha1-Cr9PHKpbyx96nYrMbepPqqBLrJs=", "dev": true }, - "eventemitter2": { - "version": "6.4.3", - "resolved": "https://registry.npmjs.org/eventemitter2/-/eventemitter2-6.4.3.tgz", - "integrity": "sha512-t0A2msp6BzOf+QAcI6z9XMktLj52OjGQg+8SJH6v5+3uxNpWYRR3wQmfA+6xtMU9kOC59qk9licus5dYcrYkMQ==", - "dev": true - }, - "execa": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/execa/-/execa-1.0.0.tgz", - "integrity": "sha512-adbxcyWV46qiHyvSp50TKt05tB4tK3HcmF7/nxfAdhnox83seTDbwnaqKO4sXRy7roHAIFqJP/Rw/AuEbX61LA==", - "dev": true, - "requires": { - "cross-spawn": "^6.0.0", - "get-stream": "^4.0.0", - "is-stream": "^1.1.0", - "npm-run-path": "^2.0.0", - "p-finally": "^1.0.0", - "signal-exit": "^3.0.0", - "strip-eof": "^1.0.0" - } - }, - "executable": { - "version": "4.1.1", - "resolved": "https://registry.npmjs.org/executable/-/executable-4.1.1.tgz", - "integrity": "sha512-8iA79xD3uAch729dUG8xaaBBFGaEa0wdD2VkYLFHwlqosEj/jT66AzcreRDSgV7ehnNLBW2WR5jIXwGKjVdTLg==", - "dev": true, - "requires": { - "pify": "^2.2.0" - } - }, - "exit-hook": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/exit-hook/-/exit-hook-1.1.1.tgz", - "integrity": "sha1-8FyiM7SMBdVP/wd2XfhQfpXAL/g=", - "dev": true - }, "expand-brackets": { "version": "2.1.4", "resolved": "https://registry.npmjs.org/expand-brackets/-/expand-brackets-2.1.4.tgz", @@ -3362,50 +2952,6 @@ } } }, - "extract-zip": { - "version": "1.7.0", - "resolved": "https://registry.npmjs.org/extract-zip/-/extract-zip-1.7.0.tgz", - "integrity": "sha512-xoh5G1W/PB0/27lXgMQyIhP5DSY/LhoCsOyZgb+6iMmRtCwVBo55uKaMoEYrDCKQhWvqEip5ZPKAc6eFNyf/MA==", - "dev": true, - "requires": { - "concat-stream": "^1.6.2", - "debug": "^2.6.9", - "mkdirp": "^0.5.4", - "yauzl": "^2.10.0" - }, - "dependencies": { - "debug": { - "version": "2.6.9", - "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz", - "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", - "dev": true, - "requires": { - "ms": "2.0.0" - } - }, - "minimist": { - "version": "1.2.5", - "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.5.tgz", - "integrity": "sha512-FM9nNUYrRBAELZQT3xeZQ7fmMOBg6nWNmJKTcgsJeaLstP/UODVpGsr5OhXhhXg6f+qtJ8uiZ+PUxkDWcgIXLw==", - "dev": true - }, - "mkdirp": { - "version": "0.5.5", - "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-0.5.5.tgz", - "integrity": "sha512-NKmAlESf6jMGym1++R0Ra7wvhV+wFW63FaSOFPwRahvea0gMUcGUhVeAg/0BC0wiv9ih5NYPB1Wn1UEI1/L+xQ==", - "dev": true, - "requires": { - "minimist": "^1.2.5" - } - }, - "ms": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", - "integrity": "sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g=", - "dev": true - } - } - }, "extsprintf": { "version": "1.3.0", "resolved": "https://registry.npmjs.org/extsprintf/-/extsprintf-1.3.0.tgz", @@ -3449,25 +2995,6 @@ "integrity": "sha1-1RQsDK7msRifh9OnYREGT4bIu/I=", "dev": true }, - "fd-slicer": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/fd-slicer/-/fd-slicer-1.1.0.tgz", - "integrity": "sha1-JcfInLH5B3+IkbvmHY85Dq4lbx4=", - "dev": true, - "requires": { - "pend": "~1.2.0" - } - }, - "figures": { - "version": "1.7.0", - "resolved": "https://registry.npmjs.org/figures/-/figures-1.7.0.tgz", - "integrity": "sha1-y+Hjr/zxzUS4DK3+0o3Hk6lwHS4=", - "dev": true, - "requires": { - "escape-string-regexp": "^1.0.5", - "object-assign": "^4.1.0" - } - }, "fill-range": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-4.0.0.tgz", @@ -3535,17 +3062,6 @@ "integrity": "sha512-y6OAwoSIf7FyjMIv94u+b5rdheZEjzR63GTyZJm5qh4Bi+2YgwLCcI/fPFZkL5PSixOt6ZNKm+w+Hfp/Bciwow==", "dev": true }, - "fs-extra": { - "version": "8.1.0", - "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-8.1.0.tgz", - "integrity": "sha512-yhlQgA6mnOJUKOsRUFsgJdQCvkKhcz8tlZG5HBQfReYZy46OwLcY+Zia0mtdHsOo9y/hP+CxMN0TU9QxoOtG4g==", - "dev": true, - "requires": { - "graceful-fs": "^4.2.0", - "jsonfile": "^4.0.0", - "universalify": "^0.1.0" - } - }, "fs.realpath": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz", @@ -3564,38 +3080,12 @@ "integrity": "sha1-uWjGsKBDhDJJAui/Gl3zJXmkUP4=", "dev": true }, - "get-stream": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/get-stream/-/get-stream-4.1.0.tgz", - "integrity": "sha512-GMat4EJ5161kIy2HevLlr4luNjBgvmj413KaQA7jt4V8B4RDsfpHk7WQ9GVqfYyyx8OS/L66Kox+rJRNklLK7w==", - "dev": true, - "requires": { - "pump": "^3.0.0" - } - }, - "get-value": { - "version": "2.0.6", - "resolved": "https://registry.npmjs.org/get-value/-/get-value-2.0.6.tgz", - "integrity": "sha1-3BXKHGcjh8p2vTesCjlbogQqLCg=", - "dev": true - }, - "getos": { - "version": "3.2.1", - "resolved": "https://registry.npmjs.org/getos/-/getos-3.2.1.tgz", - "integrity": "sha512-U56CfOK17OKgTVqozZjUKNdkfEv6jk5WISBJ8SHoagjE6L69zOwl3Z+O8myjY9MEW3i2HPWQBt/LTbCgcC973Q==", - "dev": true, - "requires": { - "async": "^3.2.0" - }, - "dependencies": { - "async": { - "version": "3.2.0", - "resolved": "https://registry.npmjs.org/async/-/async-3.2.0.tgz", - "integrity": "sha512-TR2mEZFVOj2pLStYxLht7TyfuRzaydfpxr3k9RpHIzMgw7A64dzsdqCxH1WJyQdoe8T10nDXd9wnEigmiuHIZw==", - "dev": true - } - } - }, + "get-value": { + "version": "2.0.6", + "resolved": "https://registry.npmjs.org/get-value/-/get-value-2.0.6.tgz", + "integrity": "sha1-3BXKHGcjh8p2vTesCjlbogQqLCg=", + "dev": true + }, "getpass": { "version": "0.1.7", "resolved": "https://registry.npmjs.org/getpass/-/getpass-0.1.7.tgz", @@ -3646,15 +3136,6 @@ "integrity": "sha1-jFoUlNIGbFcMw7/kSWF1rMTVAqs=", "dev": true }, - "global-dirs": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/global-dirs/-/global-dirs-2.0.1.tgz", - "integrity": "sha512-5HqUqdhkEovj2Of/ms3IeS/EekcO54ytHRLV4PEY2rhRwrHXLQjeVEES0Lhka0xwNDtGYn58wyC4s5+MHsOO6A==", - "dev": true, - "requires": { - "ini": "^1.3.5" - } - }, "globals": { "version": "11.12.0", "resolved": "https://registry.npmjs.org/globals/-/globals-11.12.0.tgz", @@ -3892,12 +3373,6 @@ "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==", "dev": true }, - "ini": { - "version": "1.3.5", - "resolved": "https://registry.npmjs.org/ini/-/ini-1.3.5.tgz", - "integrity": "sha512-RZY5huIKCMRWDUqZlEi72f/lmXKMvuszcMBduliQ3nnWbx9X/ZBQO7DijMEYS9EhHBb2qacRUMtC7svLwe0lcw==", - "dev": true - }, "invariant": { "version": "2.2.4", "resolved": "https://registry.npmjs.org/invariant/-/invariant-2.2.4.tgz", @@ -4046,24 +3521,6 @@ } } }, - "is-installed-globally": { - "version": "0.3.2", - "resolved": "https://registry.npmjs.org/is-installed-globally/-/is-installed-globally-0.3.2.tgz", - "integrity": "sha512-wZ8x1js7Ia0kecP/CHM/3ABkAmujX7WPvQk6uu3Fly/Mk44pySulQpnHG46OMjHGXApINnV4QhY3SWnECO2z5g==", - "dev": true, - "requires": { - "global-dirs": "^2.0.1", - "is-path-inside": "^3.0.1" - }, - "dependencies": { - "is-path-inside": { - "version": "3.0.2", - "resolved": "https://registry.npmjs.org/is-path-inside/-/is-path-inside-3.0.2.tgz", - "integrity": "sha512-/2UGPSgmtqwo1ktx8NDHjuPwZWmHhO+gj0f93EkhLB5RgW9RZevWYYlIkS6zePc6U2WpOdQYIwHe9YC4DWEBVg==", - "dev": true - } - } - }, "is-jquery-obj": { "version": "0.1.1", "resolved": "https://registry.npmjs.org/is-jquery-obj/-/is-jquery-obj-0.1.1.tgz", @@ -4096,15 +3553,6 @@ } } }, - "is-observable": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/is-observable/-/is-observable-1.1.0.tgz", - "integrity": "sha512-NqCa4Sa2d+u7BWc6CukaObG3Fh+CU9bvixbpcXYhy2VvYS7vVGIdAgnIS5Ks3A/cqk4rebLJ9s8zBstT2aKnIA==", - "dev": true, - "requires": { - "symbol-observable": "^1.1.0" - } - }, "is-path-cwd": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/is-path-cwd/-/is-path-cwd-1.0.0.tgz", @@ -4138,12 +3586,6 @@ "isobject": "^3.0.1" } }, - "is-promise": { - "version": "2.2.2", - "resolved": "https://registry.npmjs.org/is-promise/-/is-promise-2.2.2.tgz", - "integrity": "sha512-+lP4/6lKUBfQjZ2pdxThZvLUAafmZb8OAxFb8XXtiQmS35INgr85hdOGoEs124ez1FCnZJt6jau/T+alh58QFQ==", - "dev": true - }, "is-stream": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/is-stream/-/is-stream-1.1.0.tgz", @@ -4243,15 +3685,6 @@ "minimist": "^1.2.0" } }, - "jsonfile": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/jsonfile/-/jsonfile-4.0.0.tgz", - "integrity": "sha1-h3Gq4HmbZAdrdmQPygWPnBDjPss=", - "dev": true, - "requires": { - "graceful-fs": "^4.1.6" - } - }, "jsprim": { "version": "1.4.1", "resolved": "https://registry.npmjs.org/jsprim/-/jsprim-1.4.1.tgz", @@ -4270,12 +3703,6 @@ "integrity": "sha512-s5kLOcnH0XqDO+FvuaLX8DDjZ18CGFk7VygH40QoKPUQhW4e2rvM0rwUq0t8IQDOwYSeLK01U90OjzBTme2QqA==", "dev": true }, - "lazy-ass": { - "version": "1.6.0", - "resolved": "https://registry.npmjs.org/lazy-ass/-/lazy-ass-1.6.0.tgz", - "integrity": "sha1-eZllXoZGwX8In90YfRUNMyTVRRM=", - "dev": true - }, "lazystream": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/lazystream/-/lazystream-1.0.0.tgz", @@ -4294,237 +3721,12 @@ "os-family": "^1.0.0" } }, - "listr": { - "version": "0.14.3", - "resolved": "https://registry.npmjs.org/listr/-/listr-0.14.3.tgz", - "integrity": "sha512-RmAl7su35BFd/xoMamRjpIE4j3v+L28o8CT5YhAXQJm1fD+1l9ngXY8JAQRJ+tFK2i5njvi0iRUKV09vPwA0iA==", - "dev": true, - "requires": { - "@samverschueren/stream-to-observable": "^0.3.0", - "is-observable": "^1.1.0", - "is-promise": "^2.1.0", - "is-stream": "^1.1.0", - "listr-silent-renderer": "^1.1.1", - "listr-update-renderer": "^0.5.0", - "listr-verbose-renderer": "^0.5.0", - "p-map": "^2.0.0", - "rxjs": "^6.3.3" - }, - "dependencies": { - "p-map": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/p-map/-/p-map-2.1.0.tgz", - "integrity": "sha512-y3b8Kpd8OAN444hxfBbFfj1FY/RjtTd8tzYwhUqNYXx0fXx2iX4maP4Qr6qhIKbQXI02wTLAda4fYUbDagTUFw==", - "dev": true - } - } - }, - "listr-silent-renderer": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/listr-silent-renderer/-/listr-silent-renderer-1.1.1.tgz", - "integrity": "sha1-kktaN1cVN3C/Go4/v3S4u/P5JC4=", - "dev": true - }, - "listr-update-renderer": { - "version": "0.5.0", - "resolved": "https://registry.npmjs.org/listr-update-renderer/-/listr-update-renderer-0.5.0.tgz", - "integrity": "sha512-tKRsZpKz8GSGqoI/+caPmfrypiaq+OQCbd+CovEC24uk1h952lVj5sC7SqyFUm+OaJ5HN/a1YLt5cit2FMNsFA==", - "dev": true, - "requires": { - "chalk": "^1.1.3", - "cli-truncate": "^0.2.1", - "elegant-spinner": "^1.0.1", - "figures": "^1.7.0", - "indent-string": "^3.0.0", - "log-symbols": "^1.0.2", - "log-update": "^2.3.0", - "strip-ansi": "^3.0.1" - }, - "dependencies": { - "ansi-styles": { - "version": "2.2.1", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-2.2.1.tgz", - "integrity": "sha1-tDLdM1i2NM914eRmQ2gkBTPB3b4=", - "dev": true - }, - "chalk": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-1.1.3.tgz", - "integrity": "sha1-qBFcVeSnAv5NFQq9OHKCKn4J/Jg=", - "dev": true, - "requires": { - "ansi-styles": "^2.2.1", - "escape-string-regexp": "^1.0.2", - "has-ansi": "^2.0.0", - "strip-ansi": "^3.0.0", - "supports-color": "^2.0.0" - } - }, - "indent-string": { - "version": "3.2.0", - "resolved": "https://registry.npmjs.org/indent-string/-/indent-string-3.2.0.tgz", - "integrity": "sha1-Sl/W0nzDMvN+VBmlBNu4NxBckok=", - "dev": true - }, - "log-symbols": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/log-symbols/-/log-symbols-1.0.2.tgz", - "integrity": "sha1-N2/3tY6jCGoPCfrMdGF+ylAeGhg=", - "dev": true, - "requires": { - "chalk": "^1.0.0" - } - }, - "supports-color": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-2.0.0.tgz", - "integrity": "sha1-U10EXOa2Nj+kARcIRimZXp3zJMc=", - "dev": true - } - } - }, - "listr-verbose-renderer": { - "version": "0.5.0", - "resolved": "https://registry.npmjs.org/listr-verbose-renderer/-/listr-verbose-renderer-0.5.0.tgz", - "integrity": "sha512-04PDPqSlsqIOaaaGZ+41vq5FejI9auqTInicFRndCBgE3bXG8D6W1I+mWhk+1nqbHmyhla/6BUrd5OSiHwKRXw==", - "dev": true, - "requires": { - "chalk": "^2.4.1", - "cli-cursor": "^2.1.0", - "date-fns": "^1.27.2", - "figures": "^2.0.0" - }, - "dependencies": { - "cli-cursor": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/cli-cursor/-/cli-cursor-2.1.0.tgz", - "integrity": "sha1-s12sN2R5+sw+lHR9QdDQ9SOP/LU=", - "dev": true, - "requires": { - "restore-cursor": "^2.0.0" - } - }, - "figures": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/figures/-/figures-2.0.0.tgz", - "integrity": "sha1-OrGi0qYsi/tDGgyUy3l6L84nyWI=", - "dev": true, - "requires": { - "escape-string-regexp": "^1.0.5" - } - }, - "restore-cursor": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/restore-cursor/-/restore-cursor-2.0.0.tgz", - "integrity": "sha1-n37ih/gv0ybU/RYpI9YhKe7g368=", - "dev": true, - "requires": { - "onetime": "^2.0.0", - "signal-exit": "^3.0.2" - } - } - } - }, "lodash": { "version": "4.17.11", "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.11.tgz", "integrity": "sha512-cQKh8igo5QUhZ7lg38DYWAxMvjSAKG0A8wGSVimP07SIUEK2UO+arSRKbRZWtelMtN5V0Hkwh5ryOto/SshYIg==", "dev": true }, - "lodash.once": { - "version": "4.1.1", - "resolved": "https://registry.npmjs.org/lodash.once/-/lodash.once-4.1.1.tgz", - "integrity": "sha1-DdOXEhPHxW34gJd9UEyI+0cal6w=", - "dev": true - }, - "log-symbols": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/log-symbols/-/log-symbols-3.0.0.tgz", - "integrity": "sha512-dSkNGuI7iG3mfvDzUuYZyvk5dD9ocYCYzNU6CYDE6+Xqd+gwme6Z00NS3dUh8mq/73HaEtT7m6W+yUPtU6BZnQ==", - "dev": true, - "requires": { - "chalk": "^2.4.2" - } - }, - "log-update": { - "version": "2.3.0", - "resolved": "https://registry.npmjs.org/log-update/-/log-update-2.3.0.tgz", - "integrity": "sha1-iDKP19HOeTiykoN0bwsbwSayRwg=", - "dev": true, - "requires": { - "ansi-escapes": "^3.0.0", - "cli-cursor": "^2.0.0", - "wrap-ansi": "^3.0.1" - }, - "dependencies": { - "ansi-escapes": { - "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": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-3.0.0.tgz", - "integrity": "sha1-7QMXwyIGT3lGbAKWa922Bas32Zg=", - "dev": true - }, - "cli-cursor": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/cli-cursor/-/cli-cursor-2.1.0.tgz", - "integrity": "sha1-s12sN2R5+sw+lHR9QdDQ9SOP/LU=", - "dev": true, - "requires": { - "restore-cursor": "^2.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", - "integrity": "sha1-o7MKXE8ZkYMWeqq5O+764937ZU8=", - "dev": true - }, - "restore-cursor": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/restore-cursor/-/restore-cursor-2.0.0.tgz", - "integrity": "sha1-n37ih/gv0ybU/RYpI9YhKe7g368=", - "dev": true, - "requires": { - "onetime": "^2.0.0", - "signal-exit": "^3.0.2" - } - }, - "string-width": { - "version": "2.1.1", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-2.1.1.tgz", - "integrity": "sha512-nOqH59deCq9SRHlxq1Aw85Jnt4w6KvLKqWVik6oA9ZklXLNIOlqg4F2yrT1MVaTjAqvVwdfeZ7w7aCvJD7ugkw==", - "dev": true, - "requires": { - "is-fullwidth-code-point": "^2.0.0", - "strip-ansi": "^4.0.0" - } - }, - "strip-ansi": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-4.0.0.tgz", - "integrity": "sha1-qEeQIusaw2iocTibY1JixQXuNo8=", - "dev": true, - "requires": { - "ansi-regex": "^3.0.0" - } - }, - "wrap-ansi": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-3.0.1.tgz", - "integrity": "sha1-KIoE2H7aXChuBg3+jxNc6NAH+Lo=", - "dev": true, - "requires": { - "string-width": "^2.1.1", - "strip-ansi": "^4.0.0" - } - } - } - }, "log-update-async-hook": { "version": "2.0.2", "resolved": "https://registry.npmjs.org/log-update-async-hook/-/log-update-async-hook-2.0.2.tgz", @@ -4776,12 +3978,6 @@ "to-regex": "^3.0.1" } }, - "nice-try": { - "version": "1.0.5", - "resolved": "https://registry.npmjs.org/nice-try/-/nice-try-1.0.5.tgz", - "integrity": "sha512-1nh45deeb5olNY7eX82BkPO7SSxR5SSYJiPTrTdFUVYwAl8CKMA5N9PjTYkHiRjisVcxcQ1HXdLhx2qxxJzLNQ==", - "dev": true - }, "node-releases": { "version": "1.1.21", "resolved": "https://registry.npmjs.org/node-releases/-/node-releases-1.1.21.tgz", @@ -4806,15 +4002,6 @@ "remove-trailing-separator": "^1.0.1" } }, - "npm-run-path": { - "version": "2.0.2", - "resolved": "https://registry.npmjs.org/npm-run-path/-/npm-run-path-2.0.2.tgz", - "integrity": "sha1-NakjLfo11wZ7TLLd8jV7GHFTbF8=", - "dev": true, - "requires": { - "path-key": "^2.0.0" - } - }, "number-is-nan": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/number-is-nan/-/number-is-nan-1.0.1.tgz", @@ -4918,18 +4105,6 @@ "integrity": "sha1-u+Z0BseaqFxc/sdm/lc0VV36EnQ=", "dev": true }, - "ospath": { - "version": "1.2.2", - "resolved": "https://registry.npmjs.org/ospath/-/ospath-1.2.2.tgz", - "integrity": "sha1-EnZjl3Sj+O8lcvf+QoDg6kVQwHs=", - "dev": true - }, - "p-finally": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/p-finally/-/p-finally-1.0.0.tgz", - "integrity": "sha1-P7z7FbiZpEEjs0ttzBi3JDNqLK4=", - "dev": true - }, "p-map": { "version": "1.2.0", "resolved": "https://registry.npmjs.org/p-map/-/p-map-1.2.0.tgz", @@ -4966,12 +4141,6 @@ "integrity": "sha1-NlQX3t5EQw0cEa9hAn+s8HS9/FM=", "dev": true }, - "path-key": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/path-key/-/path-key-2.0.1.tgz", - "integrity": "sha1-QRyttXTFoUDTpLGRDUDYDMn0C0A=", - "dev": true - }, "path-parse": { "version": "1.0.6", "resolved": "https://registry.npmjs.org/path-parse/-/path-parse-1.0.6.tgz", @@ -5001,12 +4170,6 @@ "integrity": "sha1-uULm1L3mUwBe9rcTYd74cn0GReA=", "dev": true }, - "pend": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/pend/-/pend-1.2.0.tgz", - "integrity": "sha1-elfrVQpng/kRUzH89GY9XI4AelA=", - "dev": true - }, "performance-now": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/performance-now/-/performance-now-2.1.0.tgz", @@ -5046,12 +4209,6 @@ "integrity": "sha1-AerA/jta9xoqbAL+q7jB/vfgDqs=", "dev": true }, - "pretty-bytes": { - "version": "5.3.0", - "resolved": "https://registry.npmjs.org/pretty-bytes/-/pretty-bytes-5.3.0.tgz", - "integrity": "sha512-hjGrh+P926p4R4WbaB6OckyRtO0F0/lQBiT+0gnxjV+5kjPBrfVBFCsCLbMqVQeydvIoouYTCmmEURiH3R1Bdg==", - "dev": true - }, "private": { "version": "0.1.8", "resolved": "https://registry.npmjs.org/private/-/private-0.1.8.tgz", @@ -5085,16 +4242,6 @@ "integrity": "sha512-LTDP2uSrsc7XCb5lO7A8BI1qYxRe/8EqlRvMeEl6rsnYAqDOl8xHR+8lSAIVfrNaSAlTPTNOCgNjWcoUL3AZsw==", "dev": true }, - "pump": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/pump/-/pump-3.0.0.tgz", - "integrity": "sha512-LwZy+p3SFs1Pytd/jYct4wpv49HiYCqd9Rlc5ZVdk0V+8Yzv6jR5Blk3TRmPL1ft69TxP0IMZGJ+WPFU2BFhww==", - "dev": true, - "requires": { - "end-of-stream": "^1.1.0", - "once": "^1.3.1" - } - }, "punycode": { "version": "1.4.1", "resolved": "https://registry.npmjs.org/punycode/-/punycode-1.4.1.tgz", @@ -5119,18 +4266,6 @@ "integrity": "sha512-N5ZAX4/LxJmF+7wN74pUD6qAh9/wnvdQcjq9TZjevvXzSUo7bfmw91saqMjzGS2xq91/odN2dW/WOl7qQHNDGA==", "dev": true }, - "querystring": { - "version": "0.2.0", - "resolved": "https://registry.npmjs.org/querystring/-/querystring-0.2.0.tgz", - "integrity": "sha1-sgmEkgO7Jd+CDadW50cAWHhSFiA=", - "dev": true - }, - "ramda": { - "version": "0.26.1", - "resolved": "https://registry.npmjs.org/ramda/-/ramda-0.26.1.tgz", - "integrity": "sha512-hLWjpy7EnsDBb0p+Z3B7rPi3GDeRG5ZtiI33kJhTt+ORCd38AbAIjB/9zRIUoeTbE/AVX5ZkU7m6bznsvrf8eQ==", - "dev": true - }, "read-file-relative": { "version": "1.2.0", "resolved": "https://registry.npmjs.org/read-file-relative/-/read-file-relative-1.2.0.tgz", @@ -5311,15 +4446,6 @@ } } }, - "request-progress": { - "version": "3.0.0", - "resolved": "https://registry.npmjs.org/request-progress/-/request-progress-3.0.0.tgz", - "integrity": "sha1-TKdUCBx/7GP1BeT6qCWqBs1mnb4=", - "dev": true, - "requires": { - "throttleit": "^1.0.0" - } - }, "resolve": { "version": "1.11.0", "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.11.0.tgz", @@ -5358,24 +4484,6 @@ "integrity": "sha1-LGN/53yJOv0qZj/iGqkIAGjiBSo=", "dev": true }, - "restore-cursor": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/restore-cursor/-/restore-cursor-1.0.1.tgz", - "integrity": "sha1-NGYfRohjJ/7SmRR5FSJS35LapUE=", - "dev": true, - "requires": { - "exit-hook": "^1.0.0", - "onetime": "^1.0.0" - }, - "dependencies": { - "onetime": { - "version": "1.1.0", - "resolved": "https://registry.npmjs.org/onetime/-/onetime-1.1.0.tgz", - "integrity": "sha1-ofeDj4MUxRbwXs78vEzP4EtO14k=", - "dev": true - } - } - }, "ret": { "version": "0.1.15", "resolved": "https://registry.npmjs.org/ret/-/ret-0.1.15.tgz", @@ -5452,15 +4560,6 @@ "micromatch": "^3.1.10" } }, - "rxjs": { - "version": "6.6.2", - "resolved": "https://registry.npmjs.org/rxjs/-/rxjs-6.6.2.tgz", - "integrity": "sha512-BHdBMVoWC2sL26w//BCu3YzKT4s2jip/WhwsGEDmeKYBhKDZeYezVUnHatYB7L85v5xs0BAQmg6BEYJEKxBabg==", - "dev": true, - "requires": { - "tslib": "^1.9.0" - } - }, "safe-buffer": { "version": "5.1.2", "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", @@ -5578,39 +4677,12 @@ } } }, - "shebang-command": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/shebang-command/-/shebang-command-1.2.0.tgz", - "integrity": "sha1-RKrGW2lbAzmJaMOfNj/uXer98eo=", - "dev": true, - "requires": { - "shebang-regex": "^1.0.0" - } - }, - "shebang-regex": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/shebang-regex/-/shebang-regex-1.0.0.tgz", - "integrity": "sha1-2kL0l0DAtC2yypcoVxyxkMmO/qM=", - "dev": true - }, - "signal-exit": { - "version": "3.0.3", - "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.3.tgz", - "integrity": "sha512-VUJ49FC8U1OxwZLxIbTTrDvLnf/6TDgxZcK8wxR8zs13xpx7xbG60ndBlhNrFi2EMuFRoeDoJO7wthSLq42EjA==", - "dev": true - }, "slash": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/slash/-/slash-1.0.0.tgz", "integrity": "sha1-xB8vbDn8FtHNF61LXYlhFK5HDVU=", "dev": true }, - "slice-ansi": { - "version": "0.0.4", - "resolved": "https://registry.npmjs.org/slice-ansi/-/slice-ansi-0.0.4.tgz", - "integrity": "sha1-7b+JA/ZvfOL46v1s7tZeJkyDGzU=", - "dev": true - }, "snapdragon": { "version": "0.8.2", "resolved": "https://registry.npmjs.org/snapdragon/-/snapdragon-0.8.2.tgz", @@ -5867,12 +4939,6 @@ "is-utf8": "^0.2.0" } }, - "strip-eof": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/strip-eof/-/strip-eof-1.0.0.tgz", - "integrity": "sha1-u0P/VZim6wXYm1n80SnJgzE2Br8=", - "dev": true - }, "supports-color": { "version": "5.5.0", "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz", @@ -5882,12 +4948,6 @@ "has-flag": "^3.0.0" } }, - "symbol-observable": { - "version": "1.2.0", - "resolved": "https://registry.npmjs.org/symbol-observable/-/symbol-observable-1.2.0.tgz", - "integrity": "sha512-e900nM8RRtGhlV36KGEU9k65K3mPb1WV70OdjfxlG2EAuM1noi/E/BaW/uMhL7bPEssK8QV57vN3esixjUvcXQ==", - "dev": true - }, "tar-stream": { "version": "1.6.2", "resolved": "https://registry.npmjs.org/tar-stream/-/tar-stream-1.6.2.tgz", @@ -6219,12 +5279,6 @@ "integrity": "sha1-5tZsVyzhWvJmcGrw/WELKoQd1EM=", "dev": true }, - "throttleit": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/throttleit/-/throttleit-1.0.0.tgz", - "integrity": "sha1-nnhYNtr0Z0MUWlmEtiaNgoUorGw=", - "dev": true - }, "time-limit-promise": { "version": "1.0.4", "resolved": "https://registry.npmjs.org/time-limit-promise/-/time-limit-promise-1.0.4.tgz", @@ -6355,12 +5409,6 @@ } } }, - "tslib": { - "version": "1.13.0", - "resolved": "https://registry.npmjs.org/tslib/-/tslib-1.13.0.tgz", - "integrity": "sha512-i/6DQjL8Xf3be4K/E6Wgpekn5Qasl1usyw++dAA35Ue5orEn65VIxOA+YvNNl9HV3qv70T7CNwjODHZrLwvd1Q==", - "dev": true - }, "tunnel-agent": { "version": "0.6.0", "resolved": "https://registry.npmjs.org/tunnel-agent/-/tunnel-agent-0.6.0.tgz", @@ -6382,12 +5430,6 @@ "integrity": "sha512-0fr/mIH1dlO+x7TlcMy+bIDqKPsw/70tVyeHW787goQjhmqaZe10uwLujubK9q9Lg6Fiho1KUKDYz0Z7k7g5/g==", "dev": true }, - "typedarray": { - "version": "0.0.6", - "resolved": "https://registry.npmjs.org/typedarray/-/typedarray-0.0.6.tgz", - "integrity": "sha1-hnrHTjhkGHsdPUfZlqeOxciDB3c=", - "dev": true - }, "typescript": { "version": "3.9.7", "resolved": "https://registry.npmjs.org/typescript/-/typescript-3.9.7.tgz", @@ -6481,12 +5523,6 @@ } } }, - "universalify": { - "version": "0.1.2", - "resolved": "https://registry.npmjs.org/universalify/-/universalify-0.1.2.tgz", - "integrity": "sha512-rBJeI5CXAlmy1pV+617WB9J63U6XcazHHF2f2dbJix4XzpUF0RS3Zbj0FGIOCAva5P/d/GBOYaACQ1w+0azUkg==", - "dev": true - }, "unset-value": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/unset-value/-/unset-value-1.0.0.tgz", @@ -6527,12 +5563,6 @@ } } }, - "untildify": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/untildify/-/untildify-4.0.0.tgz", - "integrity": "sha512-KK8xQ1mkzZeg9inewmFVDNkg3l5LUhoq9kN6iWYB/CC9YMG8HA+c1Q8HwDe6dEX7kErrEVNVBO3fWsVq5iDgtw==", - "dev": true - }, "uri-js": { "version": "4.2.2", "resolved": "https://registry.npmjs.org/uri-js/-/uri-js-4.2.2.tgz", @@ -6556,24 +5586,6 @@ "integrity": "sha1-2pN/emLiH+wf0Y1Js1wpNQZ6bHI=", "dev": true }, - "url": { - "version": "0.11.0", - "resolved": "https://registry.npmjs.org/url/-/url-0.11.0.tgz", - "integrity": "sha1-ODjpfPxgUh63PFJajlW/3Z4uKPE=", - "dev": true, - "requires": { - "punycode": "1.3.2", - "querystring": "0.2.0" - }, - "dependencies": { - "punycode": { - "version": "1.3.2", - "resolved": "https://registry.npmjs.org/punycode/-/punycode-1.3.2.tgz", - "integrity": "sha1-llOgNvt8HuQjQvIyXM7v6jkmxI0=", - "dev": true - } - } - }, "use": { "version": "3.1.1", "resolved": "https://registry.npmjs.org/use/-/use-3.1.1.tgz", @@ -6745,16 +5757,6 @@ "integrity": "sha1-HBH5IY8HYImkfdUS+TxmmaaoHVI=", "dev": true }, - "yauzl": { - "version": "2.10.0", - "resolved": "https://registry.npmjs.org/yauzl/-/yauzl-2.10.0.tgz", - "integrity": "sha1-x+sXyT4RLLEIb6bY5R+wZnt5pfk=", - "dev": true, - "requires": { - "buffer-crc32": "~0.2.3", - "fd-slicer": "~1.1.0" - } - }, "yn": { "version": "3.1.1", "resolved": "https://registry.npmjs.org/yn/-/yn-3.1.1.tgz", diff --git a/package.json b/package.json index 4d89cc7da..bd2588c19 100644 --- a/package.json +++ b/package.json @@ -2,12 +2,21 @@ "name": "sortablejs", "exportName": "Sortable", "version": "1.10.2", + "scripts": { + "build:umd": "NODE_ENV=umd rollup -c ./scripts/umd-build.js", + "build:umd:watch": "set NODE_ENV=umd&& rollup -w -c ./scripts/umd-build.js", + "build:es": "set NODE_ENV=es&& rollup -c ./scripts/esm-build.js", + "build:es:watch": "set NODE_ENV=es&& rollup -w -c ./scripts/esm-build.js", + "minify": "node ./scripts/minify.js", + "build": "npm run build:es && npm run build:umd && npm run minify", + "test:compat": "ts-node ./scripts/test-compat.ts", + "test": "ts-node ./scripts/test.ts" + }, "devDependencies": { "@babel/core": "^7.4.4", "@babel/plugin-transform-object-assign": "^7.2.0", "@babel/preset-env": "^7.4.4", "@types/node": "^14.0.27", - "cypress": "^4.12.1", "fp-ts": "^2.8.1", "logging-ts": "^0.3.3", "rollup": "^1.11.3", @@ -24,16 +33,6 @@ "description": "JavaScript library for reorderable drag-and-drop lists on modern browsers and touch devices. No jQuery required. Supports Meteor, AngularJS, React, Polymer, Vue, Knockout and any CSS library, e.g. Bootstrap.", "main": "./Sortable.js", "module": "modular/sortable.esm.js", - "scripts": { - "build:umd": "NODE_ENV=umd rollup -c ./scripts/umd-build.js", - "build:umd:watch": "set NODE_ENV=umd&& rollup -w -c ./scripts/umd-build.js", - "build:es": "set NODE_ENV=es&& rollup -c ./scripts/esm-build.js", - "build:es:watch": "set NODE_ENV=es&& rollup -w -c ./scripts/esm-build.js", - "minify": "node ./scripts/minify.js", - "build": "npm run build:es && npm run build:umd && npm run minify", - "test:compat": "ts-node ./scripts/test-compat.ts", - "test": "ts-node ./scripts/test.ts" - }, "maintainers": [ "Konstantin Lebedev ", "Owen Mills " diff --git a/scripts/test-compat.ts b/scripts/test-compat.ts index a535dfcd9..4ae6281b9 100644 --- a/scripts/test-compat.ts +++ b/scripts/test-compat.ts @@ -58,7 +58,9 @@ const teLog = TE.fold( // settings used for these tests const settings = (runner: Runner): Runner => - runner.src("./tests/Sortable.compat.test.js").browsers(browsers); + runner + .src("./tests/e2e-saucelabs/Sortable.compat.test.js") + .browsers(browsers); export const program = pipe( runTests, diff --git a/scripts/test.ts b/scripts/test.ts index a40e8650d..172cf2af6 100644 --- a/scripts/test.ts +++ b/scripts/test.ts @@ -50,8 +50,8 @@ const teLog = TE.fold( // settings used for these tests const settings = (runner: Runner): Runner => runner - .src("./tests/Sortable.test.js") - .browsers("chrome:headless") + .src("./tests/e2e-local/Sortable.test.js") + .browsers("firefox:headless") .concurrency(3); export const program = pipe( diff --git a/tests/Sortable.compat.test.js b/tests/Sortable.compat.test.js deleted file mode 100644 index 7c00396b9..000000000 --- a/tests/Sortable.compat.test.js +++ /dev/null @@ -1,39 +0,0 @@ -import { Selector } from 'testcafe'; - - -fixture `Simple Sorting` - .page `./single-list.html`; - -let list1 = Selector('#list1'); - -test('Sort down list', async browser => { - const dragStartPosition = list1.child(0); - const dragEl = await dragStartPosition(); - const dragEndPosition = list1.child(2); - const targetStartPosition = list1.child(2); - const target = await targetStartPosition(); - const targetEndPosition = list1.child(1); - - await browser - .expect(dragStartPosition.innerText).eql(dragEl.innerText) - .expect(targetStartPosition.innerText).eql(target.innerText) - .dragToElement(dragEl, target) - .expect(dragEndPosition.innerText).eql(dragEl.innerText) - .expect(targetEndPosition.innerText).eql(target.innerText); -}); - -test('Sort up list', async browser => { - const dragStartPosition = list1.child(2); - const dragEl = await dragStartPosition(); - const dragEndPosition = list1.child(0); - const targetStartPosition = list1.child(0); - const target = await targetStartPosition(); - const targetEndPosition = list1.child(1); - - await browser - .expect(dragStartPosition.innerText).eql(dragEl.innerText) - .expect(targetStartPosition.innerText).eql(target.innerText) - .dragToElement(dragEl, target) - .expect(dragEndPosition.innerText).eql(dragEl.innerText) - .expect(targetEndPosition.innerText).eql(target.innerText); -}); diff --git a/tests/Sortable.test.js b/tests/Sortable.test.js deleted file mode 100644 index 59ce11f46..000000000 --- a/tests/Sortable.test.js +++ /dev/null @@ -1,386 +0,0 @@ -import { Selector } from 'testcafe'; -const itemHeight = 54; // px -const leeway = 1; - - -fixture `Simple Sorting` - .page `./single-list.html`; - -let list1 = Selector('#list1'); - -test('Sort down list', async browser => { - const dragStartPosition = list1.child(0); - const dragEl = await dragStartPosition(); - const dragEndPosition = list1.child(2); - const targetStartPosition = list1.child(2); - const target = await targetStartPosition(); - const targetEndPosition = list1.child(1); - - await browser - .expect(dragStartPosition.innerText).eql(dragEl.innerText) - .expect(targetStartPosition.innerText).eql(target.innerText) - .dragToElement(dragEl, target) - .expect(dragEndPosition.innerText).eql(dragEl.innerText) - .expect(targetEndPosition.innerText).eql(target.innerText); -}); - -test('Sort up list', async browser => { - const dragStartPosition = list1.child(2); - const dragEl = await dragStartPosition(); - const dragEndPosition = list1.child(0); - const targetStartPosition = list1.child(0); - const target = await targetStartPosition(); - const targetEndPosition = list1.child(1); - - await browser - .expect(dragStartPosition.innerText).eql(dragEl.innerText) - .expect(targetStartPosition.innerText).eql(target.innerText) - .dragToElement(dragEl, target) - .expect(dragEndPosition.innerText).eql(dragEl.innerText) - .expect(targetEndPosition.innerText).eql(target.innerText); -}); - -test('Swap threshold', async browser => { - const dragStartPosition = list1.child(0); - const dragEl = await dragStartPosition(); - const dragEndPosition = list1.child(1); - const targetStartPosition = list1.child(1); - const target = await targetStartPosition(); - const targetEndPosition = list1.child(0); - - await browser.eval(() => { - Sortable.get(document.getElementById('list1')).option('swapThreshold', 0.6); - }); - - - await browser - .expect(dragStartPosition.innerText).eql(dragEl.innerText) - .expect(targetStartPosition.innerText).eql(target.innerText) - .dragToElement(dragEl, target, { - destinationOffsetY: Math.round(itemHeight / 2 * 0.4 - leeway) - }) - .expect(dragStartPosition.innerText).eql(dragEl.innerText) - .expect(targetStartPosition.innerText).eql(target.innerText) - .dragToElement(dragEl, target, { - destinationOffsetY: Math.round(itemHeight / 2 * 0.4 + leeway) - }) - .expect(dragEndPosition.innerText).eql(dragEl.innerText) - .expect(targetEndPosition.innerText).eql(target.innerText); -}); - -test('Invert swap', async browser => { - const dragStartPosition = list1.child(0); - const dragEl = await dragStartPosition(); - const dragEndPosition = list1.child(1); - const targetStartPosition = list1.child(1); - const target = await targetStartPosition(); - const targetEndPosition = list1.child(0); - - await browser.eval(() => { - Sortable.get(document.getElementById('list1')).option('invertSwap', true); - }); - - - await browser - .expect(dragStartPosition.innerText).eql(dragEl.innerText) - .expect(targetStartPosition.innerText).eql(target.innerText) - .dragToElement(dragEl, target, { - destinationOffsetY: Math.round(itemHeight / 2 - leeway) - }) - .expect(dragStartPosition.innerText).eql(dragEl.innerText) - .expect(targetStartPosition.innerText).eql(target.innerText) - .dragToElement(dragEl, target, { - destinationOffsetY: Math.round(itemHeight / 2 + leeway) - }) - .expect(dragEndPosition.innerText).eql(dragEl.innerText) - .expect(targetEndPosition.innerText).eql(target.innerText); -}); - - -test('Inverted swap threshold', async browser => { - const dragStartPosition = list1.child(0); - const dragEl = await dragStartPosition(); - const dragEndPosition = list1.child(1); - const targetStartPosition = list1.child(1); - const target = await targetStartPosition(); - const targetEndPosition = list1.child(0); - - await browser.eval(() => { - Sortable.get(document.getElementById('list1')).option('invertSwap', true); - Sortable.get(document.getElementById('list1')).option('invertedSwapThreshold', 0.5); - }); - - - await browser - .expect(dragStartPosition.innerText).eql(dragEl.innerText) - .expect(targetStartPosition.innerText).eql(target.innerText) - .dragToElement(dragEl, target, { - destinationOffsetY: Math.round(itemHeight - (itemHeight / 2 * 0.5) - leeway) - }) - .expect(dragStartPosition.innerText).eql(dragEl.innerText) - .expect(targetStartPosition.innerText).eql(target.innerText) - .dragToElement(dragEl, target, { - destinationOffsetY: Math.round(itemHeight - (itemHeight / 2 * 0.5) + leeway) - }) - .expect(dragEndPosition.innerText).eql(dragEl.innerText) - .expect(targetEndPosition.innerText).eql(target.innerText); -}); - - -fixture `Grouping` - .page `./dual-list.html`; - -let list2 = Selector('#list2'); - -test('Move to list of the same group', async browser => { - const dragStartPosition = list1.child(0); - const dragEl = await dragStartPosition(); - const dragEndPosition = list2.child(0); - const targetStartPosition = list2.child(0); - const target = await targetStartPosition(); - const targetEndPosition = list2.child(1); - - await browser.eval(() => { - Sortable.get(document.getElementById('list2')).option('group', 'shared'); - }); - - await browser - .expect(dragStartPosition.innerText).eql(dragEl.innerText) - .expect(targetStartPosition.innerText).eql(target.innerText) - .dragToElement(dragEl, target, { offsetY: 0, destinationOffsetY: 0 }) - .expect(dragEndPosition.innerText).eql(dragEl.innerText) - .expect(targetEndPosition.innerText).eql(target.innerText); -}); - - -test('Do not move to list of different group', async browser => { - const dragStartPosition = list1.child(0); - const dragEl = await dragStartPosition(); - const targetStartPosition = list2.child(0); - const target = await targetStartPosition(); - - await browser.eval(() => { - Sortable.get(document.getElementById('list2')).option('group', null); - }); - - await browser - .expect(dragStartPosition.innerText).eql(dragEl.innerText) - .expect(targetStartPosition.innerText).eql(target.innerText) - .dragToElement(dragEl, target, { offsetY: 0, destinationOffsetY: 0 }) - .expect(dragStartPosition.innerText).eql(dragEl.innerText) - .expect(targetStartPosition.innerText).eql(target.innerText); -}); - - -test('Move to list with put:true', async browser => { - // Should allow insert, since pull defaults to `true` - const dragStartPosition = list1.child(0); - const dragEl = await dragStartPosition(); - const dragEndPosition = list2.child(0); - const targetStartPosition = list2.child(0); - const target = await targetStartPosition(); - const targetEndPosition = list2.child(1); - - await browser.eval(() => { - Sortable.get(document.getElementById('list2')).option('group', { put: true }); - }); - - await browser - .expect(dragStartPosition.innerText).eql(dragEl.innerText) - .expect(targetStartPosition.innerText).eql(target.innerText) - .dragToElement(dragEl, target, { offsetY: 0, destinationOffsetY: 0 }) - .expect(dragEndPosition.innerText).eql(dragEl.innerText) - .expect(targetEndPosition.innerText).eql(target.innerText); -}); - -test('Do not move from list with pull:false', async browser => { - // Should not allow insert, since put defaults to `false` - const dragStartPosition = list1.child(0); - const dragEl = await dragStartPosition(); - const targetStartPosition = list2.child(0); - const target = await targetStartPosition(); - - await browser.eval(() => { - Sortable.get(document.getElementById('list1')).option('group', { pull: false }); - }); - - await browser - .expect(dragStartPosition.innerText).eql(dragEl.innerText) - .expect(targetStartPosition.innerText).eql(target.innerText) - .dragToElement(dragEl, target, { offsetY: 0, destinationOffsetY: 0 }) - .expect(dragStartPosition.innerText).eql(dragEl.innerText) - .expect(targetStartPosition.innerText).eql(target.innerText); -}); - -test('Clone element if pull:"clone"', async browser => { - const dragStartPosition = list1.child(0); - const dragEl = await dragStartPosition(); - const dragEndPosition = list2.child(0); - const targetStartPosition = list2.child(0); - const target = await targetStartPosition(); - const targetEndPosition = list2.child(1); - - await browser.eval(() => { - Sortable.get(document.getElementById('list1')).option('group', { pull: 'clone' }); - Sortable.get(document.getElementById('list2')).option('group', { put: true }); - }); - - await browser - .expect(dragStartPosition.innerText).eql(dragEl.innerText) - .expect(targetStartPosition.innerText).eql(target.innerText) - .dragToElement(dragEl, target, { offsetY: 0, destinationOffsetY: 0 }) - .expect(dragStartPosition.innerText).eql(dragEl.innerText) // clone check - .expect(dragEndPosition.innerText).eql(dragEl.innerText) - .expect(targetEndPosition.innerText).eql(target.innerText); -}); - - - -fixture `Handles` - .page `./handles.html`; - -test('Do not allow dragging not using handle', async browser => { - const dragStartPosition = list1.child(0); - const dragEl = await dragStartPosition(); - const targetStartPosition = list1.child(1); - const target = await targetStartPosition(); - - await browser - .expect(dragStartPosition.innerText).eql(dragEl.innerText) - .expect(targetStartPosition.innerText).eql(target.innerText) - .dragToElement(dragEl, target) - .expect(dragStartPosition.innerText).eql(dragEl.innerText) - .expect(targetStartPosition.innerText).eql(target.innerText); -}); - - -test('Allow dragging using handle', async browser => { - const dragStartPosition = list1.child(0); - const dragEl = await dragStartPosition(); - const dragEndPosition = list1.child(1); - const targetStartPosition = list1.child(1); - const target = await targetStartPosition(); - const targetEndPosition = list1.child(0); - - await browser - .expect(dragStartPosition.innerText).eql(dragEl.innerText) - .expect(targetStartPosition.innerText).eql(target.innerText) - .dragToElement(await dragStartPosition.child('.handle'), target) - .expect(dragEndPosition.innerText).eql(dragEl.innerText) - .expect(targetEndPosition.innerText).eql(target.innerText); -}); - -fixture `Filter` - .page `./filter.html`; - -test('Do not allow dragging of filtered element', async browser => { - const dragStartPosition = list1.child('.filtered'); - const dragEl = await dragStartPosition(); - const targetStartPosition = dragStartPosition.nextSibling(1); - const target = await targetStartPosition(); - - await browser - .expect(dragStartPosition.innerText).eql(dragEl.innerText) - .expect(targetStartPosition.innerText).eql(target.innerText) - .dragToElement(dragEl, target) - .expect(dragStartPosition.innerText).eql(dragEl.innerText) - .expect(targetStartPosition.innerText).eql(target.innerText); -}); - - -test('Allow dragging of non-filtered element', async browser => { - const dragStartPosition = list1.child(':not(.filtered)'); - const dragEl = await dragStartPosition(); - const dragEndPosition = dragStartPosition.nextSibling(1); - const targetStartPosition = dragStartPosition.nextSibling(1); - const target = await targetStartPosition(); - const targetEndPosition = dragStartPosition.nextSibling(0); - - await browser - .expect(dragStartPosition.innerText).eql(dragEl.innerText) - .expect(targetStartPosition.innerText).eql(target.innerText) - .dragToElement(dragEl, target) - .expect(dragEndPosition.innerText).eql(dragEl.innerText) - .expect(targetEndPosition.innerText).eql(target.innerText); -}); - - - -fixture `Nested` - .page `./nested.html`; - -let list1n1 = Selector('.n1'); -let list1n2 = Selector('.n2'); -let list2n1 = Selector('.n1:nth-of-type(2)'); - -test('Dragging from level 1 to level 0', async browser => { - const dragStartPosition = list1n1.child(0); - const dragEl = await dragStartPosition(); - const dragEndPosition = list1.child(2); - const targetStartPosition = list1.child(2); - const target = await targetStartPosition(); - const targetEndPosition = list1.child(3); - - await browser - .expect(dragStartPosition.innerText).eql(dragEl.innerText) - .expect(targetStartPosition.innerText).eql(target.innerText) - .dragToElement(dragEl, target, { destinationOffsetY: 0 }) - .expect(dragEndPosition.innerText).eql(dragEl.innerText) - .expect(targetEndPosition.innerText).eql(target.innerText); -}); - - -test('Dragging from level 0 to level 2', async browser => { - const dragStartPosition = list1.child(1); - const dragEl = await dragStartPosition(); - const dragEndPosition = list1n2.child(2); - const targetStartPosition = list1n2.child(2); - const target = await targetStartPosition(); - const targetEndPosition = list1n2.child(3); - - await browser - .expect(dragStartPosition.innerText).eql(dragEl.innerText) - .expect(targetStartPosition.innerText).eql(target.innerText) - .dragToElement(dragEl, target, { destinationOffsetY: 0 }) - .expect(dragEndPosition.innerText).eql(dragEl.innerText) - .expect(targetEndPosition.innerText).eql(target.innerText); -}); - - -fixture `Empty Insert` - .page `./empty-list.html`; - -test('Insert into empty list if within emptyInsertThreshold', async browser => { - const threshold = await browser.eval(() => Sortable.get(document.getElementById('list2')).option('emptyInsertThreshold')); - const dragStartPosition = list1.child(0); - const dragEl = await dragStartPosition(); - const dragEndPosition = list2.child(0); - // Must use rects since testcafe won't drag to element that is "not visible" - const dragRect = dragEl.boundingClientRect; - const list2Rect = await list2.boundingClientRect; - - - await browser - .expect(dragStartPosition.innerText).eql(dragEl.innerText) - .drag(dragEl, Math.round(list2Rect.left - dragRect.left) - (threshold - 1), -(threshold - 1), { - offsetY: 0, - offsetX: 0 - }) - .expect(dragEndPosition.innerText).eql(dragEl.innerText); -}); - -test('Do not insert into empty list if outside emptyInsertThreshold', async browser => { - const threshold = await browser.eval(() => Sortable.get(document.getElementById('list2')).option('emptyInsertThreshold')); - const dragStartPosition = list1.child(0); - const dragEl = await dragStartPosition(); - const dragRect = dragEl.boundingClientRect; - const list2Rect = await list2.boundingClientRect; - - await browser - .expect(dragStartPosition.innerText).eql(dragEl.innerText) - .drag(dragEl, Math.round(list2Rect.left - dragRect.left) - (threshold + 1), -(threshold + 1), { - offsetY: 0, - offsetX: 0 - }) - .expect(dragStartPosition.innerText).eql(dragEl.innerText); -}); diff --git a/tests/dual-list.html b/tests/dual-list.html deleted file mode 100644 index 6d7e15b9b..000000000 --- a/tests/dual-list.html +++ /dev/null @@ -1,34 +0,0 @@ - - - - - - - - -
-
Item 1.1
-
Item 1.2
-
Item 1.3
-
Item 1.4
-
Item 1.5
-
- -
-
Item 2.1
-
Item 2.2
-
Item 2.3
-
Item 2.4
-
Item 2.5
-
- - - - - - - - diff --git a/tests/e2e-fixtures/dual-list.html b/tests/e2e-fixtures/dual-list.html new file mode 100644 index 000000000..93942630d --- /dev/null +++ b/tests/e2e-fixtures/dual-list.html @@ -0,0 +1,31 @@ + + + + + + + +
+
Item 1.1
+
Item 1.2
+
Item 1.3
+
Item 1.4
+
Item 1.5
+
+ +
+
Item 2.1
+
Item 2.2
+
Item 2.3
+
Item 2.4
+
Item 2.5
+
+ + + + + + diff --git a/tests/e2e-fixtures/empty-list.html b/tests/e2e-fixtures/empty-list.html new file mode 100644 index 000000000..d590e864f --- /dev/null +++ b/tests/e2e-fixtures/empty-list.html @@ -0,0 +1,25 @@ + + + + + + + +
+
Item 1.1
+
Item 1.2
+
Item 1.3
+
Item 1.4
+
Item 1.5
+
+ +
+ + + + + + diff --git a/tests/e2e-fixtures/filter.html b/tests/e2e-fixtures/filter.html new file mode 100644 index 000000000..d3503d79f --- /dev/null +++ b/tests/e2e-fixtures/filter.html @@ -0,0 +1,22 @@ + + + + + + + +
+
Item 1.1
+
Item 1.2
+
Item 1.3
+
Item 1.4
+
Item 1.5
+
+ + + + + + diff --git a/tests/e2e-fixtures/handles.html b/tests/e2e-fixtures/handles.html new file mode 100644 index 000000000..2fd71d541 --- /dev/null +++ b/tests/e2e-fixtures/handles.html @@ -0,0 +1,22 @@ + + + + + + + +
+
::Item 1.1
+
::Item 1.2
+
::Item 1.3
+
::Item 1.4
+
::Item 1.5
+
+ + + + + + diff --git a/tests/e2e-fixtures/nested.html b/tests/e2e-fixtures/nested.html new file mode 100644 index 000000000..170385e3d --- /dev/null +++ b/tests/e2e-fixtures/nested.html @@ -0,0 +1,67 @@ + + + + + + + +
+
+ Item 1.1 +
+
Item 2.1
+
+ Item 2.2 +
+
Item 3.1
+
Item 3.2
+
Item 3.3
+
Item 3.4
+
+
+
Item 2.3
+
Item 2.4
+
+
+
Item 1.2
+
Item 1.3
+
+ Item 1.4 +
+
Item 2.1
+
Item 2.2
+
Item 2.3
+
Item 2.4
+
+
+
Item 1.5
+
+ + + + + + + + diff --git a/tests/e2e-fixtures/single-list.html b/tests/e2e-fixtures/single-list.html new file mode 100644 index 000000000..f61ddec62 --- /dev/null +++ b/tests/e2e-fixtures/single-list.html @@ -0,0 +1,22 @@ + + + + + + + +
+
Item 1.1
+
Item 1.2
+
Item 1.3
+
Item 1.4
+
Item 1.5
+
+ + + + + + diff --git a/tests/style.css b/tests/e2e-fixtures/style.css similarity index 100% rename from tests/style.css rename to tests/e2e-fixtures/style.css diff --git a/tests/e2e-local/Sortable.test.js b/tests/e2e-local/Sortable.test.js new file mode 100644 index 000000000..8fdc3211d --- /dev/null +++ b/tests/e2e-local/Sortable.test.js @@ -0,0 +1,471 @@ +import { Selector } from "testcafe"; +const itemHeight = 54; // px +const leeway = 1; + +fixture`Simple Sorting`.page`../e2e-fixtures/single-list.html`; + +let list1 = Selector("#list1"); + +test("Sort down list", async (browser) => { + const dragStartPosition = list1.child(0); + const dragEl = await dragStartPosition(); + const dragEndPosition = list1.child(2); + const targetStartPosition = list1.child(2); + const target = await targetStartPosition(); + const targetEndPosition = list1.child(1); + + await browser + .expect(dragStartPosition.innerText) + .eql(dragEl.innerText) + .expect(targetStartPosition.innerText) + .eql(target.innerText) + .dragToElement(dragEl, target) + .expect(dragEndPosition.innerText) + .eql(dragEl.innerText) + .expect(targetEndPosition.innerText) + .eql(target.innerText); +}); + +test("Sort up list", async (browser) => { + const dragStartPosition = list1.child(2); + const dragEl = await dragStartPosition(); + const dragEndPosition = list1.child(0); + const targetStartPosition = list1.child(0); + const target = await targetStartPosition(); + const targetEndPosition = list1.child(1); + + await browser + .expect(dragStartPosition.innerText) + .eql(dragEl.innerText) + .expect(targetStartPosition.innerText) + .eql(target.innerText) + .dragToElement(dragEl, target) + .expect(dragEndPosition.innerText) + .eql(dragEl.innerText) + .expect(targetEndPosition.innerText) + .eql(target.innerText); +}); + +test("Swap threshold", async (browser) => { + const dragStartPosition = list1.child(0); + const dragEl = await dragStartPosition(); + const dragEndPosition = list1.child(1); + const targetStartPosition = list1.child(1); + const target = await targetStartPosition(); + const targetEndPosition = list1.child(0); + + await browser.eval(() => { + Sortable.get(document.getElementById("list1")).option("swapThreshold", 0.6); + }); + + await browser + .expect(dragStartPosition.innerText) + .eql(dragEl.innerText) + .expect(targetStartPosition.innerText) + .eql(target.innerText) + .dragToElement(dragEl, target, { + destinationOffsetY: Math.round((itemHeight / 2) * 0.4 - leeway), + }) + .expect(dragStartPosition.innerText) + .eql(dragEl.innerText) + .expect(targetStartPosition.innerText) + .eql(target.innerText) + .dragToElement(dragEl, target, { + destinationOffsetY: Math.round((itemHeight / 2) * 0.4 + leeway), + }) + .expect(dragEndPosition.innerText) + .eql(dragEl.innerText) + .expect(targetEndPosition.innerText) + .eql(target.innerText); +}); + +test("Invert swap", async (browser) => { + const dragStartPosition = list1.child(0); + const dragEl = await dragStartPosition(); + const dragEndPosition = list1.child(1); + const targetStartPosition = list1.child(1); + const target = await targetStartPosition(); + const targetEndPosition = list1.child(0); + + await browser.eval(() => { + Sortable.get(document.getElementById("list1")).option("invertSwap", true); + }); + + await browser + .expect(dragStartPosition.innerText) + .eql(dragEl.innerText) + .expect(targetStartPosition.innerText) + .eql(target.innerText) + .dragToElement(dragEl, target, { + destinationOffsetY: Math.round(itemHeight / 2 - leeway), + }) + .expect(dragStartPosition.innerText) + .eql(dragEl.innerText) + .expect(targetStartPosition.innerText) + .eql(target.innerText) + .dragToElement(dragEl, target, { + destinationOffsetY: Math.round(itemHeight / 2 + leeway), + }) + .expect(dragEndPosition.innerText) + .eql(dragEl.innerText) + .expect(targetEndPosition.innerText) + .eql(target.innerText); +}); + +test("Inverted swap threshold", async (browser) => { + const dragStartPosition = list1.child(0); + const dragEl = await dragStartPosition(); + const dragEndPosition = list1.child(1); + const targetStartPosition = list1.child(1); + const target = await targetStartPosition(); + const targetEndPosition = list1.child(0); + + await browser.eval(() => { + Sortable.get(document.getElementById("list1")).option("invertSwap", true); + Sortable.get(document.getElementById("list1")).option( + "invertedSwapThreshold", + 0.5 + ); + }); + + await browser + .expect(dragStartPosition.innerText) + .eql(dragEl.innerText) + .expect(targetStartPosition.innerText) + .eql(target.innerText) + .dragToElement(dragEl, target, { + destinationOffsetY: Math.round( + itemHeight - (itemHeight / 2) * 0.5 - leeway + ), + }) + .expect(dragStartPosition.innerText) + .eql(dragEl.innerText) + .expect(targetStartPosition.innerText) + .eql(target.innerText) + .dragToElement(dragEl, target, { + destinationOffsetY: Math.round( + itemHeight - (itemHeight / 2) * 0.5 + leeway + ), + }) + .expect(dragEndPosition.innerText) + .eql(dragEl.innerText) + .expect(targetEndPosition.innerText) + .eql(target.innerText); +}); + +fixture`Grouping`.page`../e2e-fixtures/dual-list.html`; + +let list2 = Selector("#list2"); + +test("Move to list of the same group", async (browser) => { + const dragStartPosition = list1.child(0); + const dragEl = await dragStartPosition(); + const dragEndPosition = list2.child(0); + const targetStartPosition = list2.child(0); + const target = await targetStartPosition(); + const targetEndPosition = list2.child(1); + + await browser.eval(() => { + Sortable.get(document.getElementById("list2")).option("group", "shared"); + }); + + await browser + .expect(dragStartPosition.innerText) + .eql(dragEl.innerText) + .expect(targetStartPosition.innerText) + .eql(target.innerText) + .dragToElement(dragEl, target, { offsetY: 0, destinationOffsetY: 0 }) + .expect(dragEndPosition.innerText) + .eql(dragEl.innerText) + .expect(targetEndPosition.innerText) + .eql(target.innerText); +}); + +test("Do not move to list of different group", async (browser) => { + const dragStartPosition = list1.child(0); + const dragEl = await dragStartPosition(); + const targetStartPosition = list2.child(0); + const target = await targetStartPosition(); + + await browser.eval(() => { + Sortable.get(document.getElementById("list2")).option("group", null); + }); + + await browser + .expect(dragStartPosition.innerText) + .eql(dragEl.innerText) + .expect(targetStartPosition.innerText) + .eql(target.innerText) + .dragToElement(dragEl, target, { offsetY: 0, destinationOffsetY: 0 }) + .expect(dragStartPosition.innerText) + .eql(dragEl.innerText) + .expect(targetStartPosition.innerText) + .eql(target.innerText); +}); + +test("Move to list with put:true", async (browser) => { + // Should allow insert, since pull defaults to `true` + const dragStartPosition = list1.child(0); + const dragEl = await dragStartPosition(); + const dragEndPosition = list2.child(0); + const targetStartPosition = list2.child(0); + const target = await targetStartPosition(); + const targetEndPosition = list2.child(1); + + await browser.eval(() => { + Sortable.get(document.getElementById("list2")).option("group", { + put: true, + }); + }); + + await browser + .expect(dragStartPosition.innerText) + .eql(dragEl.innerText) + .expect(targetStartPosition.innerText) + .eql(target.innerText) + .dragToElement(dragEl, target, { offsetY: 0, destinationOffsetY: 0 }) + .expect(dragEndPosition.innerText) + .eql(dragEl.innerText) + .expect(targetEndPosition.innerText) + .eql(target.innerText); +}); + +test("Do not move from list with pull:false", async (browser) => { + // Should not allow insert, since put defaults to `false` + const dragStartPosition = list1.child(0); + const dragEl = await dragStartPosition(); + const targetStartPosition = list2.child(0); + const target = await targetStartPosition(); + + await browser.eval(() => { + Sortable.get(document.getElementById("list1")).option("group", { + pull: false, + }); + }); + + await browser + .expect(dragStartPosition.innerText) + .eql(dragEl.innerText) + .expect(targetStartPosition.innerText) + .eql(target.innerText) + .dragToElement(dragEl, target, { offsetY: 0, destinationOffsetY: 0 }) + .expect(dragStartPosition.innerText) + .eql(dragEl.innerText) + .expect(targetStartPosition.innerText) + .eql(target.innerText); +}); + +test('Clone element if pull:"clone"', async (browser) => { + const dragStartPosition = list1.child(0); + const dragEl = await dragStartPosition(); + const dragEndPosition = list2.child(0); + const targetStartPosition = list2.child(0); + const target = await targetStartPosition(); + const targetEndPosition = list2.child(1); + + await browser.eval(() => { + Sortable.get(document.getElementById("list1")).option("group", { + pull: "clone", + }); + Sortable.get(document.getElementById("list2")).option("group", { + put: true, + }); + }); + + await browser + .expect(dragStartPosition.innerText) + .eql(dragEl.innerText) + .expect(targetStartPosition.innerText) + .eql(target.innerText) + .dragToElement(dragEl, target, { offsetY: 0, destinationOffsetY: 0 }) + .expect(dragStartPosition.innerText) + .eql(dragEl.innerText) // clone check + .expect(dragEndPosition.innerText) + .eql(dragEl.innerText) + .expect(targetEndPosition.innerText) + .eql(target.innerText); +}); + +fixture`Handles`.page`../e2e-fixtures/handles.html`; + +test("Do not allow dragging not using handle", async (browser) => { + const dragStartPosition = list1.child(0); + const dragEl = await dragStartPosition(); + const targetStartPosition = list1.child(1); + const target = await targetStartPosition(); + + await browser + .expect(dragStartPosition.innerText) + .eql(dragEl.innerText) + .expect(targetStartPosition.innerText) + .eql(target.innerText) + .dragToElement(dragEl, target) + .expect(dragStartPosition.innerText) + .eql(dragEl.innerText) + .expect(targetStartPosition.innerText) + .eql(target.innerText); +}); + +test("Allow dragging using handle", async (browser) => { + const dragStartPosition = list1.child(0); + const dragEl = await dragStartPosition(); + const dragEndPosition = list1.child(1); + const targetStartPosition = list1.child(1); + const target = await targetStartPosition(); + const targetEndPosition = list1.child(0); + + await browser + .expect(dragStartPosition.innerText) + .eql(dragEl.innerText) + .expect(targetStartPosition.innerText) + .eql(target.innerText) + .dragToElement(await dragStartPosition.child(".handle"), target) + .expect(dragEndPosition.innerText) + .eql(dragEl.innerText) + .expect(targetEndPosition.innerText) + .eql(target.innerText); +}); + +fixture`Filter`.page`../e2e-fixtures/filter.html`; + +test("Do not allow dragging of filtered element", async (browser) => { + const dragStartPosition = list1.child(".filtered"); + const dragEl = await dragStartPosition(); + const targetStartPosition = dragStartPosition.nextSibling(1); + const target = await targetStartPosition(); + + await browser + .expect(dragStartPosition.innerText) + .eql(dragEl.innerText) + .expect(targetStartPosition.innerText) + .eql(target.innerText) + .dragToElement(dragEl, target) + .expect(dragStartPosition.innerText) + .eql(dragEl.innerText) + .expect(targetStartPosition.innerText) + .eql(target.innerText); +}); + +test("Allow dragging of non-filtered element", async (browser) => { + const dragStartPosition = list1.child(":not(.filtered)"); + const dragEl = await dragStartPosition(); + const dragEndPosition = dragStartPosition.nextSibling(1); + const targetStartPosition = dragStartPosition.nextSibling(1); + const target = await targetStartPosition(); + const targetEndPosition = dragStartPosition.nextSibling(0); + + await browser + .expect(dragStartPosition.innerText) + .eql(dragEl.innerText) + .expect(targetStartPosition.innerText) + .eql(target.innerText) + .dragToElement(dragEl, target) + .expect(dragEndPosition.innerText) + .eql(dragEl.innerText) + .expect(targetEndPosition.innerText) + .eql(target.innerText); +}); + +fixture`Nested`.page`../e2e-fixtures/nested.html`; + +let list1n1 = Selector(".n1"); +let list1n2 = Selector(".n2"); +let list2n1 = Selector(".n1:nth-of-type(2)"); + +test("Dragging from level 1 to level 0", async (browser) => { + const dragStartPosition = list1n1.child(0); + const dragEl = await dragStartPosition(); + const dragEndPosition = list1.child(2); + const targetStartPosition = list1.child(2); + const target = await targetStartPosition(); + const targetEndPosition = list1.child(3); + + await browser + .expect(dragStartPosition.innerText) + .eql(dragEl.innerText) + .expect(targetStartPosition.innerText) + .eql(target.innerText) + .dragToElement(dragEl, target, { destinationOffsetY: 0 }) + .expect(dragEndPosition.innerText) + .eql(dragEl.innerText) + .expect(targetEndPosition.innerText) + .eql(target.innerText); +}); + +test("Dragging from level 0 to level 2", async (browser) => { + const dragStartPosition = list1.child(1); + const dragEl = await dragStartPosition(); + const dragEndPosition = list1n2.child(2); + const targetStartPosition = list1n2.child(2); + const target = await targetStartPosition(); + const targetEndPosition = list1n2.child(3); + + await browser + .expect(dragStartPosition.innerText) + .eql(dragEl.innerText) + .expect(targetStartPosition.innerText) + .eql(target.innerText) + .dragToElement(dragEl, target, { destinationOffsetY: 0 }) + .expect(dragEndPosition.innerText) + .eql(dragEl.innerText) + .expect(targetEndPosition.innerText) + .eql(target.innerText); +}); + +fixture`Empty Insert`.page`../e2e-fixtures/empty-list.html`; + +test("Insert into empty list if within emptyInsertThreshold", async (browser) => { + const threshold = await browser.eval(() => + Sortable.get(document.getElementById("list2")).option( + "emptyInsertThreshold" + ) + ); + const dragStartPosition = list1.child(0); + const dragEl = await dragStartPosition(); + const dragEndPosition = list2.child(0); + // Must use rects since testcafe won't drag to element that is "not visible" + const dragRect = dragEl.boundingClientRect; + const list2Rect = await list2.boundingClientRect; + + await browser + .expect(dragStartPosition.innerText) + .eql(dragEl.innerText) + .drag( + dragEl, + Math.round(list2Rect.left - dragRect.left) - (threshold - 1), + -(threshold - 1), + { + offsetY: 0, + offsetX: 0, + } + ) + .expect(dragEndPosition.innerText) + .eql(dragEl.innerText); +}); + +test("Do not insert into empty list if outside emptyInsertThreshold", async (browser) => { + const threshold = await browser.eval(() => + Sortable.get(document.getElementById("list2")).option( + "emptyInsertThreshold" + ) + ); + const dragStartPosition = list1.child(0); + const dragEl = await dragStartPosition(); + const dragRect = dragEl.boundingClientRect; + const list2Rect = await list2.boundingClientRect; + + await browser + .expect(dragStartPosition.innerText) + .eql(dragEl.innerText) + .drag( + dragEl, + Math.round(list2Rect.left - dragRect.left) - (threshold + 1), + -(threshold + 1), + { + offsetY: 0, + offsetX: 0, + } + ) + .expect(dragStartPosition.innerText) + .eql(dragEl.innerText); +}); diff --git a/tests/e2e-saucelabs/Sortable.compat.test.js b/tests/e2e-saucelabs/Sortable.compat.test.js new file mode 100644 index 000000000..0db23e639 --- /dev/null +++ b/tests/e2e-saucelabs/Sortable.compat.test.js @@ -0,0 +1,45 @@ +import { Selector } from "testcafe"; + +fixture`Simple Sorting`.page`../e2e-fixtures/single-list.html`; + +let list1 = Selector("#list1"); + +test("Sort down list", async (browser) => { + const dragStartPosition = list1.child(0); + const dragEl = await dragStartPosition(); + const dragEndPosition = list1.child(2); + const targetStartPosition = list1.child(2); + const target = await targetStartPosition(); + const targetEndPosition = list1.child(1); + + await browser + .expect(dragStartPosition.innerText) + .eql(dragEl.innerText) + .expect(targetStartPosition.innerText) + .eql(target.innerText) + .dragToElement(dragEl, target) + .expect(dragEndPosition.innerText) + .eql(dragEl.innerText) + .expect(targetEndPosition.innerText) + .eql(target.innerText); +}); + +test("Sort up list", async (browser) => { + const dragStartPosition = list1.child(2); + const dragEl = await dragStartPosition(); + const dragEndPosition = list1.child(0); + const targetStartPosition = list1.child(0); + const target = await targetStartPosition(); + const targetEndPosition = list1.child(1); + + await browser + .expect(dragStartPosition.innerText) + .eql(dragEl.innerText) + .expect(targetStartPosition.innerText) + .eql(target.innerText) + .dragToElement(dragEl, target) + .expect(dragEndPosition.innerText) + .eql(dragEl.innerText) + .expect(targetEndPosition.innerText) + .eql(target.innerText); +}); diff --git a/tests/empty-list.html b/tests/empty-list.html deleted file mode 100644 index 3e2064154..000000000 --- a/tests/empty-list.html +++ /dev/null @@ -1,30 +0,0 @@ - - - - - - - - -
-
Item 1.1
-
Item 1.2
-
Item 1.3
-
Item 1.4
-
Item 1.5
-
- -
- -
- - - - - - - - diff --git a/tests/filter.html b/tests/filter.html deleted file mode 100644 index 49b40dd1d..000000000 --- a/tests/filter.html +++ /dev/null @@ -1,27 +0,0 @@ - - - - - - - - -
-
Item 1.1
-
Item 1.2
-
Item 1.3
-
Item 1.4
-
Item 1.5
-
- - - - - - - - - - diff --git a/tests/handles.html b/tests/handles.html deleted file mode 100644 index 037e272d0..000000000 --- a/tests/handles.html +++ /dev/null @@ -1,27 +0,0 @@ - - - - - - - - -
-
::Item 1.1
-
::Item 1.2
-
::Item 1.3
-
::Item 1.4
-
::Item 1.5
-
- - - - - - - - - - diff --git a/tests/nested.html b/tests/nested.html deleted file mode 100644 index f9dd15778..000000000 --- a/tests/nested.html +++ /dev/null @@ -1,67 +0,0 @@ - - - - - - - - -
-
Item 1.1 -
-
Item 2.1
-
Item 2.2 -
-
Item 3.1
-
Item 3.2
-
Item 3.3
-
Item 3.4
-
-
-
Item 2.3
-
Item 2.4
-
-
-
Item 1.2
-
Item 1.3
-
Item 1.4 -
-
Item 2.1
-
Item 2.2
-
Item 2.3
-
Item 2.4
-
-
-
Item 1.5
-
- - - - - - - - - diff --git a/tests/single-list.html b/tests/single-list.html deleted file mode 100644 index 30b984b0d..000000000 --- a/tests/single-list.html +++ /dev/null @@ -1,25 +0,0 @@ - - - - - - - - -
-
Item 1.1
-
Item 1.2
-
Item 1.3
-
Item 1.4
-
Item 1.5
-
- - - - - - - -