Fix stream emulation #193

Closed
wants to merge 2 commits into
from

Conversation

Projects
None yet
1 participant
@markstory

Context

Stream API emulation is incomplete, because headers cannot be accessed out of the wrapper data so client code that works with native streams + curlwrappers fails when emulated by VCR.

What has been done

  • I've added the missing behavior to access the headers key which is populated by the native http and https stream implementations when PHP is compiled with curlwrappers support (the default on osx)
  • I've had to skip all the SOAP related tests. The WSDL file they are based on is throwing IIS errors. See http://wsf.cdyne.com/WeatherWS/Weather.asmx?WSDL

How to test

  • Use the CakePHP or Aura HTTP clients and turn on VCR. Without these changes you get mostly cryptic errors.

Todo

N/A

Notes

N/A

markstory added some commits Mar 19, 2017

Skip SOAP tests.
The WSDL files from cdyne.com are no longer available. Because this
service is offline the quickest way to get a passing test run was to
skip some tests.
Add headers to stream wrapper_data emulation.
When using the stream_* methods some clients expect that there is an
internal key of `headers`. By emulating this key VCR can be compatible
with more clients. I encountered this issue when trying to use VCR with
the CakePHP HTTP Client which uses the stream API.
@markstory

This comment has been minimized.

Show comment
Hide comment
@markstory

markstory Jan 4, 2018

Closing as #230 incorporates these changes with test fixes.

Closing as #230 incorporates these changes with test fixes.

@markstory markstory closed this Jan 4, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment