Commit Graph

283 Commits

Author SHA1 Message Date
Zach Bloomquist 2cd99c890c Set minimum TLS version to TLSv1 (#6130)
Set minimum TLS version to TLSv1
2020-01-16 12:15:37 -05:00
renovate[bot] e0e249c9e2 fix(deps): update dependency http-status-codes to version 1.4.0… (#6134)
Co-authored-by: WhiteSource Renovate <renovatebot@gmail.com>
2020-01-15 16:03:43 +06:30
Zach Bloomquist 79bdca0c53 add test for #5446 2020-01-09 11:00:05 -05:00
renovate[bot] 2d9b8e597f fix(deps): update dependency ansi_up to version 4.0.4 🌟 (#6074)
Co-authored-by: Renovate Bot <bot@renovateapp.com>
2020-01-02 10:40:41 +06:30
renovate[bot] ae8277ceb6 fix(deps): update dependency jimp to version 0.9.3 🌟 (#6020)
Co-authored-by: Renovate Bot <bot@renovateapp.com>
2019-12-23 09:14:30 +06:30
renovate[bot] c3ad1a372a fix(deps): update dependency ansi_up to version .x 🌟 (#4331)
* fix(deps): update ansi_up to 4.0.3 🌟

* Update ansi_up to use new non-deprecated 2.0+ api

* Do not pass 'use_classes: true' (defaults to false) - we are expecting rgb values in our tests

* set back to use_classes

* Fix 'use_classes' option which was being incorrectly passed

Co-authored-by: Renovate Bot <renovatebot@gmail.com>
Co-authored-by: Jennifer Shehane <shehane.jennifer@gmail.com>
2019-12-20 18:31:15 +06:30
renovate[bot] 14206e3fc3 fix(deps): Update dependency which to version .x 🌟 (#6017)
Co-authored-by: Renovate Bot <bot@renovateapp.com>
2019-12-20 16:42:43 +06:30
renovate[bot] 56f68924f5 fix(deps): Update dependency chrome-remote-interface to version… (#6008)
Co-authored-by: Renovate Bot <bot@renovateapp.com>
2019-12-20 16:39:18 +06:30
renovate[bot] d83788dd43 chore(deps): update snap-shot-it to 7.9.1 🌟 (#6007) 2019-12-19 23:01:53 +06:30
renovate[bot] 548958af9d fix(deps): update dependency get-port to version 5.1.0 🌟 (#6004)
Co-authored-by: Renovate Bot <bot@renovateapp.com>
2019-12-19 22:03:59 +06:30
renovate[bot] 95d5d0efef fix(deps): update dependency send to version 0.17.1 🌟 (#5130)
Co-authored-by: Renovate Bot <bot@renovateapp.com>
2019-12-19 14:34:51 +06:30
renovate[bot] 6d264d26b4 chore(deps): update dependency devtools-protocol to version 0.0… (#5994)
Co-authored-by: Renovate Bot <bot@renovateapp.com>
2019-12-18 16:24:54 +06:30
Zach Bloomquist 93b5c0eec2 Fix CDP cookie matching algorithm (#5862)
* use correct tough.match param order

* add chrome extension types

* fix CDP cookie matching algorithm

* improve domain suffix match

* add tests for cookie matching utils
2019-12-06 15:12:36 -05:00
Zach Bloomquist 13aa496476 use cross-env in npm scripts so they work on Windows (#5888)
* use cross-env in npm scripts so they work on Windows

* update more cross-envs

* Apply suggestions from code review

Co-Authored-By: Gleb Bahmutov <gleb.bahmutov@gmail.com>
2019-12-05 11:38:03 -05:00
renovate[bot] 1cbf22a0bb fix(deps): Update dependency electron-context-menu to version 0… (#5495)
Co-authored-by: Renovate Bot <bot@renovateapp.com>
2019-12-02 13:27:50 +06:30
Zach Bloomquist b0378dc04e Refactor proxy into own package, implement middleware pattern (#5136)
* renames

* Refactor proxy into own package, implement middleware pattern

don't need these mocha opts anymore

fix test

no more zunder

READMEs

fix test

* pass request by reference

* fix cors path

* Move replace_stream to proxy, concat-stream util in network

* Pin dependency versions

* Revert addDefaultPort behavior

* Add READMEs for proxy, network

* Update README.md

* eslint --fix

* set to null not undefined

* use delete and bump node types

* import cors from package now

* parse-domain@2.3.4

* proxy package needs common-tags

* move pumpify dep

* load through where it's needed, remove unused passthru_stream

* remove unneeded getbuffer call


Co-authored-by: Gleb Bahmutov <gleb.bahmutov@gmail.com>
2019-11-27 19:16:15 -05:00
Kukhyeon Heo e19bcc038a CI should fail when something went wrong. (#5779)
* Added unit test script wrapper.

* Removed bin-up to make lint-coffee fail.

* Made mocha tests return non-zero value on failure for reporter and runner

* Added empty space to test ci failure.

* remove extra whitespace

* use Promise.delay instead of hand-rolled sleep function

* include root-level tests

* exit with number of failures
2019-11-27 12:41:45 -05:00
renovate[bot] 6bb3a483f9 fix(deps): update dependency parse-domain to version 2.3.4 🌟 (#5726)
* fix(deps): update parse-domain to 2.3.4 🌟

* update details now that s3.amazonaws.com is a public suffix

* bump max size


Co-authored-by: Renovate Bot <bot@renovateapp.com>
Co-authored-by: Zach Bloomquist <github@chary.us>
2019-11-19 13:06:11 -05:00
renovate[bot] bf6c187a0d chore(deps): Update dependency @cypress/json-schemas to version… (#5713)
Co-authored-by: Renovate Bot <bot@renovateapp.com>
2019-11-15 14:04:33 -05:00
Zach Bloomquist 98063aec64 Fix cy.clearCookie, fix HTTP redirect behavior, fix cy.visit HT… (#5478)
* Add a bunch of extra tests in 2_cookies_spec

* Try not doing weird things to cookies

* if cypress.env.debug is set, log command execution thru server

* improve elctron logging - we missed this when doing cri-client logging

* make video_capture frames part of verbose

* cleanup

* use the data from getCookie to run deleteCookies

* fix screenshots

* still resolve with cleared cookie

* cy.getcookie now gets ALL cookies from ALL domains

* return Promise for followRedirect, not req.init wrap

* allow passing domain: null to cy.getCookies to get all

* update request_spec to be clearer

* still need to call followRedirect option during sendStream

* beautify the e2e tests

* correct e2e test + snapshot

* always discard default ports when get/set buffer - fixes #5367

* make cy.clearCookies({ domain: null }) clear ALL cookies

* update spec

* use string url as key

* rebalance some e2e tests to make time for new cookies e2e tests

* always add default port to buffer url

* jk, remove default port

* set hostOnly: true when appropriate when setting cookies back on visit

* update tests

* Revert "if cypress.env.debug is set, log command execution thru server"

This reverts commit 623ed443d4.

* try to clean diff, cookies_no_baseurl didnt change

* WIP move the expected cookies array out of snapshot and expect inline

* finish updating tests

* add missing snapshot

* remove useless onstdout


Co-authored-by: Brian Mann <brian.mann86@gmail.com>
2019-11-07 19:12:27 -05:00
Gleb Bahmutov b3e40b08cd allow list of search patterns in testFiles config option (#5402)
* WIP: log spec search steps

* add multiple files via glob test

* allow testFiles to be a string or a list of strings to match

* failing config tests: testFiles type change

Change `testFiles` from a string to either a string **or** array of strings; following similar pattern as `ignoreTestFiles`

* testFiles type change passing tests

* update verbiage related to testFiles type change

* enable running integration tests locally

See https://github.com/paulmillr/chokidar/issues/855 for more details.

* integration tests; failing

Seems to fail for similar reason as #4543 and is likely resolved with PR #4849

* correct test verbiage

Distinguish between the two tests; as they are subtly different.

* update TS types for testFiles type change

Updated the comments, but forgot to update the actual type. This commit rectifies that.

* correct CLI syntax in test

`--config` was not being passed the appropriate value. Now matches other test cases; such as that found in [args_spec](https://github.com/cypress-io/cypress/blob/92b91fe514e5ff6286b4d4e26d2df23062bdf869/packages/server/test/unit/args_spec.coffee#L210)

* remove unsupported syntax from tests

From looking at other tests, it does not appear that the syntax `--config=testFiles=glob1,glob2` is current supported. Removing the test for this test case.

* test the correct config value

Previously was testing `ignoreTestFiles` instead of `testFies`

* provide more accurate test assertion

* correct config's `testFiles` type

Should be a string or an array of strings.

* remove unnecessary newline

* tweak verbiage to better align with intention

Co-Authored-By: Ben Kucera <14625260+Bkucera@users.noreply.github.com>


Co-authored-by: Andrew Smith <andrew@andrew.codes>
2019-10-31 11:26:47 -04:00
renovate[bot] 93093fb3cf fix(deps): update dependency graceful-fs to version 4.2.3 🌟 (#5497)
Co-authored-by: Renovate Bot <bot@renovateapp.com>
Co-authored-by: Jennifer Shehane <jennifer@cypress.io>
2019-10-31 11:21:31 -04:00
Brian Mann 91a4477ad0 replace handlebars with squirrelly (#5521)
* WIP: rip out handlebars and implement with squirrelly

- handle caching ourselves
- TODO: add tests, make sure escaping and all that jazz works

* fixes squirrelly template handling

* only fire mocha events when in run mode

* add unit tests for template engine rendering + caching
2019-10-30 02:21:53 -04:00
Zach Bloomquist a3265ccdef Control Chrome cookies through CDP (#5297)
* try connecting to chrome remote interface

* linting

* print CRI targets for better debugging

* linting

* load empty tab first when connecting to CRI

* first load blank page, then navigate

* Page.navigate is working

* linting

* remove title

* add mocha banner

* more banners

* update some server unit tests

* update integration test

* document how to run single driver spec file

* set the focus back on the page before navigating from blank chrome tab

* update server unit test

* do not store Chrome remote interface reference for now

* record video of the Chrome tab using screencast API

* use dynamic port to connect to Chrome remote interface

* update unit tests

* refactoring

* wrap chrome remote interface in our interface, limit access to send

* resolved merge

* fix reference

* passing run unit spec

* stub canary search for CI to pass

* add build step to packages/server

* update chrome spec

* do not build js on install for server

* updated spec snapshots

* update 6_visit_spec snapshot

* update snapshot for 6_web_security_spec

* update snapshot for 3_plugins_spec

* update snapshot for 3_user_agent_spec

* update snapshot for 5_stdout_spec

* update snapshot for 2_browser_path_spec

* do not git ignore js files, add note why

* update several snapshots with video on Chrome

* update visit performance snapshot

* add chrome-remote-interface dependency

* cleanup coffeescript conversion to JS, fix some type errors, make parallel override clearer

* fix failing tests

* Fix snapshot - now we do record in Chrome, so warning message is no longer there.

* remove chrome warnings about not recording from snapshot

* Remove performance tests from 6_visit_spec snapshot

* Remove error from snapshot

* Add newline back to cy_visit_performance_spec snapshot

* Use CDP to control Chrome cookies + screenshot

* Add devtools types

* Cleanup

* Cleanup

* Add guards for minimum CDP version

* Fix failing tests

* Split cdp_automation_spec out of electron_spec

* Move takeScreenshot to cri-client

* Navigate to about:blank

* look for blank page url

* add note about avoiding Prettier

* disable prettier a little more

* call chrome remote interface close after each spec

* return promise when starting screencast

* update failing unit tests, add cri client close test

* update integration test

* Add verbose debug statements to cri-client

* Use connect.createRetryingSocket for CDP connection

* record video from chrome browsers

* add method for validating browser family

* update e2e spec snapshot

* update 4_request_spec snapshot

* update snapshot for spec 1_commands_outside_of_test_spec

* update snapshot for 3_plugins_spec

* update snapshot for spec 3_user_agent_spec

* try: Always log video capturing errors

* update snapshot for 2_browser_path_spec

* update snapshot for 2_cookies_spec

* better browser family test

* update snapshot for 5_stdout_spec

* update snapshot for 5_subdomain_spec

* Add protocol_spec tests

* do not capture video during performance test

* Add test for VIDEO_POST_PROCESSING_FAILED warning

* Add basic cookie validation in cy.setCookie

* Update cdp_automation to throw on Network.setCookie failure code

* Update tests 🎉

* Update snapshot

* Fix test

* Remove redundant logs, cleanup

* Add cri-client_spec, fix some small bugs, improve errors

* Update dep

* use client.on to register screencast callback

* use isCookieName

* strict-cookie-parser@3.1.0

* cleanup prettier, extract some functions, switch to browser.family

* moar cleanup and fixes

* add logging to the cri-client so we can see every message sent + received to the cdp protocol

* bump bluebird to 3.7.0 for .tapCatch addition

* Fix unit tests

* WIP: update e2e test to ensure that duration of the video matches what we expect

* Test duration of recorded video

* Run 6_video_compression in chrome + electron

* Cleanup

* finish ffmpeg duration verification

* Update 8_reporters_spec snapshot

* Fix cri-client test

* Update CRI close logic to monkey-patch browser.kill

* add isBrowserFamily back

* make it possible for remote-debugging-port to get overridden

* Make CDP timeout 5s; add unit, e2e tests for CDP failure; add user-friendly CDP failure error

* Update tests

* Use CYPRESS_REMOTE_DEBUGGING_PORT to set CDP port; update CDP error message

* Change new Buffer to Buffer.from

* Apply name validation on all cookie commands

* Just throw on Chrome start if the CDP version is < 1.3

* Fix cypress_spec

* Use CDP to set resolution + scale factor in Chrome e2e

* Revert "Use CDP to set resolution + scale factor in Chrome e2e"

This reverts commit a1b86d9413.

* use CYPRESS_FORCE_BROWSER_SCALE to force standard resolution

* don't do --window-size --kiosk

* Use CDP to set resolution + scale factor in Chrome e2e

* Revert "use CYPRESS_FORCE_BROWSER_SCALE to force standard resolution"

This reverts commit 22c5e78670.

* Use Page.captureScreenshot for Electron + Chrome, reduce logic

* Use before() task to force device metrics in Chrome

* Fix protocol_spec

* Update 7_record_spec to allow for before() hook

* Update 6_task_spec snapshot

* Appease eslint

* Update hooks in 5_spec_isolation snapshot

* some general promisification and cleanup

* feedback on pluginsfile

* cdp_automation feedback

* chrome.coff feedback

* feedback

* run e2e tests on port 4466, ensure no e2e test ever runs on 5566 to prevent conflicting with debugger port

* accept new 'remote:debugger:protocol' automation command to control device metrics overrides

* update web security e2e to run on electron + chrome

* run web security tests in electorn, disable context isolation

* pass disable-site-isolation-trials to Electron so webSecurity works

* Fix errors in e2e tests caused by extra log item

* fix cri-client unit tests

* fancy arrows in log message


Co-authored-by: Gleb Bahmutov <gleb.bahmutov@gmail.com>
Co-authored-by: Brian Mann <brian.mann86@gmail.com>
Co-authored-by: Jennifer Shehane <jennifer@cypress.io>
2019-10-21 17:07:53 -04:00
Zach Bloomquist 561bd21cda Run e2e tests in both Chrome and Electron (#5359)
* Update circle.yml to run e2e tests in chrome + electron

* WIP: create multiple tests per browser, but utilizing the same base snapshot

- create a dynamic test title with browser appended
- use a base named snapshot without the browser name appended
- patch snap-shot-it not to rethrow twice unnecessarily which ends up
throwing the wrong error

* Add e2e.coffee to stop-only ignore

* Convert existing x-browser e2e tests to use e2e.it

* update snapshots

* really add e2e to stop-only skip

* Replace screenshot dimensions in all tests, run only in process.env.BROWSER

* add e2e.it to more tests that should be x-browser

* update snapshots

* PEMDAS

* default e2e browser -> electron

Run afterEaches when skipping testo

Recurse upwards with runAfterEach

stop promise chains

* Revert "default e2e browser -> electron"

This reverts commit 3104f998da.

* Undo

* snap-shot-it@7.9.0

* Remove snap-shot-it patch

* Change e2e snapshot to use allowSharedSnapshot

* Add keepScreenshotDimensions to screenshot specs

* update snapshots

* fix snapshotit

* keepScreenshotDimensions: true -> sanitizeScreenshotDimensions: false

* Fix screenshot snapshots

* reduce snapshot noise

* rm 0_simple_spec

* deabstract circle.yml command

* fix circle.yml

* reduce snapshot noise

* clean up 6_visit_spec snapshot

* use allowSharedSnapshot: true in 5_spec_isolation

* Fix 5_screenshots, 2_form_submissions

* Normalize screenshot sizes in 5_spec_isolation snapshot

* Add sanitizeScreenshotDimensions only to non-e2e-project tests
Add --window-size=1280,720 --kiosk to chrome args

* update snapshots

* Use e2e.it for chrome/electron-specific tests

* handle logic for skipping tests when default browsers do not match specified browser

- implement e2e.it.skip to match mocha’s it.skip
- allow turning off dynamic test generation


Co-authored-by: Brian Mann <brian.mann86@gmail.com>
2019-10-16 21:10:50 -04:00
Gleb Bahmutov a877474df1 Connect to Chrome Remote Interface when launching Chrome and re… (#4628)
* try connecting to chrome remote interface

* linting

* print CRI targets for better debugging

* linting

* load empty tab first when connecting to CRI

* first load blank page, then navigate

* Page.navigate is working

* linting

* remove title

* add mocha banner

* more banners

* update some server unit tests

* update integration test

* document how to run single driver spec file

* set the focus back on the page before navigating from blank chrome tab

* update server unit test

* do not store Chrome remote interface reference for now

* record video of the Chrome tab using screencast API

* use dynamic port to connect to Chrome remote interface

* update unit tests

* refactoring

* wrap chrome remote interface in our interface, limit access to send

* resolved merge

* fix reference

* passing run unit spec

* stub canary search for CI to pass

* add build step to packages/server

* update chrome spec

* do not build js on install for server

* updated spec snapshots

* update 6_visit_spec snapshot

* update snapshot for 6_web_security_spec

* update snapshot for 3_plugins_spec

* update snapshot for 3_user_agent_spec

* update snapshot for 5_stdout_spec

* update snapshot for 2_browser_path_spec

* do not git ignore js files, add note why

* update several snapshots with video on Chrome

* update visit performance snapshot

* add chrome-remote-interface dependency

* cleanup coffeescript conversion to JS, fix some type errors, make parallel override clearer

* fix failing tests

* Fix snapshot - now we do record in Chrome, so warning message is no longer there.

* remove chrome warnings about not recording from snapshot

* Remove performance tests from 6_visit_spec snapshot

* Remove error from snapshot

* Add newline back to cy_visit_performance_spec snapshot

* Navigate to about:blank

* look for blank page url

* add note about avoiding Prettier

* disable prettier a little more

* call chrome remote interface close after each spec

* return promise when starting screencast

* update failing unit tests, add cri client close test

* update integration test

* Add verbose debug statements to cri-client

* Use connect.createRetryingSocket for CDP connection

* record video from chrome browsers

* add method for validating browser family

* update e2e spec snapshot

* update 4_request_spec snapshot

* update snapshot for spec 1_commands_outside_of_test_spec

* update snapshot for 3_plugins_spec

* update snapshot for spec 3_user_agent_spec

* try: Always log video capturing errors

* update snapshot for 2_browser_path_spec

* update snapshot for 2_cookies_spec

* better browser family test

* update snapshot for 5_stdout_spec

* update snapshot for 5_subdomain_spec

* Add protocol_spec tests

* do not capture video during performance test

* Add test for VIDEO_POST_PROCESSING_FAILED warning

* use client.on to register screencast callback

* cleanup prettier, extract some functions, switch to browser.family

* moar cleanup and fixes

* add logging to the cri-client so we can see every message sent + received to the cdp protocol

* bump bluebird to 3.7.0 for .tapCatch addition

* Fix unit tests

* WIP: update e2e test to ensure that duration of the video matches what we expect

* Test duration of recorded video

* Run 6_video_compression in chrome + electron

* Cleanup

* finish ffmpeg duration verification

* Update 8_reporters_spec snapshot

* Update CRI close logic to monkey-patch browser.kill

* add isBrowserFamily back

* make it possible for remote-debugging-port to get overridden

* Make CDP timeout 5s; add unit, e2e tests for CDP failure; add user-friendly CDP failure error

* Update tests

* Use CYPRESS_REMOTE_DEBUGGING_PORT to set CDP port; update CDP error message


Co-authored-by: Brian Mann <brian.mann86@gmail.com>
Co-authored-by: Jennifer Shehane <jennifer@cypress.io>
Co-authored-by: Zach Bloomquist <github@chary.us>
2019-10-11 18:36:05 -04:00
renovate[bot] daab2d7075 chore(deps): Update dependency bin-up and is-fork-pr (#5321)
Co-authored-by: Renovate Bot <bot@renovateapp.com>
Co-authored-by: Jennifer Shehane <jennifer@cypress.io>
2019-10-09 17:56:18 -04:00
Zach Bloomquist bbd452a9fc Update https-proxy-agent to 3.0.0 (#5311)
The fixes we need for our tests to run have been merged:

https://github.com/TooTallNate/node-https-proxy-agent/releases/tag/3.0.0

Co-authored-by: Jennifer Shehane <jennifer@cypress.io>
2019-10-09 15:38:27 -04:00
Zach Bloomquist 55494882fa Update https-proxy-agent to point back to original repo (#5294) 2019-10-04 12:06:32 -04:00
Gleb Bahmutov 4ec77e3d58 use Node path from config file to run plugins (#4436)
* use Node path from config file to run plugins

* add finding system node

* memoize node find, use fix-path if Node is not found

* find Node asynchronously

* update note on ENFILE

* print node version before executing registered event

* use nodeVersion option, add validator isOneOf

* linting

* remove resolve-dir

* debugging unit test

* resolve original promise to make the tests run correctly

* update second test

* add unit tests

* upgrade snap-shot-it package to be able to update snapshots

* make finding node path part of startup, merge into config

* update tests

* add node version & path to run output

* add node version display to desktop-gui

* add warnings, add tests, add learn more link in desktop-gui

* Revert "add node version & path to run output"

This reverts commit 40a3218175.

* only show Node Version if it is non-default

* Add e2e test for using system node

* cleanup

* add tests that resolvedNodePath and Version are available in tests

* assert nodeVersion == system

* add nodeVersion to schema

* add new configoptions to types

* add fallback if pluginsfile is disabled

* new package.json sorting

* update some of the wording/styling of Node Version panel

* remove ` from schema file

* clean up decaffeinated tests + update wording when no pluginsfile is present

* playing with messaging.

* push updated node version panel design

* update design + copy of Node panel again

* some more iteration on design (WIP)

* Finish design changes + fix tests

* add debug message

* linting problems

* add missed require

* Add comment to refactor the colWidths in this PR after another PR goes

* replace the exact length of Node version in specfiles

* print object for node version and path instead of %s %s

* update snapshot to match v12 length


Co-authored-by: Zach Bloomquist <github@chary.us>
Co-authored-by: Jennifer Shehane <jennifer@cypress.io>
2019-10-01 17:08:11 -04:00
renovate[bot] ab6aabb1bc fix(deps): update dependency sanitize-filename to version 1.6.3… (#5216)
Co-authored-by: Renovate Bot <bot@renovateapp.com>
2019-10-01 10:23:18 -04:00
Zach Bloomquist e7ecfcf518 Fix gzipped utf-8 .js files getting corrupted (#4984)
* add failing test for utf8 word boundary corruption

* use UTF-8 aware stream replacer

* cleanup

* cleanup test server

* add link to issue

* add replace_stream tests

* add license

* perf improvements - tsificiation

* emit the maximum chars possible

* add better types

* move license, update test
2019-09-28 22:26:25 -04:00
Chris Breiding 6ba8d7cc93 Electron v5.0.10 (#4720)
* fix specs

* use debugger protocol for cookie handling in electron

* use latest gulp

* use rimraf instead of gulp-clean

* use electron 3.1.8 and node 10.2.1

* use gulp 4 in packages/static

* fix sendCommandAsync, log Schema.getDomains on CDP connect

* autofill e2e test name [skip ci]

* electron@5.0.7, see what new failures exist

* --no-sandbox for launching Electron

* update cookies logic for electron

* node 12

* update snapshot for new node

* update error message for new node

* stub sendCommandAsync

* only connect to socket if path has been replaced, fixes #4776

* update node-sass to support node 12

* skip wacky socket tests for now

* snapshot

* fix run_plugins_spec snapshot, don't include stack trace

* use --no-sandbox on linux to run as root

* allow sendCommandAsync to resolve

* use euid for root check

* log domains even if undefined

* don't worry about ending 1xx responses immediately anymore

* use --max-http-header-size, change max size from 8kb to 1mb, fix #76

* do not send 502 on failed websocket, just send back ECONNRESET

* update websocket spec port to not collide with other test

* update outdated expect

* Revert "only connect to socket if path has been replaced, fixes #4776"

This reverts commit f179eda5ca.

* update gulp in root

* update https-proxy unit tests

* update network spec to properly close server

* update reporter spec

* update https-proxy-agent to fix node 10.10.0 change

discussion: https://github.com/nodejs/node/issues/24474\#issuecomment-511963799

* only pass --max-http-header-size on node >=12

* use own server-destroy implementation that supports secureConnect events

* oops

* update socket_spec

* electron 6.0.0

* console.table introduced in node 10

* change browserify entry to init.js

* handle edge case when no response body

* console.table added in node 10

* do not exit app when all BrowserWindows are closed

* update e2e snapshots

* value may not be null

* update plugins spec

* correct cookie expiry, use browser.getversion for CDP version check

* fix snapshotting for require stacks

* reorder cookies in spec

* warn when depreated electron callback apis are used

* only report 1 plugin error per process

* cleanup

* node 12.4.0, cypress/browsers:node12.4.0-chrome76 docker image

* update shell.openExternal to promisified

* update dialog.showOpenDialog to promisified

* update webContents.session.setProxy to promisified

* updating native dependencies since we don't need ancient node ABI support anymore

* WIP: switch cookies to simpler, jar-less approach

* WIP: switch cookies to simpler, jar-less approach

* making tests pass

* improve cookie filtering logic

* Remove unneeded Promise.try

* filter what makes it to the extension

* properly re-set superdomain cookies on cross-origin cy.visit

* allow comma-separated list of e2e tests

* sort cookies in order of expiration date, ascending

* updating tests, cleanup

* update tests

* version electron as a devDependency, electron@6.0.1

* cleanup, remove old automation

* cleanup, remove old automation

* bump chokidar to fix win10 + node12 issue

was seeing this on windows:
https://github.com/nuxt/nuxt.js/issues/6035

fixed with version bump

* enable now-supported quit role, re-enable old tests

* don't need that arg there

* remove last deprecated callback electron invocations

* Delete cypress.json

* responding to PR feedback

* cleanup

* invoke

* use 'quit' role

* Use new appMenu role for Cypress menu on mac

* electron@6.0.2

* electron@6.0.3

* remove domain: cookie.domain and see what happens

* remove setErrorHandler

* Revert "remove domain: cookie.domain and see what happens"

This reverts commit 49e916896d.

* add unit tests for cookies

* ci

* fix project-content css

* electron@6.0.4

* fix specs_list test

* electron@6.0.7

* some cleanup

* electron@6.0.9

* Update 8_reporters_spec.coffee.js

* electron@5.0.10 - Chromium 73, Node 12

* cli: fix the STDIN pipe on Windows (#5045)

* cli: pipe stdin

* uggh, here is the actual change

* update cli unit tests

* add unit test

* more permissive check for json to include application/vnd.api+j… (#5166)

* more permissive check for json to include

* add json test for content-type application/vnd.api+json

* cruder solution passes e2e tests locally, so let's go with that

* Remove 'charset' from content-type before checking if JSON

* fix eslint for fixture specs (#5176)

* update eslint to lint files within 'fixtures' in support files

- ignore some edge cases like jquery, jsx and obvious js files we wrote
with broken code

* Fixes from eslint to 'fixtures' files

* Catch env variable with reserved name CYPRESS_ENV 1621 (#1626)

* server: check CYPRESS_ENV variable when merging configs

* catch invalid CYPRESS_ENV value in CLI, close #1621

* linting

* sanitize platform in test snapshot

* linting

* update error message text

* add missing comma

* fix finally merge in JS code

* pass CLI linter

* fix log reference, should be debug

* use correct sinon reference

* update message, show first part in red

* update error message text

* Addresses #2953 (#5174)

* Addresses #2953

* Added proper test for new error message

* Didn't realize it ran this test as well, whoops

* Implementing changes as suggested by @jennifer-shehane

* Fixing tests and error output. Moved the checks to the start of the get command to ensure we always catch improper options

* Removing issue test since the querying spec covers it

* Using coffescript isArray check

* depromisify things that were promisified b/t electron 5 <=> 6

Revert "update shell.openExternal to promisified"

This reverts commit 8b6460d015.

Revert "update dialog.showOpenDialog to promisified"

This reverts commit 5f178b075b.

Revert "update webContents.session.setProxy to promisified"

This reverts commit 727df3a4e5.

* node12.4.0-chrome76 => node12.0.0-chrome75

* fix tests for electron downgrade

* node12.0.0-chrome75 => node12.0.0-chrome73


Co-authored-by: Zach Bloomquist <github@chary.us>
Co-authored-by: Brian Mann <brian.mann86@gmail.com>
2019-09-24 14:35:24 -04:00
Zach Bloomquist 7b85344b84 Fix proxying HTTPS requests to IP addresses (#4947)
* use own server-destroy implementation that supports secureConnect events

* stand up HTTPS server for requests over ssl to IPs

* don't need to resolve with

* fix tests

* stand up a server on 127.0.0.1 for test

* tighten up / cleanup code, consolidate + refactor

- lazily fs.outputfile’s
- move sslIpServers to be global
- add remove all CA utility

* Improve proxy_spec test

* Don't crash on server error events

* feedback

* derp


Co-authored-by: Brian Mann <brian.mann86@gmail.com>
2019-09-12 15:30:10 -04:00
Jennifer Shehane 1a4ac7d84c replace abandoned cli-table2 dep for currently maintained cli-t… (#5118)
* replace abandoned cli-table2 dep for currently maintained cli-table3 dep

* update dep require :P
2019-09-10 15:23:02 -04:00
renovate[bot] 9fa3f0989c fix(deps): update dependency term-size to version 2.1.0 🌟 (#5119)
Co-authored-by: Renovate Bot <bot@renovateapp.com>
2019-09-10 14:19:34 -04:00
renovate[bot] 796f2686d6 fix(deps): update dependency @cypress/get-windows-proxy to vers… (#5108)
Co-authored-by: Renovate Bot <bot@renovateapp.com>
2019-09-10 13:33:23 -04:00
Zach Bloomquist ca0b74930c Move fast_visit_spec to performance-test stage, track perf (#4989)
* Move fast_visit_spec to performance-test stage

* upload results from fast_visit_spec and proxy_performance_spec

* test

* Track URL in proxy_perf_spec

* also send commit timestamp

* use more params, use ciProviders where possible

* test

* add platform + arch

* use commit-info for timestamp, commit message

* Revert "use commit-info for timestamp, commit message"

This reverts commit a55d16af3d.

* use commit-info for timestamp, commit message

* just always have nock

* slice(1) the testCases

* send current retry with fast_visit_spec

* currentRetry
2019-08-21 14:19:48 -04:00
renovate[bot] 6be24f62d5 fix(deps): update dependency duplexify to version 4.1.1 🌟 (#4853)
Co-authored-by: Renovate Bot <bot@renovateapp.com>
2019-07-29 15:44:57 +06:30
renovate[bot] 189935cfcb fix(deps): update dependency browserify to version .x 🌟 (#4826)
Co-authored-by: Renovate Bot <bot@renovateapp.com>
2019-07-26 16:09:33 +06:30
renovate[bot] 862ad33fb3 chore(deps): update dependency mockery to version .x 🌟 (#4819)
Co-authored-by: Renovate Bot <bot@renovateapp.com>
2019-07-26 14:14:57 +06:30
renovate[bot] 1324ec2566 fix(deps): update dependency browserify to version .x 🌟 (#4825)
Co-authored-by: Renovate Bot <bot@renovateapp.com>
2019-07-26 13:48:33 +06:30
renovate[bot] 55e96186ff fix(deps): update dependency graceful-fs to version 4.2.0 🌟 (#4818)
Co-authored-by: Renovate Bot <bot@renovateapp.com>
2019-07-25 17:55:58 +06:30
renovate[bot] 3b93c7b9be chore(deps): update dependency supertest-session to version .x… (#4815)
Co-authored-by: Renovate Bot <bot@renovateapp.com>
2019-07-25 17:25:31 +06:30
renovate[bot] 9883aaed56 chore(deps): update dependency supertest-session to version .x… (#4813)
Co-authored-by: Renovate Bot <bot@renovateapp.com>
2019-07-25 16:55:46 +06:30
renovate[bot] b7de89e661 chore(deps): Update dependency supertest-session to version .x… (#4809)
* chore(deps): Update supertest-session to 2.0.1 🌟

* update supertest-session to no longer use module configuration - as this has been removed in 2.x

* supertest-session also no longer requires obj + app key, just pass app


Co-authored-by: Renovate Bot <bot@renovateapp.com>
Co-authored-by: Jennifer Shehane <jennifer@cypress.io>
2019-07-25 14:35:25 +06:30
Jennifer Shehane f189d5e408 remove packages that do not appear to be used (#4755)
- I may have broken things - let’s see.
2019-07-25 11:08:01 +06:30
renovate[bot] a6cf9d5a13 fix(deps): update dependency semver to version 6.3.0 🌟 (#4797)
Co-authored-by: Renovate Bot <bot@renovateapp.com>
2019-07-24 18:21:14 +06:30
renovate[bot] 39f72439f3 chore(deps): update dependency supertest-session to version .x… (#4718)
Co-authored-by: Renovate Bot <bot@renovateapp.com>
Co-authored-by: Jennifer Shehane <jennifer@cypress.io>
2019-07-24 15:39:15 +06:30
renovate[bot] ce86d54c55 fix(deps): Update dependency @ffmpeg-installer/ffmpeg to versio… (#4792)
Co-authored-by: Renovate Bot <bot@renovateapp.com>
2019-07-24 11:38:01 +06:30