Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Ref core issue #1671200: Simpletest broken: CURLOPT_COOKIEJAR cannot be NULL. On some PHP configurations the cURL options are not set correctly, causing HTML output to be returned in the AJAX calls. This causes the familiar An AJAX HTTP error occurred. HTTP Result Code: 200 Debugging information follows.
error messages.
Comment | File | Size | Author |
---|---|---|---|
#5 | simpletest-curlopts-1692836-5-D6.patch | 1.52 KB | kentr |
#2 | 1692836-2-simpletest-curlopts.patch | 2.58 KB | pfrenssen |
#1 | 1692836-1-simpletest-curlopts.patch | 2.08 KB | pfrenssen |
Comments
Comment #1
pfrenssenI rerolled the patch that was made by jaimealsilva and sun and was posted in comment #4 in #1671200: Simpletest broken: CURLOPT_COOKIEJAR cannot be NULL for contrib Simpletest.
Comment #2
pfrenssenDrupalRemoteTestCase::setUp() is not inheriting DrupalWebTestCase::setUp(). This patch also sets $this->cookieFile in DrupalRemoteTestCase::setUp(), but a cleaner solution would indeed be to do this in curlInitialize().
Comment #3
djdevinThis also exists in 6.x-2.x, and also any version with PHP 5.3.14.
Comment #4
pfrenssenThe patch in #1671200: Simpletest broken: CURLOPT_COOKIEJAR cannot be NULL has landed in D8 and there is a new version of the patch for D7.
Comment #5
kentr CreditAttribution: kentr commentedD6 patch attached.
Though one could also create a new class to extend
DrupalWebTestCase
with a correctcurlInitialize()
method.