[ELY-94] Replace tests against exact KeySpec types for isAssignableFrom checks
Merge remote-tracking branch 'stefan/master'