Adding test to prove #5107
Fixes #5107 and removes some unneded code
Merge pull request #5108 from cakephp/3.0-pagination-union

3.0 pagination union