XWIKI-8931: Support global user in local group in the new security authorization module
* add tests
* various improvements to the test framework and apply codestyle