package yaz4jtest;
import org.junit.*;
import static org.junit.Assert.*;
import java.util.*;

public class ConnectionTest {
	@Test
	public void testConnection() {
		org.yaz4j.Connection con = new org.yaz4j.Connection("z3950.indexdata.dk:210/gils", 0);
		assertNotNull(con);
		org.yaz4j.PrefixQuery pqf = new org.yaz4j.PrefixQuery("@attr 1=4 utah");
		con.Search(pqf);
	}
}

@@ -267,16 +267,42 @@
 l(con);%0A
+%09%09con.setSyntax(%22sutrs%22);%0A
 %09%09org.ya
@@ -374,22 +374,316 @@
 ;%0A%09%09
-con.Search(pqf
+assertNotNull(pqf);%0A%09%09org.yaz4j.ResultSet s = con.Search(pqf);%0A%09%09assertNotNull(s);%0A%09%09assertEquals(s.getSize(), 9);%0A%09%09org.yaz4j.Record rec = s.getRecord(0);%0A%09%09assertNotNull(rec);%0A%09%09byte %5B%5D content = rec.getContent();%0A%09%09// first SUTRS record%0A%09%09assertEquals(content.length, 1940);%0A%09%09assertEquals(content%5B0%5D, 103
 );%0A%09

Use ResultSet and Record in test.