blob: 969945435a0153342e95d22166f5edeed5db99c2 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
|
package org.simpleframework.common.buffer;
import junit.framework.TestCase;
public class FileByteQueueTest extends TestCase {
public void testQueue() throws Exception {
/* Allocator allocator = new FileAllocator();
FileByteQueue queue = new FileByteQueue(allocator);
for(int i = 0; i < 26; i++) {
queue.write(new byte[]{(byte)(i+'a')}, 0, 1);
System.err.println("WRITE>>"+(char)(i+'a'));
}
for(int i = 0; i < 26; i++) {
byte[] buffer = new byte[1];
assertEquals(queue.read(buffer, 0, 1), 1);
System.err.println("READ>>"+((char)buffer[0]));
assertEquals(buffer[0], (byte)(i+'a'));
}*/
}
}
|