@ -101,7 +101,7 @@ public class ReftableTest {
try ( RefCursor rc = t . seekRef ( HEAD ) ) {
try ( RefCursor rc = t . seekRef ( HEAD ) ) {
assertFalse ( rc . next ( ) ) ;
assertFalse ( rc . next ( ) ) ;
}
}
try ( RefCursor rc = t . seekRef ( R_HEADS ) ) {
try ( RefCursor rc = t . seekPrefix ( R_HEADS ) ) {
assertFalse ( rc . next ( ) ) ;
assertFalse ( rc . next ( ) ) ;
}
}
try ( LogCursor rc = t . allLogs ( ) ) {
try ( LogCursor rc = t . allLogs ( ) ) {
@ -317,10 +317,10 @@ public class ReftableTest {
public void namespaceNotFound ( ) throws IOException {
public void namespaceNotFound ( ) throws IOException {
Ref exp = ref ( MASTER , 1 ) ;
Ref exp = ref ( MASTER , 1 ) ;
ReftableReader t = read ( write ( exp ) ) ;
ReftableReader t = read ( write ( exp ) ) ;
try ( RefCursor rc = t . seekRef ( "refs/changes/" ) ) {
try ( RefCursor rc = t . seekPrefix ( "refs/changes/" ) ) {
assertFalse ( rc . next ( ) ) ;
assertFalse ( rc . next ( ) ) ;
}
}
try ( RefCursor rc = t . seekRef ( "refs/tags/" ) ) {
try ( RefCursor rc = t . seekPrefix ( "refs/tags/" ) ) {
assertFalse ( rc . next ( ) ) ;
assertFalse ( rc . next ( ) ) ;
}
}
}
}
@ -332,12 +332,12 @@ public class ReftableTest {
Ref v1 = tag ( V1_0 , 3 , 4 ) ;
Ref v1 = tag ( V1_0 , 3 , 4 ) ;
ReftableReader t = read ( write ( master , next , v1 ) ) ;
ReftableReader t = read ( write ( master , next , v1 ) ) ;
try ( RefCursor rc = t . seekRef ( "refs/tags/" ) ) {
try ( RefCursor rc = t . seekPrefix ( "refs/tags/" ) ) {
assertTrue ( rc . next ( ) ) ;
assertTrue ( rc . next ( ) ) ;
assertEquals ( V1_0 , rc . getRef ( ) . getName ( ) ) ;
assertEquals ( V1_0 , rc . getRef ( ) . getName ( ) ) ;
assertFalse ( rc . next ( ) ) ;
assertFalse ( rc . next ( ) ) ;
}
}
try ( RefCursor rc = t . seekRef ( "refs/heads/" ) ) {
try ( RefCursor rc = t . seekPrefix ( "refs/heads/" ) ) {
assertTrue ( rc . next ( ) ) ;
assertTrue ( rc . next ( ) ) ;
assertEquals ( MASTER , rc . getRef ( ) . getName ( ) ) ;
assertEquals ( MASTER , rc . getRef ( ) . getName ( ) ) ;
@ -484,7 +484,7 @@ public class ReftableTest {
try ( RefCursor rc = t . allRefs ( ) ) {
try ( RefCursor rc = t . allRefs ( ) ) {
assertFalse ( rc . next ( ) ) ;
assertFalse ( rc . next ( ) ) ;
}
}
try ( RefCursor rc = t . seekRef ( "refs/heads/" ) ) {
try ( RefCursor rc = t . seekPrefix ( "refs/heads/" ) ) {
assertFalse ( rc . next ( ) ) ;
assertFalse ( rc . next ( ) ) ;
}
}
try ( LogCursor lc = t . allLogs ( ) ) {
try ( LogCursor lc = t . allLogs ( ) ) {