Skip to content

Commit e1bcf35

Browse files
committed
core: test: Switch SimpleLmTest to use Opaque instead of byte[] keys
This will change the test to use the new LockManager Opaque API. Related: #149 Signed-off-by: Christian Kohlschütter <[email protected]>
1 parent d3a5bce commit e1bcf35

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

core/src/test/java/org/dcache/nfs/v4/nlm/SimpleLmTest.java

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22

33
import java.nio.charset.StandardCharsets;
44

5+
import org.dcache.nfs.util.Opaque;
56
import org.dcache.nfs.v4.StateOwner;
67
import org.dcache.nfs.v4.xdr.clientid4;
78
import org.dcache.nfs.v4.xdr.nfs4_prot;
@@ -16,14 +17,14 @@
1617
public class SimpleLmTest {
1718

1819
private LockManager nlm;
19-
private byte[] file1;
20-
private byte[] file2;
20+
private Opaque file1;
21+
private Opaque file2;
2122

2223
@Before
2324
public void setUp() throws Exception {
2425
nlm = new SimpleLm();
25-
file1 = "file1".getBytes(StandardCharsets.UTF_8);
26-
file2 = "file2".getBytes(StandardCharsets.UTF_8);
26+
file1 = Opaque.forBytes("file1".getBytes(StandardCharsets.UTF_8));
27+
file2 = Opaque.forBytes("file2".getBytes(StandardCharsets.UTF_8));
2728
}
2829

2930
@Test

0 commit comments

Comments
 (0)