simple test

This commit is contained in:
Zlatin Balevsky
2018-07-17 22:31:34 +01:00
parent 8e464604f4
commit c28708feb7

View File

@@ -0,0 +1,16 @@
package com.muwire.core
import static org.junit.jupiter.api.Assertions.assertEquals
import org.junit.Test
class InfoHashTest {
@Test
void testEmpty() {
byte [] empty = new byte[0x1 << 6];
def ih = InfoHash.fromHashList(empty)
def ih2 = new InfoHash("6ws72qwrniqdaj4y55xngcmxtnbqapjdedm7b2hktay2sj2z7nfq");
assertEquals(ih, ih2);
}
}