@@ -0,0 +1,1317 @@
+package com.wizzardo.epoll;%0A%0Aimport org.junit.Test;%0A%0Aimport java.nio.ByteBuffer;%0A%0Aimport static org.junit.Assert.assertEquals;%0A%0A/**%0A * Created by wizzardo on 24/04/16.%0A */%0Apublic class EpollCoreTest %7B%0A%0A    @Test%0A    public void test_copy() %7B%0A        int limit = 256;%0A        ByteBuffer src = ByteBuffer.allocateDirect(limit);%0A        ByteBuffer dst = ByteBuffer.allocateDirect(limit);%0A        for (int i = 0; i %3C limit; i++) %7B%0A            src.put((byte) i);%0A        %7D%0A%0A        EpollCore.arraycopy(src, 0, dst, 0, limit);%0A        dst.limit(limit);%0A        for (int i = 0; i %3C limit; i++) %7B%0A            assertEquals((byte) i, dst.get());%0A        %7D%0A    %7D%0A%0A    @Test%0A    public void test_copy_2() %7B%0A        int limit = 256;%0A        ByteBuffer src = ByteBuffer.allocateDirect(limit);%0A        ByteBuffer dst = ByteBuffer.allocateDirect(limit);%0A        for (int i = 0; i %3C limit; i++) %7B%0A            src.put((byte) i);%0A        %7D%0A%0A        EpollCore.arraycopy(src, 0, dst, 0, limit);%0A        dst.limit(limit);%0A        for (int i = 0; i %3C limit; i++) %7B%0A            assertEquals((byte) i, dst.get());%0A        %7D%0A        for (int i = 0; i %3C limit; i++) %7B%0A            EpollCore.arraycopy(src, i, dst, i, 1);%0A            dst.position(i);%0A            dst.limit(i + 1);%0A            assertEquals((byte) i, dst.get());%0A        %7D%0A    %7D%0A%7D%0A

add tests for 'copy direct byte-buffer'