laravel/framework — pull request #2687 by karptonite (2013-11-10 14:42:57+00:00)
Title: Implements cache tags for query builder from issue #2630

Also refactors builder tests for cache.

The syntax is
```$users = DB::table('users')->remember(10)->tags(array('foo','bar'))->get();```
and
```$users = DB::table('users')->rememberForever()->tags(array('foo','bar'))->get();```

The placement of the call to tags is irrelevant, as long as it is after table() and before get().
tags() will take either an array of tags, or a single string, just like the tags() method in the caching system.
If neither remember() nor rememberForever() are called at all, the call to tags() will be ignored.

Also, I wrote an integration test which used the ArrayStore directly, just to make myself feel a bit more confident that it would work. I didn't check it in because you usually don't have integration tests among your unit tests, but I can provide it if you're interested.