Closed (fixed)
Project:
Views (for Drupal 7)
Version:
7.x-3.x-dev
Component:
tests
Priority:
Critical
Category:
Task
Assigned:
Unassigned
Reporter:
Created:
17 Aug 2017 at 20:23 UTC
Updated:
1 Sep 2017 at 17:49 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #2
damienmckennaThere were two instances of short-syntax arrays.
Comment #4
David_Rothstein commentedThe patch looks good - I was going to mark this RTBC, but not sure what's up with that unrelated test failure. I'll trigger a retest.
Note that this issue is also causing test failures in other modules besides Views, which use it in their tests (for example, see #1635750: OG Context handler for ajax calls (system, file upload, autocomplete, etc)).
Comment #6
damienmckennaYeah, that's annoying.
That points to this line:
.. and the variable comes from:
.. and test_feed_http_headers_caching is a view that comes from the views_test module. So this should work. I guess I need to run the tests locally to work out what's going on.
Comment #7
damienmckennaFYI I get the same error locally too.
Comment #8
damienmckennaI went back to 7.x-3.16 and ViewsCacheTest works ok there. Looking at the difference in the output, though, I wonder if the problem is simply a matter of unwanted whitespace? I added print_r($first_content) and there are more blank lines between the intro and the intro xml tag in the 7.x-3.x codebase than there are on 7.x-3.16.
Comment #9
Stevel commentedThe error is caused by a space introduced at the top of tests/views_test.views_default.inc in the latest security patch. I'll roll a patch shortly to remove this space.
Comment #10
Stevel commentedHere's the patch that solved this for me.
Comment #12
Stevel commentedNew patch combining both above patches.
Edit: It worked for me without the array() patch, but I'm running PHP 7 and the shorthand syntax for array() was introduced in PHP 5.4. We still need to support 5.2.5+ here though.
Comment #14
damienmckennaThanks for finding that, Stevel!
Comment #15
dawehnerThank you for this quick fix!