Improve qb validation

fixes some bugs in the tests, also fixes https://github.com/doctrine/phpcr-odm/issues/541

note ``Doctrine\Tests\ODM\PHPCR\Query\Builder\BuilderConverterPhpcrTest::testOrderBy`` is failing .. but honestly I don't really think such a test makes sense. It is way too complex to test as it requires so much mocking. IMHO we are better off testing this via the various existing functional test. So I vote for removing that test.

/cc @dantleech 

in my original commit we only checked for nodetype and associations inside the foreach for orderings:
https://github.com/doctrine/phpcr-odm/commit/5fa4e2cf0e1a7704c3b03a7c3dfc94407dce0665#diff-0f74c7373c7c111b598f851ef2957d0eR760

I am still not sure where the issue was with that version of the PR