Refactoring and added tests
Merge branch 'master' of https://eddyh@github.com/software-engineering-amsterdam/poly-ql.git