// Regression for HARMONY-24
try {
URLEncoder.encode("str","unknown_enc");
fail("Assert 0: Should throw UEE for invalid encoding");
} catch (UnsupportedEncodingException e) {
// expected
}
//Regression for HARMONY-1233
try {
URLEncoder.encode(null, "harmony");
fail("NullPointerException expected");
} catch (NullPointerException e) {
//expected
}