Skip to content
Permalink
Browse files

Forcing the Articles to contain Tags for test passing

  • Loading branch information...
Patrick Conroy
Patrick Conroy committed Aug 26, 2014
1 parent dfe379d commit d1d63a85aa48b9073903e356b964caac2e9f49c4
Showing with 1 addition and 1 deletion.
  1. +1 −1 tests/test_app/TestApp/Model/Table/ArticlesTable.php
@@ -61,7 +61,7 @@ public function doSomethingElse() {
*/
public function findCustomTags(Query $query, array $options = []) {
if (isset($options['tags']) && is_array($options['tags'])) {
return $query->matching('Tags', function($q) use ($options) {
return $query->contain(['Tags'])->matching('Tags', function($q) use ($options) {
return $q->where(['Tags.id IN' => $options['tags']]);
});
}

0 comments on commit d1d63a8

Please sign in to comment.
You can’t perform that action at this time.