Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 6 of 6 for testBoundaryConditions (0.07 sec)

  1. src/test/java/jcifs/internal/util/SMBUtilTest.java

                // Account for precision loss (milliseconds to seconds conversion)
                assertEquals((time / 1000L) * 1000L, readTime);
            }
        }
    
        @Test
        void testBoundaryConditions() {
            byte[] buffer = new byte[16];
    
            // Test edge of array
            SMBUtil.writeInt2(0xFFFF, buffer, 14);
            assertEquals(0xFFFF, SMBUtil.readInt2(buffer, 14));
    
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 11.1K bytes
    - Viewed (0)
  2. src/test/java/jcifs/internal/smb1/trans2/Trans2SetFileInformationResponseTest.java

            result = response.readDataWireFormat(null, 0, 0);
            assertEquals(0, result);
        }
    
        @Test
        @DisplayName("Test boundary conditions for buffer offsets")
        void testBoundaryConditions() {
            byte[] smallBuffer = new byte[10];
    
            // Test with maximum offset
            int result = response.writeSetupWireFormat(smallBuffer, Integer.MAX_VALUE);
            assertEquals(0, result);
    
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 15.9K bytes
    - Viewed (0)
  3. src/test/java/jcifs/internal/smb2/create/CreateContextResponseTest.java

                assertNotNull(response.getName());
                assertEquals(0, response.getName().length);
            }
    
            @Test
            @DisplayName("Should handle boundary conditions in decode")
            void testBoundaryConditions() throws SMBProtocolDecodingException {
                byte[] buffer = new byte[100];
                TestCreateContextResponse response = new TestCreateContextResponse("BOUNDARY".getBytes(StandardCharsets.UTF_8));
    
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 16.2K bytes
    - Viewed (0)
  4. src/test/java/jcifs/internal/smb1/com/SmbComTreeDisconnectTest.java

            }
        }
    
        /**
         * Test boundary conditions for buffer indices
         */
        @Test
        @DisplayName("Test boundary conditions for buffer indices")
        public void testBoundaryConditions() {
            // Given
            smbComTreeDisconnect = new SmbComTreeDisconnect(config);
            byte[] buffer = new byte[100];
    
            // When & Then - test with maximum valid index
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 18.5K bytes
    - Viewed (0)
  5. src/test/java/jcifs/internal/smb2/create/CreateContextRequestTest.java

                assertNotNull(request.getData());
                assertEquals(0, request.getData().length);
            }
    
            @Test
            @DisplayName("Should handle boundary conditions in encode")
            void testBoundaryConditions() {
                byte[] buffer = new byte[256];
                byte[] name = "BOUNDARY".getBytes(StandardCharsets.UTF_8);
                TestCreateContextRequest request = new TestCreateContextRequest(name);
    
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 24.9K bytes
    - Viewed (0)
  6. src/test/java/jcifs/internal/smb2/io/Smb2WriteRequestTest.java

                assertEquals(Smb2Constants.SMB2_HEADER_LENGTH + 48, Smb2WriteRequest.OVERHEAD);
            }
    
            @Test
            @DisplayName("Should handle boundary conditions")
            void testBoundaryConditions() {
                // Test with exactly aligned data
                request.setData(new byte[8], 0, 8); // 8-byte aligned
                assertEquals(((Smb2Constants.SMB2_HEADER_LENGTH + 48 + 8 + 7) / 8) * 8, request.size());
    
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 22.4K bytes
    - Viewed (0)
Back to top