- Sort Score
- Result 10 results
- Languages All
Results 11 - 20 of 62 for anySet (0.04 sec)
-
src/test/java/jcifs/netbios/SessionServicePacketTest.java
} @Test @DisplayName("readn should handle multiple read calls") void testReadnMultipleCalls() throws IOException { when(mockInputStream.read(any(byte[].class), anyInt(), anyInt())).thenReturn(2) // First read returns 2 bytes .thenReturn(2) // Second read returns 2 bytes .thenReturn(1); // Third read returns 1 byte byte[] buffer = new byte[10];
Registered: Sun Sep 07 00:10:21 UTC 2025 - Last Modified: Thu Aug 14 05:31:44 UTC 2025 - 15.5K bytes - Viewed (0) -
src/test/java/jcifs/smb/SmbPipeHandleInternalTest.java
when(tree.acquire()).thenReturn(tree); // Setup for ensureOpen when(tree.isSMB2()).thenReturn(true); when(pipe.openUnshared(anyString(), anyInt(), anyInt(), anyInt(), anyInt(), anyInt())).thenReturn(fh); when(fh.acquire()).thenReturn(fh); lenient().when(fh.isValid()).thenReturn(true); lenient().when(fh.getTree()).thenReturn(tree);
Registered: Sun Sep 07 00:10:21 UTC 2025 - Last Modified: Thu Aug 14 07:14:38 UTC 2025 - 16.7K bytes - Viewed (0) -
src/test/java/jcifs/smb/SmbRandomAccessFileTest.java
when(tree.getSendBufferSize()).thenReturn(1024); when(tree.hasCapability(anyInt())).thenAnswer(inv -> ntSmbsCap && inv.getArgument(0).equals(SmbConstants.CAP_NT_SMBS)); when(tree.areSignaturesActive()).thenReturn(false); when(tree.isSMB2()).thenReturn(smb2); when(file.openUnshared(anyInt(), anyInt(), anyInt(), anyInt(), anyInt())).thenReturn(fh); when(fh.acquire()).thenReturn(fh);
Registered: Sun Sep 07 00:10:21 UTC 2025 - Last Modified: Thu Aug 14 05:31:44 UTC 2025 - 18.1K bytes - Viewed (0) -
src/test/java/jcifs/smb/SmbFileTest.java
doReturn(mockTreeHandle).when(smbFile).ensureTreeConnected(); when(mockTreeHandle.getConfig()).thenReturn(mockConfig); doReturn(mockFileHandle).when(smbFile).openUnshared(anyInt(), anyInt(), anyInt(), anyInt(), anyInt()); } @Test void testGetInputStream() throws IOException { // Act var inputStream = smbFile.getInputStream(); // Assert
Registered: Sun Sep 07 00:10:21 UTC 2025 - Last Modified: Thu Aug 14 05:31:44 UTC 2025 - 20.8K bytes - Viewed (0) -
src/test/java/jcifs/internal/smb2/create/CreateContextResponseTest.java
CreateContextResponse response = mock(CreateContextResponse.class); byte[] buffer = new byte[100]; when(response.decode(any(byte[].class), anyInt(), anyInt())).thenReturn(10); int result = response.decode(buffer, 0, 10); assertEquals(10, result); verify(response, times(1)).decode(buffer, 0, 10); } @Test
Registered: Sun Sep 07 00:10:21 UTC 2025 - Last Modified: Thu Aug 14 05:31:44 UTC 2025 - 16.2K bytes - Viewed (0) -
src/test/java/jcifs/internal/AllocInfoTest.java
void shouldHandleMockedDecodeMethod() throws jcifs.internal.SMBProtocolDecodingException { // Given byte[] buffer = new byte[100]; when(mockAllocInfo.decode(any(byte[].class), anyInt(), anyInt())).thenReturn(42); // When int result = mockAllocInfo.decode(buffer, 10, 50); // Then assertEquals(42, result);
Registered: Sun Sep 07 00:10:21 UTC 2025 - Last Modified: Thu Aug 14 05:31:44 UTC 2025 - 18.8K bytes - Viewed (0) -
src/test/java/jcifs/internal/smb2/lease/DirectoryLeaseManagerTest.java
import static org.junit.jupiter.api.Assertions.assertNotNull; import static org.junit.jupiter.api.Assertions.assertNull; import static org.junit.jupiter.api.Assertions.assertTrue; import static org.mockito.ArgumentMatchers.anyInt; import static org.mockito.ArgumentMatchers.anyString; import static org.mockito.Mockito.mock; import static org.mockito.Mockito.verify; import static org.mockito.Mockito.when; import java.io.IOException;
Registered: Sun Sep 07 00:10:21 UTC 2025 - Last Modified: Sat Aug 23 01:47:47 UTC 2025 - 15.9K bytes - Viewed (0) -
src/test/java/jcifs/internal/smb2/ioctl/Smb2IoctlRequestTest.java
when(mockInputData.encode(any(byte[].class), anyInt())).thenReturn(100); request.setInputData(mockInputData); byte[] buffer = new byte[1024]; int written = request.writeBytesWireFormat(buffer, 0); assertTrue(written > 57); verify(mockInputData).encode(any(byte[].class), anyInt()); } @Test
Registered: Sun Sep 07 00:10:21 UTC 2025 - Last Modified: Thu Aug 14 05:31:44 UTC 2025 - 14.3K bytes - Viewed (0) -
src/test/java/jcifs/dcerpc/DcerpcMessageTest.java
lenient().doNothing().when(mockBuffer).advance(anyInt()); lenient().doNothing().when(mockBuffer).enc_ndr_long(anyInt()); lenient().doNothing().when(mockBuffer).enc_ndr_short(anyInt()); lenient().doNothing().when(mockBuffer).enc_ndr_small(anyInt()); lenient().doNothing().when(mockBuffer).setIndex(anyInt()); message.encode(mockBuffer);
Registered: Sun Sep 07 00:10:21 UTC 2025 - Last Modified: Thu Aug 14 07:14:38 UTC 2025 - 18.3K bytes - Viewed (0) -
src/test/java/jcifs/smb/DfsImplTest.java
import static org.junit.jupiter.api.Assertions.assertNull; import static org.mockito.ArgumentMatchers.any; import static org.mockito.ArgumentMatchers.anyBoolean; import static org.mockito.ArgumentMatchers.anyInt; import static org.mockito.ArgumentMatchers.anyString; import static org.mockito.Mockito.mock; import static org.mockito.Mockito.when; import java.io.IOException; import org.junit.jupiter.api.BeforeEach;
Registered: Sun Sep 07 00:10:21 UTC 2025 - Last Modified: Thu Aug 14 05:31:44 UTC 2025 - 5.5K bytes - Viewed (0)