Search Options

Results per page
Sort
Preferred Languages
Advance

Results 21 - 30 of 38 for testReadBytesWireFormat (0.1 sec)

  1. src/test/java/jcifs/internal/smb2/tree/Smb2TreeDisconnectRequestTest.java

            byte[] expected = new byte[] { 0x04, 0x00, 0x00, 0x00 };
            assertArrayEquals(expected, buffer);
        }
    
        @Test
        @DisplayName("Should always return 0 for readBytesWireFormat")
        void testReadBytesWireFormat() {
            // Given
            Configuration mockConfig = mock(Configuration.class);
            Smb2TreeDisconnectRequest request = new Smb2TreeDisconnectRequest(mockConfig);
            byte[] buffer = createTestData(256);
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 14.1K bytes
    - Viewed (0)
  2. src/test/java/jcifs/internal/smb2/nego/Smb2NegotiateRequestTest.java

            // Verify negotiate context offset/count area is zeroed
            assertEquals(0, SMBUtil.readInt8(buffer, 28));
        }
    
        @Test
        @DisplayName("Should read empty bytes from wire format")
        void testReadBytesWireFormat() {
            // Given
            request = new Smb2NegotiateRequest(mockConfig, 0);
            byte[] buffer = new byte[256];
    
            // When
            int bytesRead = request.readBytesWireFormat(buffer, 0);
    
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 20.7K bytes
    - Viewed (0)
  3. src/test/java/jcifs/internal/TreeConnectResponseTest.java

                assertEquals(0x001F01FF, access, "Should return maximal access value");
            }
    
            @Test
            @DisplayName("Should decode response from bytes correctly")
            void testReadBytesWireFormat() throws Exception {
                // Given - Prepare a valid SMB2 Tree Connect Response buffer
                byte[] buffer = new byte[16];
                // Structure size (16)
                buffer[0] = 0x10;
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 24.9K bytes
    - Viewed (0)
  4. src/test/java/jcifs/internal/smb2/Smb2EchoRequestTest.java

            }
        }
    
        @Nested
        @DisplayName("ReadBytesWireFormat Tests")
        class ReadBytesWireFormatTests {
    
            @Test
            @DisplayName("Should always return 0")
            void testReadBytesWireFormat() {
                byte[] buffer = new byte[100];
    
                int bytesRead = echoRequest.readBytesWireFormat(buffer, 0);
    
                assertEquals(0, bytesRead);
            }
    
            @Test
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 11.3K bytes
    - Viewed (0)
  5. src/test/java/jcifs/internal/smb1/com/SmbComTreeDisconnectTest.java

            }
        }
    
        /**
         * Test readBytesWireFormat returns 0
         */
        @Test
        @DisplayName("Test readBytesWireFormat always returns 0")
        public void testReadBytesWireFormat() {
            // Given
            smbComTreeDisconnect = new SmbComTreeDisconnect(config);
            byte[] buffer = new byte[100];
            int bufferIndex = 0;
    
            // When
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 18.5K bytes
    - Viewed (0)
  6. src/test/java/jcifs/internal/smb2/io/Smb2FlushRequestTest.java

                requestWithNull.writeBytesWireFormat(buffer, 0);
            });
        }
    
        @Test
        @DisplayName("readBytesWireFormat should return 0")
        void testReadBytesWireFormat() {
            byte[] buffer = new byte[256];
            int result = request.readBytesWireFormat(buffer, 0);
    
            assertEquals(0, result);
        }
    
        @ParameterizedTest
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 11.5K bytes
    - Viewed (0)
  7. src/test/java/jcifs/internal/smb2/info/Smb2QueryDirectoryRequestTest.java

            assertEquals(0, fnOffset);
            assertEquals(0, fnLength);
        }
    
        @Test
        @DisplayName("Test readBytesWireFormat returns 0")
        void testReadBytesWireFormat() {
            request = new Smb2QueryDirectoryRequest(mockConfig);
            byte[] buffer = new byte[100];
    
            int bytesRead = request.readBytesWireFormat(buffer, 0);
    
            assertEquals(0, bytesRead);
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 13.2K bytes
    - Viewed (0)
  8. src/test/java/jcifs/internal/smb1/com/SmbComQueryInformationResponseTest.java

            response.readParameterWordsWireFormat(buffer, 0);
    
            // 0xFFFFFFFF becomes -1 when interpreted as signed int
            assertEquals(-1L, response.getSize());
        }
    
        @Test
        void testReadBytesWireFormat() {
            // Test readBytesWireFormat - should always return 0
            response = new SmbComQueryInformationResponse(mockConfig, 0L);
    
            byte[] buffer = new byte[256];
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 11.9K bytes
    - Viewed (0)
  9. src/test/java/jcifs/internal/smb1/com/SmbComRenameTest.java

            assertEquals(0, result);
        }
    
        /**
         * Test readBytesWireFormat method
         */
        @Test
        @DisplayName("Test readBytesWireFormat always returns 0")
        public void testReadBytesWireFormat() {
            // Given
            byte[] buffer = new byte[10];
            smbComRename = new SmbComRename(config, "old.txt", "new.txt");
    
            // When
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 12.5K bytes
    - Viewed (0)
  10. src/test/java/jcifs/internal/smb2/info/Smb2SetInfoRequestTest.java

            // Verify total bytes written
            assertEquals(32 + infoSize, bytesWritten);
        }
    
        @Test
        @DisplayName("Test readBytesWireFormat returns 0")
        void testReadBytesWireFormat() {
            request = new Smb2SetInfoRequest(mockConfig);
            byte[] buffer = new byte[256];
    
            int bytesRead = request.readBytesWireFormat(buffer, 0);
    
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 13.9K bytes
    - Viewed (0)
Back to top