Fix getMockForModel() using the incorrect datasource.

Because getMockForModel() does not go through the test datasource
injection in ClassRegistry::init() we need to duplicate the basics of
that logic here. Thankfully, we already have a mock so we can do that
datasource switching without reflection. Of course this means there will
be limitations to how/when this will work, but I feel those scenarios
can probably be solved by not using mocks, or by mocking out the
problematic methods. This set of changes makes getMockForModel() work
with secondary datasources, as one would expect it to do, but I'm not
sure it ever did.

Refs #4694
Add BC test for #4851
Possible fix for isUnique backward compatibility
Merge pull request #4871 from rchavik/2.5-is-unique-test

2.5 Add isUnique test + possible fix
Make rule sniff less complicated and tidy up doc block.

Refs #4871
Fix PHPCS and PHP5.3 error.
Merge branch 'master' into 2.6

Conflicts:
	lib/Cake/VERSION.txt
Merge branch '2.6' of github.com:cakephp/cakephp into 2.6
Merge pull request #4867 from cakephp/issue-4694

Fix getMockForModel() using the incorrect datasource.
Add default prefix to RedisEngine

This makes redis work like the other cache engines. Also by having
a default prefix the clear() method will not wipe all the data in the
current redis database.

Refs #4876
Merge pull request #4884 from cakephp/issue-4876

Add default prefix to RedisEngine
Fix Memcached test failures.

The Memcached extension does not provide enough information to PHP's
Reflection API to allow mock objects to be generated correctly. We'll
skip the affected tests until php-memcached-dev/php-memcached#126 has
been resolved.
Merge pull request #4891 from cakephp/fix-memcached-failures

Fix Memcached test failures.
Merge branch 'master' into 2.6
Merge remote-tracking branch 'origin/2.6' into 3.0

Conflicts:
	lib/Cake/Model/Model.php
	lib/Cake/Test/Case/Model/ModelValidationTest.php
	src/Cache/Engine/RedisEngine.php
	src/TestSuite/TestCase.php
	tests/TestCase/Cache/Engine/MemcachedEngineTest.php
	tests/TestCase/Cache/Engine/RedisEngineTest.php
	tests/TestCase/TestSuite/TestCaseTest.php
Merge branch '3.0' of github.com:cakephp/cakephp into 3.0