Skip to content

Commit

Permalink
feat(deps): update dependency electron to v15 🌟 (#18317)
Browse files Browse the repository at this point in the history
Co-authored-by: Renovate Bot <bot@renovateapp.com>
Co-authored-by: Zach Bloomquist <git@chary.us>
Co-authored-by: David Munechika <davidam1203@gmail.com>
  • Loading branch information
4 people authored Nov 9, 2021
1 parent 99c8d46 commit 3095d73
Show file tree
Hide file tree
Showing 28 changed files with 194 additions and 175 deletions.
2 changes: 1 addition & 1 deletion .node-version
Original file line number Diff line number Diff line change
@@ -1 +1 @@
14.17.0
16.5.0
2 changes: 1 addition & 1 deletion appveyor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ branches:
# https://www.appveyor.com/docs/lang/nodejs-iojs/
environment:
# use matching version of Node.js
nodejs_version: "14.17.0"
nodejs_version: "16.5.0"
# encode secure variables which will NOT be used
# in pull requests
# https://www.appveyor.com/docs/build-configuration/#secure-variables
Expand Down
42 changes: 27 additions & 15 deletions circle.yml
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ executors:
# the Docker image with Cypress dependencies and Chrome browser
cy-doc:
docker:
- image: cypress/browsers:node14.17.0-chrome91-ff89
- image: cypress/browsers:node16.5.0-chrome94-ff93
# by default, we use "small" to save on CI costs. bump on a per-job basis if needed.
resource_class: small
environment:
Expand All @@ -59,7 +59,7 @@ executors:
# Docker image with non-root "node" user
non-root-docker-user:
docker:
- image: cypress/browsers:node14.17.0-chrome91-ff89
- image: cypress/browsers:node16.5.0-chrome94-ff93
user: node
environment:
PLATFORM: linux
Expand All @@ -70,7 +70,7 @@ executors:
mac:
macos:
# Executor should have Node >= required version
xcode: "12.2.0"
xcode: "13.0.0"
environment:
PLATFORM: mac

Expand Down Expand Up @@ -266,25 +266,30 @@ commands:

install-required-node:
# https://discuss.circleci.com/t/switch-nodejs-version-on-machine-executor-solved/26675/2
description: Install Node version matching .node-version
description: Install Node version
parameters:
version:
type: string
default: ""
steps:
- run:
name: Install NVM
# TODO: determine why we get the missing .nvmrc file error
command: |
export NODE_VERSION=$(cat .node-version)
export NODE_VERSION=<<parameters.version>>
export NODE_VERSION=${NODE_VERSION:-$(cat .node-version)}
echo "Installing Node $NODE_VERSION"
cp .node-version .nvmrc
echo $NODE_VERSION > .nvmrc
curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.35.3/install.sh | bash
- run:
# https://github.com/nvm-sh/nvm#nvmrc
name: Install Node
command: |
. ./scripts/load-nvm.sh
echo "before nvm install"
nvm install
nvm install <<parameters.version>>
echo "before nvm use"
nvm use
nvm use <<parameters.version>>
echo "before nvm alias default"
nvm alias default
node --version
Expand Down Expand Up @@ -1467,20 +1472,27 @@ jobs:
<<: *defaults
steps:
- restore_cached_workspace
- install-required-node:
version: "16.10"
- run:
name: Build
command: yarn workspace @cypress/schematic build:all
- run:
name: Install @angular/cli
command: yarn policies set-version 1.19.0 && yarn add --dev @angular/cli
name: Build + Install
command: |
. ../../scripts/load-nvm.sh
yarn workspace @cypress/schematic build:all
yarn policies set-version 1.19.0
yarn add --dev @angular/cli
working_directory: npm/cypress-schematic
- run:
name: Launch
command: yarn launch:test
command: |
. ../../scripts/load-nvm.sh
yarn launch:test
working_directory: npm/cypress-schematic
- run:
name: Run unit tests
command: yarn test
command: |
. ../../scripts/load-nvm.sh
yarn test
working_directory: npm/cypress-schematic
- store-npm-logs

Expand Down
4 changes: 2 additions & 2 deletions cli/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
"unit": "cross-env BLUEBIRD_DEBUG=1 NODE_ENV=test mocha --reporter mocha-multi-reporters --reporter-options configFile=../mocha-reporter-config.json"
},
"dependencies": {
"@cypress/request": "^2.88.6",
"@cypress/request": "^2.88.7",
"@cypress/xvfb": "^1.2.4",
"@types/node": "^14.14.31",
"@types/sinonjs__fake-timers": "^6.0.2",
Expand Down Expand Up @@ -85,7 +85,7 @@
"execa-wrap": "1.4.0",
"hasha": "5.2.2",
"mocha": "6.2.2",
"mock-fs": "4.13.0",
"mock-fs": "5.1.1",
"mocked-env": "1.3.2",
"nock": "13.0.7",
"postinstall-postinstall": "2.1.0",
Expand Down
2 changes: 1 addition & 1 deletion npm/create-cypress-tests/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@
"@types/ora": "^3.2.0",
"copy": "0.3.2",
"mocha": "7.1.1",
"mock-fs": "4.13.0",
"mock-fs": "5.1.1",
"shx": "0.3.3",
"snap-shot-it": "7.9.3",
"typescript": "^4.2.3"
Expand Down
10 changes: 5 additions & 5 deletions npm/cypress-schematic/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,15 +18,15 @@
"unlink:sandbox": "cd sandbox && yarn unlink @cypress/schematic && cd .. && yarn unlink"
},
"dependencies": {
"@angular-devkit/architect": "^0.1200.0",
"@angular-devkit/core": "^12.0.0",
"@angular-devkit/schematics": "^12.0.0",
"@schematics/angular": "^12.0.0",
"@angular-devkit/architect": "^0.1202.10",
"@angular-devkit/core": "^12.2.10",
"@angular-devkit/schematics": "^12.2.10",
"@schematics/angular": "^12.2.10",
"jsonc-parser": "^3.0.0",
"rxjs": "~6.6.0"
},
"devDependencies": {
"@angular-devkit/schematics-cli": "^12.0.0",
"@angular-devkit/schematics-cli": "^12.2.10",
"@types/chai-enzyme": "0.6.7",
"@types/mocha": "8.0.3",
"@types/node": "^12.11.1",
Expand Down
1 change: 1 addition & 0 deletions npm/webpack-preprocessor/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@
"@babel/plugin-proposal-nullish-coalescing-operator": "7.8.3",
"@babel/preset-env": "^7.0.0",
"@fellow/eslint-plugin-coffee": "0.4.13",
"@types/mocha": "9.0.0",
"@types/webpack": "^4.41.12",
"@typescript-eslint/eslint-plugin": "^4.18.0",
"@typescript-eslint/parser": "^4.18.0",
Expand Down
2 changes: 1 addition & 1 deletion npm/webpack-preprocessor/test/unit/index.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -353,7 +353,7 @@ describe('webpack preprocessor', function () {
return true
},
toJson () {
return { errors: errs }
return { warnings: [], errors: errs }
},
}

Expand Down
6 changes: 3 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@
"@cypress/env-or-json-file": "2.0.0",
"@cypress/github-commit-status-check": "1.5.0",
"@cypress/questions-remain": "1.0.1",
"@cypress/request": "2.88.6",
"@cypress/request": "2.88.7",
"@cypress/request-promise": "4.2.6",
"@fellow/eslint-plugin-coffee": "0.4.13",
"@percy/cli": "1.0.0-beta.48",
Expand Down Expand Up @@ -161,7 +161,7 @@
"mocha-banner": "1.1.2",
"mocha-junit-reporter": "2.0.0",
"mocha-multi-reporters": "1.1.7",
"mock-fs": "4.9.0",
"mock-fs": "5.1.1",
"odiff-bin": "2.1.0",
"parse-github-repo-url": "1.4.1",
"patch-package": "6.4.7",
Expand Down Expand Up @@ -190,7 +190,7 @@
"yarn-deduplicate": "3.1.0"
},
"engines": {
"node": ">=14.17.0",
"node": ">=16.5.0",
"yarn": ">=1.17.3"
},
"productName": "Cypress",
Expand Down
2 changes: 1 addition & 1 deletion packages/electron/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
"minimist": "1.2.5"
},
"devDependencies": {
"electron": "14.1.0",
"electron": "15.2.0",
"execa": "4.1.0",
"mocha": "3.5.3"
},
Expand Down
2 changes: 1 addition & 1 deletion packages/https-proxy/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
},
"devDependencies": {
"@cypress/debugging-proxy": "2.0.1",
"@cypress/request": "2.88.6",
"@cypress/request": "2.88.7",
"@cypress/request-promise": "4.2.6",
"@packages/network": "0.0.0-development",
"@packages/ts": "0.0.0-development",
Expand Down
9 changes: 2 additions & 7 deletions packages/https-proxy/test/integration/proxy_spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -99,9 +99,7 @@ describe('Proxy', () => {
proxy: 'http://localhost:3333',
resolveWithFullResponse: true,
})
.then((res) => {
// ensure client has disconnected
expect(res.socket.destroyed).to.be.true
.then(() => {
// ensure the outgoing socket created for this connection was destroyed
expect(net.connect).calledOnce

Expand Down Expand Up @@ -311,10 +309,7 @@ describe('Proxy', () => {
resolveWithFullResponse: true,
forever: false,
})
.then((res) => {
// ensure client has disconnected
expect(res.socket.destroyed).to.be.true

.then(() => {
// ensure the outgoing socket created for this connection was destroyed
expect(net.connect).calledOnce
const socket = net.connect.getCalls()[0].returnValue
Expand Down
2 changes: 1 addition & 1 deletion packages/launcher/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@
"name": "@packages/launcher",
"version": "0.0.0-development",
"private": true,
"main": "index.js",
"scripts": {
"build-prod": "tsc --project .",
"clean": "node scripts/clean.js || true",
Expand Down Expand Up @@ -33,6 +32,7 @@
"typescript": "^4.2.3"
},
"files": [
"index.js",
"lib"
],
"types": "index.ts"
Expand Down
3 changes: 2 additions & 1 deletion packages/launcher/tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
{
"extends": "./../ts/tsconfig.json",
"include": [
"**/*.ts"
"**/*.ts",
"./index.ts"
],
"files": [
"./../ts/index.d.ts"
Expand Down
2 changes: 1 addition & 1 deletion packages/network/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
},
"devDependencies": {
"@cypress/debugging-proxy": "2.0.1",
"@cypress/request": "2.88.6",
"@cypress/request": "2.88.7",
"@cypress/request-promise": "4.2.6",
"@packages/https-proxy": "0.0.0-development",
"@packages/socket": "0.0.0-development",
Expand Down
2 changes: 1 addition & 1 deletion packages/proxy/lib/http/request-middleware.ts
Original file line number Diff line number Diff line change
Expand Up @@ -170,7 +170,7 @@ const SendRequestOutgoing: RequestMiddleware = function () {

req.on('error', this.onError)
req.on('response', (incomingRes) => this.onResponse(incomingRes, req))
this.req.on('aborted', () => {
this.req.socket.on('close', () => {
this.debug('request aborted')
req.abort()
})
Expand Down
2 changes: 1 addition & 1 deletion packages/proxy/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
"utf8-stream": "0.0.0"
},
"devDependencies": {
"@cypress/request": "2.88.6",
"@cypress/request": "2.88.7",
"@cypress/request-promise": "4.2.6",
"@cypress/sinon-chai": "2.9.1",
"@packages/resolve-dist": "0.0.0-development",
Expand Down
6 changes: 3 additions & 3 deletions packages/server/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
"@cypress/get-windows-proxy": "1.6.2",
"@cypress/icons": "0.7.0",
"@cypress/mocha-teamcity-reporter": "1.0.0",
"@cypress/request": "2.88.6",
"@cypress/request": "2.88.7",
"@cypress/request-promise": "4.2.6",
"@cypress/webpack-batteries-included-preprocessor": "0.0.0-development",
"@cypress/webpack-preprocessor": "0.0.0-development",
Expand All @@ -52,7 +52,7 @@
"debug": "4.3.2",
"dependency-tree": "8.1.0",
"duplexify": "4.1.1",
"electron-context-menu": "2.2.0",
"electron-context-menu": "3.1.1",
"errorhandler": "1.5.1",
"evil-dns": "0.2.0",
"execa": "1.0.0",
Expand Down Expand Up @@ -169,7 +169,7 @@
"mochawesome-1.5.2": "npm:mochawesome@1.5.2",
"mochawesome-2.3.1": "npm:mochawesome@2.3.1",
"mochawesome-3.0.1": "npm:mochawesome@3.0.1",
"mock-fs": "4.12.0",
"mock-fs": "5.1.1",
"mocked-env": "1.2.4",
"mockery": "2.1.0",
"multer": "1.4.2",
Expand Down
35 changes: 19 additions & 16 deletions packages/server/test/integration/http_requests_spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,23 @@ const cleanResponseBody = (body) => {
return replaceAbsolutePaths(removeWhitespace(body))
}

function getHugeJsFile () {
const pathToHugeAppJs = Fixtures.path('server/libs/huge_app.js')

const getHugeFile = () => {
return rp('https://s3.amazonaws.com/internal-test-runner-assets.cypress.io/huge_app.js')
.then((resp) => {
return fs
.outputFileAsync(pathToHugeAppJs, resp)
.return(resp)
})
}

return fs
.readFileAsync(pathToHugeAppJs, 'utf8')
.catch(getHugeFile)
}

describe('Routes', () => {
require('mocha-banner').register()

Expand Down Expand Up @@ -3316,20 +3333,7 @@ describe('Routes', () => {
})

it('does not die rewriting a huge JS file', function () {
const pathToHugeAppJs = Fixtures.path('server/libs/huge_app.js')

const getHugeFile = () => {
return rp('https://s3.amazonaws.com/internal-test-runner-assets.cypress.io/huge_app.js')
.then((resp) => {
return fs
.outputFileAsync(pathToHugeAppJs, resp)
.return(resp)
})
}

return fs
.readFileAsync(pathToHugeAppJs, 'utf8')
.catch(getHugeFile)
return getHugeJsFile()
.then((hugeJsFile) => {
nock(this.server._remoteOrigin)
.get('/app.js')
Expand Down Expand Up @@ -3823,8 +3827,7 @@ describe('Routes', () => {
})

it('aborts the proxied request', function (done) {
fs
.readFileAsync(Fixtures.path('server/libs/huge_app.js'), 'utf8')
getHugeJsFile()
.then((str) => {
const server = http.createServer((req, res) => {
// when the incoming message to our
Expand Down
2 changes: 1 addition & 1 deletion packages/server/test/unit/browsers/firefox_spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -119,8 +119,8 @@ describe('lib/browsers/firefox', () => {

sinon.stub(plugins, 'has')
sinon.stub(plugins, 'execute')
sinon.stub(utils, 'writeExtension').resolves('/path/to/ext')
sinon.stub(launch, 'launch').resolves(this.browserInstance)
sinon.stub(utils, 'writeExtension').resolves('/path/to/ext')
sinon.spy(FirefoxProfile.prototype, 'setPreference')
sinon.spy(FirefoxProfile.prototype, 'updatePreferences')

Expand Down
2 changes: 1 addition & 1 deletion packages/server/test/unit/util/suppress_warnings_spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import proxyquire from 'proxyquire'

const ERROR_MESSAGE = 'Setting the NODE_TLS_REJECT_UNAUTHORIZED'

const TLS_CONNECT = `require('tls').connect().on('error', ()=>{});`
const TLS_CONNECT = `require('tls').connect('5000').on('error', ()=>{});`
const SUPPRESS_WARNING = `require('${__dirname}/../../../lib/util/suppress_warnings').suppress();`

describe('lib/util/suppress_warnings', function () {
Expand Down
Loading

2 comments on commit 3095d73

@cypress-bot
Copy link
Contributor

@cypress-bot cypress-bot bot commented on 3095d73 Nov 9, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Circle has built the linux x64 version of the Test Runner.

Learn more about this pre-release platform-specific build at https://on.cypress.io/installing-cypress#Install-pre-release-version.

Run this command to install the pre-release locally:

npm install https://cdn.cypress.io/beta/npm/8.8.0/circle-9.0-release-3095d733e92527ffd67344c6899211e058ceefa3/cypress.tgz

@JK-858
Copy link

@JK-858 JK-858 commented on 3095d73 Feb 18, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for sharing the code. I would like to look forward for more such content and implement the idea in my own experiment EduHelpHub.

Please sign in to comment.