test for bytesref stubstring function