* (related to the InputStream) and that it returns -1 at the end of stream.
*/
public void testRead1() throws Exception {
byte[] data = new byte[] { -127, -100, -50, -10, -1, 0, 1, 10, 50, 127 };
TestInputStream tis = new TestInputStream(data);
CipherInputStream cis = new CipherInputStream(tis, new NullCipher());
byte res;
for (int i = 0; i < data.length; i++) {
if ((res = (byte) cis.read()) != data[i]) {
fail("read() returned the incorrect value. " + "Expected: "
+ data[i] + ", Got: " + res + ".");