Search Options

Results per page
Sort
Preferred Languages
Advance

Results 91 - 100 of 2,385 for When (0.02 sec)

  1. src/test/java/jcifs/EmptyIteratorTest.java

        void testNextReturnsNull() {
            // When
            SmbResource result = emptyIterator.next();
    
            // Then
            assertNull(result, "next() should return null for empty iterator");
        }
    
        @Test
        @DisplayName("next should not throw NoSuchElementException")
        void testNextDoesNotThrowException() {
            // When & Then
            assertDoesNotThrow(() -> {
                emptyIterator.next();
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 12K bytes
    - Viewed (0)
  2. src/test/java/jcifs/internal/smb1/SMB1SigningDigestTest.java

            when(readResponse.getFlags2()).thenReturn(SmbConstants.FLAGS2_SECURITY_SIGNATURES);
            when(readResponse.getSignSeq()).thenReturn(10);
            when(readResponse.getCommand()).thenReturn((int) ServerMessageBlock.SMB_COM_READ_ANDX);
            when(readResponse.getLength()).thenReturn(100);
            when(readResponse.getDataLength()).thenReturn(50);
            when(readResponse.getData()).thenReturn(readData);
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 18.1K bytes
    - Viewed (0)
  3. src/test/java/jcifs/internal/fscc/FileFsFullSizeInformationTest.java

                buffer.putInt(512); // Bytes per sector
                byte[] bufferArray = buffer.array();
    
                // When
                int bytesConsumed = fileFsFullSizeInfo.decode(bufferArray, 0, bufferArray.length);
    
                // Then
                assertEquals(32, bytesConsumed);
                assertEquals(1048576L * 8 * 512, fileFsFullSizeInfo.getCapacity());
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 30.5K bytes
    - Viewed (0)
  4. src/test/java/jcifs/internal/dfs/DfsReferralDataInternalTest.java

            DfsReferralData mockData = mock(DfsReferralData.class);
            when(mockData.getServer()).thenReturn("SERVER");
            when(mockData.getShare()).thenReturn("share");
            when(mockData.getPath()).thenReturn("path");
            when(mockData.getExpiration()).thenReturn(System.currentTimeMillis() + 60000);
            when(mockData.getPathConsumed()).thenReturn(0);
            when(mockData.getDomain()).thenReturn("DOMAIN");
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 28.2K bytes
    - Viewed (0)
  5. src/test/java/jcifs/internal/smb1/com/SmbComCloseTest.java

            context = mock(CIFSContext.class);
            when(context.getConfig()).thenReturn(config);
        }
    
        /**
         * Test method for {@link jcifs.internal.smb1.com.SmbComClose#SmbComClose(jcifs.Configuration, int, long)}.
         */
        @Test
        public void testConstructor() {
            // Given
            int fid = 123;
            long lastWriteTime = System.currentTimeMillis();
    
            // When
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 6.4K bytes
    - Viewed (0)
  6. src/test/java/jcifs/internal/smb2/ioctl/SrvCopychunkTest.java

                // Given
                long sourceOffset = 1024L;
                long targetOffset = 2048L;
                int length = 4096;
    
                // When
                SrvCopychunk chunk = new SrvCopychunk(sourceOffset, targetOffset, length);
    
                // Then
                assertNotNull(chunk);
            }
    
            @ParameterizedTest
            @DisplayName("Should create instance with various offset values")
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 12.4K bytes
    - Viewed (0)
  7. src/test/java/jcifs/smb/DirFileEntryEnumIterator1Test.java

            lenient().when(tree.acquire()).thenReturn(tree);
            lenient().when(tree.getConfig()).thenReturn(config);
            lenient().when(config.getListCount()).thenReturn(10);
            lenient().when(config.getListSize()).thenReturn(4096);
    
            lenient().when(parent.getLocator()).thenReturn(locator);
            lenient().when(locator.getUNCPath()).thenReturn("\\\\SERVER\\Share\\dir\\"); // ends with \\
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 12.7K bytes
    - Viewed (0)
  8. src/test/java/jcifs/smb/DfsImplTest.java

            // Set up mock behaviors
            when(mockContext.getConfig()).thenReturn(mockConfig);
            when(mockContext.getCredentials()).thenReturn(mockCredentials);
            when(mockContext.getTransportPool()).thenReturn(mockTransportPool);
            when(mockConfig.getDfsTtl()).thenReturn(300L);
    
            // Mock transport to throw IOException - simulating connection failure
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 5.5K bytes
    - Viewed (0)
  9. src/test/java/jcifs/internal/RequestTest.java

            // Given
            when(request.isResponseAsync()).thenReturn(true);
            when(request.getNext()).thenReturn(nextRequest);
            when(request.split()).thenReturn(nextRequest);
            when(request.allowChain(nextRequest)).thenReturn(true);
            when(request.createCancel()).thenReturn(nextRequest);
            when(request.size()).thenReturn(1024);
            when(request.getOverrideTimeout()).thenReturn(5000);
    
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 14.5K bytes
    - Viewed (0)
  10. src/test/java/jcifs/CredentialsTest.java

            // Given
            when(mockCredentials.isAnonymous()).thenReturn(true);
    
            // When
            boolean isAnonymous = mockCredentials.isAnonymous();
    
            // Then
            assertTrue(isAnonymous);
            verify(mockCredentials).isAnonymous();
        }
    
        @Test
        @DisplayName("Should check for guest credentials")
        void testIsGuest() {
            // Given
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 2.5K bytes
    - Viewed (0)
Back to top