@Test void generateWithoutArgument() { Throwable exception = assertThrows(UnsupportedOperationException.class, () -> generator.generate()); assertEquals("Knowing the key strength is required to generate a key.", exception.getMessage()); }
@Override public byte[] generate() { throw new UnsupportedOperationException("Knowing the key strength is required to generate a key."); }
DefaultKeyGenerator implements KeyGenerator { @Override public byte[] generate() { throw new UnsupportedOperationException("Knowing the key strength is required to generate a key."); } }
DefaultKeyGenerator implements KeyGenerator { @Override public byte[] generate() { throw new UnsupportedOperationException("Knowing the key strength is required to generate a key."); }  }
DefaultKeyGenerator implements KeyGenerator { @Override public byte[] generate() { throw new UnsupportedOperationException("Knowing the key strength is required to generate a key."); }  @Override byte[] generate(); @Override byte[] generate(KeyGenerationParameters parameters); }
DefaultKeyGenerator implements KeyGenerator { @Override public byte[] generate() { throw new UnsupportedOperationException("Knowing the key strength is required to generate a key."); }  @Override byte[] generate(); @Override byte[] generate(KeyGenerationParameters parameters);  }