TH - made working functional tests
Merge branch 'master' into development