Search Options

Results per page
Sort
Preferred Languages
Advance

Results 31 - 40 of 99 for openMocks (0.06 sec)

  1. src/test/java/jcifs/tests/persistent/PersistentHandleManagerTest.java

        private jcifs.Configuration mockConfig;
    
        private PersistentHandleManager manager;
        private Path tempDir;
    
        @BeforeEach
        public void setUp() throws IOException {
            MockitoAnnotations.openMocks(this);
    
            // Create temporary directory for test state
            tempDir = Files.createTempDirectory("jcifs-test-handles");
    
            // Set system property for handle state directory
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 21 04:51:33 UTC 2025
    - 6.6K bytes
    - Viewed (0)
  2. src/test/java/jcifs/dcerpc/msrpc/LsaPolicyHandleTest.java

        // For now, let's assume we can mock their behavior through the sendrecv method of DcerpcHandle.
    
        @BeforeEach
        void setUp() {
            // MockitoAnnotations.openMocks(this); // Not needed with @ExtendWith(MockitoExtension.class)
        }
    
        @Test
        void constructor_shouldOpenPolicySuccessfully() throws IOException {
            // Arrange
            String server = "testServer";
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 8.9K bytes
    - Viewed (0)
  3. src/test/java/jcifs/internal/smb1/trans/TransWaitNamedPipeTest.java

        private Configuration mockConfig;
    
        private TransWaitNamedPipe transWaitNamedPipe;
        private String testPipeName = "\\PIPE\\testpipe";
    
        @BeforeEach
        void setUp() {
            MockitoAnnotations.openMocks(this);
        }
    
        @Test
        @DisplayName("Constructor should initialize with correct values")
        void testConstructor() {
            // Act
            transWaitNamedPipe = new TransWaitNamedPipe(mockConfig, testPipeName);
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 8.8K bytes
    - Viewed (0)
  4. src/test/java/jcifs/internal/smb1/trans2/Trans2GetDfsReferralResponseTest.java

    class Trans2GetDfsReferralResponseTest {
    
        @Mock
        private Configuration mockConfig;
    
        private Trans2GetDfsReferralResponse response;
    
        @BeforeEach
        void setUp() {
            MockitoAnnotations.openMocks(this);
            response = new Trans2GetDfsReferralResponse(mockConfig);
        }
    
        @Nested
        @DisplayName("Constructor and Initialization Tests")
        class ConstructorTests {
    
            @Test
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 19.4K bytes
    - Viewed (0)
  5. src/test/java/jcifs/internal/smb1/trans/TransCallNamedPipeResponseTest.java

        @Mock
        private Configuration mockConfig;
    
        private TransCallNamedPipeResponse response;
        private byte[] outputBuffer;
    
        @BeforeEach
        void setUp() {
            MockitoAnnotations.openMocks(this);
            outputBuffer = new byte[1024];
            response = new TransCallNamedPipeResponse(mockConfig, outputBuffer);
        }
    
        @Test
        void testConstructor() {
            assertNotNull(response);
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 8.8K bytes
    - Viewed (0)
  6. src/test/java/jcifs/smb/SmbTreeImplTest.java

        @Mock
        private CIFSContext context;
    
        @Mock
        private SmbTransportImpl transport;
    
        @BeforeEach
        void setUp() throws Exception {
            MockitoAnnotations.openMocks(this);
            when(session.getConfig()).thenReturn(config);
            when(session.getContext()).thenReturn(context);
            when(session.getTransport()).thenReturn(transport);
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 7.8K bytes
    - Viewed (0)
  7. src/test/java/jcifs/internal/smb1/trans/SmbComTransactionTest.java

            }
    
            void setDataBuffer(byte[] buffer) {
                this.dataBuffer = buffer;
            }
        }
    
        @BeforeEach
        void setUp() {
            MockitoAnnotations.openMocks(this);
            when(mockConfig.getTransactionBufferSize()).thenReturn(65535);
            when(mockConfig.getOemEncoding()).thenReturn("ASCII");
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 10.7K bytes
    - Viewed (0)
  8. src/test/java/jcifs/internal/smb1/trans/nt/NtTransNotifyChangeTest.java

        private static final int FILE_NOTIFY_CHANGE_STREAM_WRITE = 0x00000800;
        private static final int FILE_NOTIFY_CHANGE_ALL = 0x00000FFF;
    
        @BeforeEach
        void setUp() {
            MockitoAnnotations.openMocks(this);
            when(mockConfig.getNotifyBufferSize()).thenReturn(4096);
            when(mockConfig.getTransactionBufferSize()).thenReturn(65535);
        }
    
        @Test
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 18.4K bytes
    - Viewed (0)
  9. src/test/java/jcifs/internal/smb2/rdma/RdmaBufferManagerTest.java

        private RdmaProvider mockProvider;
    
        private RdmaBufferManager bufferManager;
        private AutoCloseable mocks;
    
        @BeforeEach
        public void setUp() throws Exception {
            mocks = MockitoAnnotations.openMocks(this);
    
            // Set up mock provider to return TCP memory regions
            when(mockProvider.registerMemory(any(ByteBuffer.class), any())).thenAnswer(invocation -> {
                ByteBuffer buffer = invocation.getArgument(0);
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Sat Aug 23 05:11:12 UTC 2025
    - 7.1K bytes
    - Viewed (0)
  10. src/test/java/jcifs/internal/smb1/trans/TransTransactNamedPipeTest.java

        private static final int TEST_OFFSET = 0;
        private static final int TEST_LENGTH = TEST_DATA.length;
    
        @BeforeEach
        void setUp() {
            MockitoAnnotations.openMocks(this);
        }
    
        @Test
        @DisplayName("Test constructor initializes fields correctly")
        void testConstructor() {
            // Act
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 9.7K bytes
    - Viewed (0)
Back to top