use of com.orientechnologies.orient.client.binary.OChannelBinaryAsynchClient in project orientdb by orientechnologies.
the class OStorageRemoteAsyncOperationTest method testNoReadCall.
@Test
public void testNoReadCall() {
final CallStatus status = new CallStatus();
storage.asyncNetworkOperation(new OStorageRemoteOperationWrite() {
@Override
public void execute(OChannelBinaryAsynchClient network, OStorageRemoteSession session, int mode) throws IOException {
assertNull(status.status);
status.status = "write";
}
}, new OStorageRemoteOperationRead<Object>() {
@Override
public Object execute(OChannelBinaryAsynchClient network, OStorageRemoteSession session) throws IOException {
fail();
return null;
}
}, 1, new ORecordId(-1, -1), null, "");
assertEquals(status.status, "write");
}
Aggregations