Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: increase test reliability #2803

Closed
Closed
2 changes: 1 addition & 1 deletion packages/@vue/babel-preset-app/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
"@babel/plugin-syntax-jsx": "^7.0.0",
"@babel/plugin-transform-runtime": "^7.0.0",
"@babel/preset-env": "^7.0.0",
"@babel/runtime": "^7.0.0",
"@babel/runtime": "7.0.0-beta.55",
"babel-helper-vue-jsx-merge-props": "^2.0.3",
"babel-plugin-dynamic-import-node": "^2.2.0",
"babel-plugin-transform-vue-jsx": "^4.0.1"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
jest.setTimeout(process.env.APPVEYOR ? 120000 : 60000)
jest.setTimeout(120000)

const create = require('@vue/cli-test-utils/createTestProject')

Expand All @@ -21,9 +21,9 @@ test('should work', async () => {
config.video = false
await project.write('cypress.json', JSON.stringify(config))

if (!process.env.CI) {
await project.run(`vue-cli-service test:e2e`)
} else if (!process.env.APPVEYOR) {
if (!process.env.APPVEYOR) {
await project.run(`vue-cli-service test:e2e --headless`)
} else if (!process.env.CI) {
await project.run(`vue-cli-service test:e2e`)
}
})
Original file line number Diff line number Diff line change
Expand Up @@ -77,9 +77,7 @@ test('should work', async () => {
expect(isFirstMsg).toBe(true)
isFirstMsg = false
// fix it
setTimeout(() => {
write('src/App.vue', app)
}, process.env.CI ? 2000 : 200)
write('src/App.vue', app)
} else if (data.match(/Compiled successfully/)) {
// should compile on 2nd update
expect(isFirstMsg).toBe(false)
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
jest.setTimeout(20000)
jest.setTimeout(process.env.APPVEYOR ? 40000 : 20000)

const create = require('@vue/cli-test-utils/createTestProject')

Expand Down
86 changes: 81 additions & 5 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -1024,7 +1024,15 @@
core-js "^2.5.3"
regenerator-runtime "^0.11.1"

"@babel/runtime@^7.0.0", "@babel/runtime@^7.0.0-beta.38", "@babel/runtime@^7.0.0-beta.51":
"@babel/[email protected]":
version "7.0.0-beta.55"
resolved "https://registry.yarnpkg.com/@babel/runtime/-/runtime-7.0.0-beta.55.tgz#0bc33aa5a6ac0b012f37e25b9e6aaa2e489a916b"
integrity sha1-C8M6paasCwEvN+JbnmqqLkiakWs=
dependencies:
core-js "^2.5.7"
regenerator-runtime "^0.12.0"

"@babel/runtime@^7.0.0-beta.38", "@babel/runtime@^7.0.0-beta.51":
version "7.0.0"
resolved "https://registry.yarnpkg.com/@babel/runtime/-/runtime-7.0.0.tgz#adeb78fedfc855aa05bc041640f3f6f98e85424c"
integrity sha512-7hGhzlcmg01CvH1EHdSPVXYX1aJ8KCEyz6I9xYIi/asDtzBPMyMhVibhM/K6g/5qnKBwjZtp10bNZIEFTRW1MA==
Expand Down Expand Up @@ -3231,6 +3239,26 @@ cacache@^10.0.4:
unique-filename "^1.1.0"
y18n "^4.0.0"

cacache@^11.0.2:
version "11.2.0"
resolved "https://registry.yarnpkg.com/cacache/-/cacache-11.2.0.tgz#617bdc0b02844af56310e411c0878941d5739965"
integrity sha512-IFWl6lfK6wSeYCHUXh+N1lY72UDrpyrYQJNIVQf48paDuWbv5RbAtJYf/4gUQFObTCHZwdZ5sI8Iw7nqwP6nlQ==
dependencies:
bluebird "^3.5.1"
chownr "^1.0.1"
figgy-pudding "^3.1.0"
glob "^7.1.2"
graceful-fs "^4.1.11"
lru-cache "^4.1.3"
mississippi "^3.0.0"
mkdirp "^0.5.1"
move-concurrently "^1.0.1"
promise-inflight "^1.0.1"
rimraf "^2.6.2"
ssri "^6.0.0"
unique-filename "^1.1.0"
y18n "^4.0.0"

cache-base@^1.0.1:
version "1.0.1"
resolved "https://registry.yarnpkg.com/cache-base/-/cache-base-1.0.1.tgz#0a7f46416831c8b662ee36fe4e7c59d76f666ab2"
Expand Down Expand Up @@ -6294,7 +6322,7 @@ fd-slicer@~1.1.0:
dependencies:
pend "~1.2.0"

figgy-pudding@^3.5.1:
figgy-pudding@^3.1.0, figgy-pudding@^3.5.1:
version "3.5.1"
resolved "https://registry.yarnpkg.com/figgy-pudding/-/figgy-pudding-3.5.1.tgz#862470112901c727a0e495a80744bd5baa1d6790"
integrity sha512-vNKxJHTEKNThjfrdJwHc7brvM6eVevuO5nTj6ez8ZQ1qbXTvGthucRF7S4vf2cr71QVnT70V34v0S1DyQsti0w==
Expand Down Expand Up @@ -6450,6 +6478,15 @@ find-cache-dir@^1.0.0:
make-dir "^1.0.0"
pkg-dir "^2.0.0"

find-cache-dir@^2.0.0:
version "2.0.0"
resolved "https://registry.yarnpkg.com/find-cache-dir/-/find-cache-dir-2.0.0.tgz#4c1faed59f45184530fb9d7fa123a4d04a98472d"
integrity sha512-LDUY6V1Xs5eFskUVYtIwatojt6+9xC9Chnlk/jYOOvn3FAFfSaWddxahDGyNHh0b2dMXa6YW2m0tk8TdVaXHlA==
dependencies:
commondir "^1.0.1"
make-dir "^1.0.0"
pkg-dir "^3.0.0"

find-parent-dir@^0.3.0:
version "0.3.0"
resolved "https://registry.yarnpkg.com/find-parent-dir/-/find-parent-dir-0.3.0.tgz#33c44b429ab2b2f0646299c5f9f718f376ff8d54"
Expand Down Expand Up @@ -10380,6 +10417,22 @@ mississippi@^2.0.0:
stream-each "^1.1.0"
through2 "^2.0.0"

mississippi@^3.0.0:
version "3.0.0"
resolved "https://registry.yarnpkg.com/mississippi/-/mississippi-3.0.0.tgz#ea0a3291f97e0b5e8776b363d5f0a12d94c67022"
integrity sha512-x471SsVjUtBRtcvd4BzKE9kFC+/2TeWgKCgw0bZcw1b9l2X3QX5vCWgF+KaZaYm87Ss//rHnWryupDrgLvmSkA==
dependencies:
concat-stream "^1.5.0"
duplexify "^3.4.2"
end-of-stream "^1.1.0"
flush-write-stream "^1.0.0"
from2 "^2.1.0"
parallel-transform "^1.1.0"
pump "^3.0.0"
pumpify "^1.3.3"
stream-each "^1.1.0"
through2 "^2.0.0"

mixin-deep@^1.2.0:
version "1.3.1"
resolved "https://registry.yarnpkg.com/mixin-deep/-/mixin-deep-1.3.1.tgz#a49e7268dce1a0d9698e45326c5626df3543d0fe"
Expand Down Expand Up @@ -13559,7 +13612,7 @@ source-map-resolve@^0.5.0, source-map-resolve@^0.5.2:
source-map-url "^0.4.0"
urix "^0.1.0"

source-map-support@^0.5.0, source-map-support@^0.5.6:
source-map-support@^0.5.0, source-map-support@^0.5.6, source-map-support@~0.5.6:
version "0.5.9"
resolved "https://registry.yarnpkg.com/source-map-support/-/source-map-support-0.5.9.tgz#41bc953b2534267ea2d605bccfa7bfa3111ced5f"
integrity sha512-gR6Rw4MvUlYy83vP0vxoVNzM6t8MUXqNuRsuBmBHQDu1Fh6X015FrLdgoDKcNdkwGubozq0P4N0Q37UyFVr1EA==
Expand Down Expand Up @@ -13694,7 +13747,7 @@ ssri@^5.2.4:
dependencies:
safe-buffer "^5.1.1"

ssri@^6.0.1:
ssri@^6.0.0, ssri@^6.0.1:
version "6.0.1"
resolved "https://registry.yarnpkg.com/ssri/-/ssri-6.0.1.tgz#2a3c41b28dd45b62b63676ecb74001265ae9edd8"
integrity sha512-3Wge10hNcT1Kur4PDFwEieXSCMCJs/7WvSACcrMYrNp+b8kDL1/0wJch5Ni2WrtwEa2IO8OsVfeKIciKCDx/QA==
Expand Down Expand Up @@ -14219,6 +14272,29 @@ terminate@^2.1.0:
dependencies:
ps-tree "^1.1.0"

terser-webpack-plugin@^1.1.0:
version "1.1.0"
resolved "https://registry.yarnpkg.com/terser-webpack-plugin/-/terser-webpack-plugin-1.1.0.tgz#cf7c25a1eee25bf121f4a587bb9e004e3f80e528"
integrity sha512-61lV0DSxMAZ8AyZG7/A4a3UPlrbOBo8NIQ4tJzLPAdGOQ+yoNC7l5ijEow27lBAL2humer01KLS6bGIMYQxKoA==
dependencies:
cacache "^11.0.2"
find-cache-dir "^2.0.0"
schema-utils "^1.0.0"
serialize-javascript "^1.4.0"
source-map "^0.6.1"
terser "^3.8.1"
webpack-sources "^1.1.0"
worker-farm "^1.5.2"

terser@^3.8.1:
version "3.10.2"
resolved "https://registry.yarnpkg.com/terser/-/terser-3.10.2.tgz#a61d2c97065f9fdc8c49a18655e2a80ca7298a94"
integrity sha512-+QrFoqBImmsQGB4c/HvaqgZynmbNvNBwoBxuu7fYXtq5EEtlLUzph+WimDj+xMkuqawXPMl2lgCIz81CdXvt+w==
dependencies:
commander "~2.17.1"
source-map "~0.6.1"
source-map-support "~0.5.6"

test-exclude@^4.2.1:
version "4.2.3"
resolved "https://registry.yarnpkg.com/test-exclude/-/test-exclude-4.2.3.tgz#a9a5e64474e4398339245a0a769ad7c2f4a97c20"
Expand Down Expand Up @@ -14674,7 +14750,7 @@ [email protected], uglify-js@^3.1.4:
commander "~2.17.1"
source-map "~0.6.1"

uglifyjs-webpack-plugin@^1.2.4, uglifyjs-webpack-plugin@^1.2.7:
uglifyjs-webpack-plugin@^1.2.4:
version "1.3.0"
resolved "https://registry.yarnpkg.com/uglifyjs-webpack-plugin/-/uglifyjs-webpack-plugin-1.3.0.tgz#75f548160858163a08643e086d5fefe18a5d67de"
integrity sha512-ovHIch0AMlxjD/97j9AYovZxG5wnHOPkL7T1GKochBADp/Zwc44pEWNqpKl1Loupp1WhFg7SlYmHZRUfdAacgw==
Expand Down