Analytic functions tests

Added several tests for analytical functions

Tests for the following have not been added because it's not implemented yet:
- Lag, Lead functions
- Window clauses

Change-Id: I34546c967a6d29c97327f4cba405006a50867dcb
Reviewed-on: http://gerrit.sjc.cloudera.com:8080/4307
Reviewed-by: Taras Bobrovytsky <tbobrovytsky@cloudera.com>
Tested-by: jenkins