Flushing should be off by default, just like it is when you are on the site normally.
It's not obvious that tests always flush when they run and you have to pass flush=0 to turn them off. People expect to have to flush to clear the cache, and the documentation already covers mentions about flushing
-> http://doc.silverstripe.org/en/developer_guides/testing/unit_testing/
-> phpunit framework/tests '' flush=all
# Run tests with optional `$_GET` parameters (you need an empty second argument)
Detect and parse HTTP_AUTHORIZATION for basic authentication running PHP in CGI mode
Add comments about using CGI mode with Apache and Basic Auth in /docs/en/topics/environment-management.md
Added notes to docs/en/changelogs/3.1.9.md
In cases where CLI tidy fails to recognise HTML with errors or
unknown HTML5 elements, it doesn't output any content and
CSSContentParser fails.
This adds the --force-output parameter so that it always outputs
the input content, even if it wasn't completely fixed by tidy.
It seems that tidy class in PHP already does this, so this just
fixes the CLI use of tidy in CSSContentParser to be consistent.
This fix can be observed on the HHVM travis builds, as tidy isn't
compiled into HHVM as an extension.
Example: you have a site in a sub-directory off the webroot, you call
->Link() on a SiteTree record, which returns "/[sitedir]/my-page", and
you pass this URL to Director::test(). It's a valid URL, but
Director::test() will throw a 404.
Director::test() should be ensuring that all URLs passed to it are
properly made relative, not just in the case where it thinks the URL
is absolute.
Summary:
PHPUnit 3.8+ adds a method to its PHPUnit_Framework_TestListener called addRiskyTest(). Need to stub it out to avoid "must implement this interface method" fatals when using 3.8+
Test Plan:
Reviewers:
CC:
Task ID: #
Blame Rev:
Provides an interface for classes to implement their own flush()
functionality. This function gets called early in a request on
all implementations of Flushable when flush=1|all is requested in the
URL.
This fix came out of an issue where Requirements combined files were not
being cleaned up after dev/build?flush=1, due to the fact that flush
would only occur when you called it while on a page that used those
combined files, but not in any other contexts. This will now call flush
on any implementors of Flushable regardless of the context of where
flush was called.
FIX for phpunit error message: ERROR [Strict Notice]: Declaration of SapphireTest::assertNotContains() should be compatible with PHPUnit_Framework_Assert::assertNotContains, and the same error for assertContains()
Move functionality from static start and destroy functions into instance
methods, allowing these to be overloaded. This works the same way as
calling Session::set() which then in turn calls inst_set()
Additionally use Injector to create the default Session instance to
allow the class to be swapped out.