Search Options

Results per page
Sort
Preferred Languages
Advance

Results 281 - 290 of 2,189 for whet (0.01 sec)

  1. src/test/java/jcifs/dcerpc/ndr/NdrObjectTest.java

         */
        @Test
        void testDecode() throws NdrException {
            // When
            ndrObject.decode(mockBuffer);
    
            // Then
            // Verify that our mock buffer had the expected method called.
            verify(mockBuffer).dec_ndr_long();
        }
    
        /**
         * Test case for the encode method when it throws an NdrException.
         * Verifies that the exception is correctly propagated.
         */
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 3.4K bytes
    - Viewed (0)
  2. src/test/java/jcifs/dcerpc/msrpc/samrTest.java

                samr.SamrSamEntry entry = new samr.SamrSamEntry();
                when(mockNdrBuffer.dec_ndr_long()).thenReturn(1, 100); // idx, _name_bufferp
                when(mockNdrBuffer.dec_ndr_short()).thenReturn(4, 6); // length, maximum_length
                when(mockDeferredBuffer.dec_ndr_long()).thenReturn(3, 0, 2); // _name_buffers, 0, _name_bufferl
                when(mockDeferredBuffer.dec_ndr_short()).thenReturn((int) (short) 't', (int) (short) 'e');
    
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 33.7K bytes
    - Viewed (0)
  3. src/test/java/jcifs/dcerpc/msrpc/lsarpcTest.java

            lenient().when(mockNdrBuffer.derive(anyInt())).thenReturn(mockDeferredNdrBuffer);
            lenient().when(mockDeferredNdrBuffer.derive(anyInt())).thenReturn(mockDeferredNdrBuffer);
    
            // Set up lenient stubs for common operations to avoid unnecessary stubbing exceptions
            lenient().when(mockNdrBuffer.getIndex()).thenReturn(0);
            lenient().when(mockDeferredNdrBuffer.getIndex()).thenReturn(0);
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 60.8K bytes
    - Viewed (0)
  4. src/test/java/jcifs/util/transport/ResponseTest.java

            // Simulate granted credits
            when(mockResponse.getGrantedCredits()).thenReturn(100);
            assertEquals(100, mockResponse.getGrantedCredits());
    
            // Verify the method was called
            verify(mockResponse, times(1)).getGrantedCredits();
        }
    
        @Test
        void testGetErrorCode() {
            // Simulate error code
            when(mockResponse.getErrorCode()).thenReturn(-1);
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 6.5K bytes
    - Viewed (0)
  5. src/test/java/jcifs/internal/smb2/tree/Smb2TreeConnectResponseTest.java

        }
    
        @Test
        @DisplayName("Should return null for getService")
        void testGetService() {
            // When
            String service = response.getService();
    
            // Then
            assertNull(service);
        }
    
        @Test
        @DisplayName("Should prepare next request correctly when received")
        void testPrepareWhenReceived() throws Exception {
            // Given
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 07:14:38 UTC 2025
    - 19.3K bytes
    - Viewed (0)
  6. src/test/java/jcifs/smb/SmbTreeHandleImplTest.java

            when(ctx.getConfig()).thenReturn(config);
            when(config.getCapabilities()).thenReturn(0);
            when(config.getFlags2()).thenReturn(0);
            when(config.getMaxMpxCount()).thenReturn(1);
            when(config.getSendBufferSize()).thenReturn(4096);
            when(config.getReceiveBufferSize()).thenReturn(4096);
            when(config.getTransactionBufferSize()).thenReturn(4096);
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 14.4K bytes
    - Viewed (0)
  7. src/test/java/jcifs/smb/SmbFileHandleImplTest.java

        SmbTreeHandleImpl tree;
    
        private void stubValidTree(long treeId, boolean connected, boolean smb2) {
            lenient().when(tree.acquire()).thenReturn(tree);
            lenient().when(tree.getTreeId()).thenReturn(treeId);
            lenient().when(tree.isConnected()).thenReturn(connected);
            lenient().when(tree.isSMB2()).thenReturn(smb2);
        }
    
        @Test
        @DisplayName("Constructor with null tree throws NPE (byte[] fid variant)")
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 12.3K bytes
    - Viewed (0)
  8. src/test/java/jcifs/smb/DosFileFilterTest.java

            when(mockFile.getAttributes()).thenReturn(SmbFile.ATTR_READONLY | SmbFile.ATTR_HIDDEN | SmbFile.ATTR_SYSTEM);
    
            // When calling accept
            // Then it should be accepted because the READONLY attribute is present
            assertTrue(dosFileFilter.accept(mockFile));
        }
    
        /**
         * Tests that the accept method returns false when the file attributes do not
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 6.2K bytes
    - Viewed (0)
  9. src/test/java/jcifs/internal/dfs/DfsReferralDataImplTest.java

            @Test
            @DisplayName("Should use special name when no expanded names")
            void testFromReferralWithSpecialName() {
                when(mockReferral.getTtl()).thenReturn(300);
                when(mockReferral.getRFlags()).thenReturn(Trans2GetDfsReferralResponse.FLAGS_NAME_LIST_REFERRAL);
                when(mockReferral.getExpandedNames()).thenReturn(new String[0]);
                when(mockReferral.getSpecialName()).thenReturn("\\SPECIAL");
    
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 30.6K bytes
    - Viewed (0)
  10. src/test/java/jcifs/smb/DirFileEntryEnumIterator2Test.java

            // Setup required for this test
            when(parent.getLocator()).thenReturn(locator);
            when(locator.getUNCPath()).thenReturn("\\\\server\\share\\dir\\");
            when(tree.getConfig()).thenReturn(config);
            when(config.getMaximumBufferSize()).thenReturn(65535);
            when(config.getListSize()).thenReturn(65535);
    
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 13.7K bytes
    - Viewed (0)
Back to top