Switch back from with() to join()->on() because DB::select returns a
Database_Query_Builder_Select which doesn't have a with() -- that's an
ORM construct.  Also fix up some table names.
Integrate PHPUnit and get it running.  It doesn't find any tests
currently so it's all red all the time.
Merge branch 'kohana_3' of github.com:gallery/gallery3 into kohana_3