mirror of
https://github.com/cypress-io/cypress.git
synced 2026-04-23 07:34:00 -05:00
9cdb33b4c6
* test: refactor and add tests in the cors package * fix: add areUrlsSameSite method to cookies package and fix sameSiteContext calculation method and add tests * fix: always use Set-Cookie optimistically whether or not we keep track of the cookie or not in the server side cookie jar * chore: add failing unit tests for postpending cookies * chore: add tough cookie integration tests to verify we append cookies appropriately to request header Cookie * fix: do not duplicate cookies in request if existing in the cookie jar. Add additional tests to verify expected behavior * test: add cookie behavior tests that document current expected behavior vs what spec behavior should/will be * test: add misc tests that check for cookie order * chore: update debug logs in request to discern cookies * test: fix assertions in firefox as same-site cookies are actually set correctly * fix test incorrect assertions. cookies currently exist in primary that are same-site regardless of browser * skip SameSite=none test in firefox as we currently low insecure samesite none cookies in firefox * chore: apply suggestions from code review * chore: change expects to expect * chore: add documentation for why we need an additional HTTPS port * remove X-Set-Cookie fixmes
network
This package contains networking-related classes and utilities.
Exports
You can see a list of the modules exported from this package in ./lib/index.ts. Here is a brief description of what's available:
agentis a HTTP/HTTPS agent with support for HTTP/HTTPS proxies and keepalive whenever possibleallowDestroycan be used to wrap anet.Serverto add a.destroy()methodblockedis a utility for matching blocked globsconcatStreamis a wrapper aroundconcat-stream@1.6.2that makes it always yield aBufferconnectcontains utilities for making network connections, includingcreateRetryingSocketcorscontains utilities for Cross-Origin Resource Sharinguricontains utilities for URL parsing and formatting
See the individual class files in ./lib for more information.
Building
Note: you should not ever need to build the .js files manually. @packages/ts provides require-time transpilation when in development.
yarn workspace @packages/network build-prod
Testing
Tests are located in ./test
To run tests:
yarn workspace @packages/network test
yarn workspace @packages/network test-watch
yarn workspace @packages/network test-debug