Database tests: added use Assert statement
Database tests: updated to Context

- removed calling deprecated methods
- renamed $dao to $context
Database tests: reenabled backjoin tests for joning over specific column
Merge pull request #1295 from hrach/db-tests

Db tests
Latte: alternative PHP syntax for control structures (if:, endif) replaced with default syntax to avoid problems with mixing syntaxes. [Closes #1296]

`if (TRUE): if (TRUE) echo 1; else: echo 2; endif;`
Latte: fixed quoteFilter
Latte: optimized output, removed empty addAttribute(array())