@Test
    public void testGetEncodedThrowsWhenNotInitialized() throws Exception {
        AlgorithmParameters params = AlgorithmParameters.getInstance("PSS");
        try {
            params.getEncoded();
            fail();
        } catch (IOException expected) {}
        try {
            params.getEncoded("ASN.1");
            fail();
        } catch (IOException expected) {}
    }
Payload of SEQUENCE extends beyond the SEQUENCE.
common/src/test/java/org/conscrypt/java/security/AlgorithmParametersPSSTest.java