KEYCLOAK-662 NPE when using direct grant API with email as username
KEYCLOAK-722 Refreshing token throws RuntimeException if realm keys have changed

Conflicts:
	testsuite/integration/src/test/java/org/keycloak/testsuite/oauth/RefreshTokenTest.java

Backport changes to AssertEvents
Merge pull request #738 from stianst/Branch_1_0

Fixes