Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 26 for parameterized (0.17 sec)

  1. src/test/java/jcifs/internal/fscc/FileEndOfFileInformationTest.java

            // Verify instance is created
            assertNotNull(fileInfo);
            assertEquals(FileInformation.FILE_ENDOFFILE_INFO, fileInfo.getFileInformationLevel());
        }
    
        @Test
        @DisplayName("Test parameterized constructor with end of file value")
        void testParameterizedConstructor() {
            // Test with specific end of file value
            long endOfFile = 1024L;
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 9.9K bytes
    - Viewed (0)
  2. src/test/java/jcifs/smb/FileEntryTest.java

                return length;
            }
    
            @Override
            public int getFileIndex() {
                return fileIndex;
            }
        }
    
        // Functional helpers for concise parameterized tests
        private interface IntGetter {
            int apply(FileEntry e);
        }
    
        private interface LongGetter {
            long apply(FileEntry e);
        }
    
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 10K bytes
    - Viewed (0)
  3. src/test/java/jcifs/smb1/smb1/FileEntryTest.java

                assertEquals(-10L, mock.length());
            }
        }
    
        @ParameterizedTest(name = "getType returns {0}")
        @ValueSource(ints = { 0, 1, -5, Integer.MAX_VALUE })
        @DisplayName("Parameterized type values")
        void typeParameterized(int type) {
            FileEntry mock = mock(FileEntry.class);
            when(mock.getType()).thenReturn(type);
            assertEquals(type, mock.getType());
        }
    
        @Test
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 3K bytes
    - Viewed (0)
  4. src/test/java/jcifs/smb/BufferCacheImplTest.java

            assertEquals(3, third.length, "Allocated buffer length matches configured maximum size");
        }
    
        // Parameterized: exercise small variations of cache size for a simple reuse cycle
        @ParameterizedTest
        @ValueSource(ints = { 1, 2 })
        @DisplayName("Parameterized: buffer reuse works for various small cache sizes")
        void reuseWorksForVariousCacheSizes(int cacheSize) {
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 7.5K bytes
    - Viewed (0)
  5. src/test/java/jcifs/smb/SMBProtocolDowngradeExceptionTest.java

     */
    @ExtendWith(MockitoExtension.class)
    class SMBProtocolDowngradeExceptionTest {
    
        /**
         * Provides messages including edge cases (null and empty) for parameterized testing.
         */
        static Stream<Arguments> messages() {
            return Stream.of(Arguments.of((String) null), Arguments.of(""), Arguments.of("unexpected downgrade"));
        }
    
        @Test
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 5.4K bytes
    - Viewed (0)
  6. src/test/java/jcifs/spnego/NegTokenInitTest.java

        private static final String SPNEGO_OID_STR = SpnegoConstants.SPNEGO_MECHANISM;
    
        // Helper to build a SPNEGO NegTokenInit as per NegTokenInit#toByteArray but parameterized for tests
        private static byte[] buildInitToken(ASN1ObjectIdentifier[] mechs, Integer flags, byte[] mechToken, byte[] mic, boolean micInTag4,
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 21K bytes
    - Viewed (0)
  7. src/test/java/jcifs/netbios/NbtExceptionTest.java

                    "The error string should match the expected message for given error class and code");
        }
    
        /**
         * Provides arguments for the testGetErrorString parameterized test.
         * Covers all defined error classes and codes, including default cases.
         */
        private static Stream<Arguments> provideErrorClassAndCodeForGetErrorString() {
            return Stream.of(
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 5.9K bytes
    - Viewed (0)
  8. src/test/java/jcifs/smb/DosFileFilterTest.java

            new DosFileFilter("*.*", SmbFile.ATTR_ARCHIVE);
            new DosFileFilter("?", SmbFile.ATTR_DIRECTORY);
            new DosFileFilter("file.txt", SmbFile.ATTR_READONLY | SmbFile.ATTR_HIDDEN);
        }
    
        /**
         * Parameterized test for the {@link DosFileFilter#accept(SmbFile)} method.
         * This test covers various combinations of file attributes and filter attributes
         * to ensure the bitwise logic is correctly implemented.
         *
    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/smb/SmbWatchHandleImplTest.java

            assertTrue(result.isEmpty(), "List should be cleared");
        }
    
        // Parameterized test to exercise SMB2 with different recursive and filter values
        @ParameterizedTest(name = "SMB2 param: recursive={0}, filter={1}")
        @CsvSource({ "true, 0", "false, -1" })
        @DisplayName("watch() SMB2 parameterized branches execute without error")
        void watch_smb2_parameterized(boolean recursive, int filter) throws Exception {
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 11.5K bytes
    - Viewed (0)
  10. guava/src/com/google/common/reflect/Types.java

            return subtypeOf(newArrayType(upperBounds[0]));
          }
        }
        return JavaVersion.CURRENT.newArrayType(componentType);
      }
    
      /**
       * Returns a type where {@code rawType} is parameterized by {@code arguments} and is owned by
       * {@code ownerType}.
       */
      static ParameterizedType newParameterizedTypeWithOwner(
          @Nullable Type ownerType, Class<?> rawType, Type... arguments) {
    Registered: Fri Sep 05 12:43:10 UTC 2025
    - Last Modified: Wed Sep 03 14:03:14 UTC 2025
    - 23.5K bytes
    - Viewed (0)
Back to top