- Sort Score
- Result 10 results
- Languages All
Results 31 - 40 of 202 for throwing (2.74 sec)
-
src/test/java/jcifs/internal/AllocInfoTest.java
// Then assertEquals(42, result); verify(mockAllocInfo, times(1)).decode(buffer, 10, 50); } @Test @DisplayName("Should handle decode method throwing exception") void shouldHandleDecodeMethodThrowingException() throws jcifs.internal.SMBProtocolDecodingException { // Given byte[] buffer = new byte[100];Registered: Sat Dec 20 13:44:44 UTC 2025 - Last Modified: Thu Aug 14 05:31:44 UTC 2025 - 18.8K bytes - Viewed (0) -
src/test/java/jcifs/smb/SIDCacheImplTest.java
import jcifs.dcerpc.UnicodeString; import jcifs.dcerpc.msrpc.LsaPolicyHandle; import jcifs.dcerpc.msrpc.lsarpc; @ExtendWith(MockitoExtension.class) class SIDCacheImplTest { // Helper to create a SID from text without throwing in the test body private static SID sid(String textual) { try { return new SID(textual); } catch (SmbException e) { throw new RuntimeException(e); } }Registered: Sat Dec 20 13:44:44 UTC 2025 - Last Modified: Thu Aug 14 05:31:44 UTC 2025 - 14K bytes - Viewed (0) -
fess-crawler/src/test/java/org/codelibs/fess/crawler/exception/CrawlerSystemExceptionTest.java
assertEquals(original.getCause().getMessage(), deserialized.getCause().getMessage()); assertEquals(original.getCause().getClass(), deserialized.getCause().getClass()); } /** * Test throwing and catching the exception */ public void test_throwAndCatch() { try { throw new CrawlerSystemException("Test throw"); } catch (CrawlerSystemException e) {
Registered: Sat Dec 20 11:21:39 UTC 2025 - Last Modified: Wed Sep 03 14:42:53 UTC 2025 - 20K bytes - Viewed (0) -
src/main/java/jcifs/internal/smb2/Smb2EncryptionContext.java
log.error("Automatic key rotation failed", e); throw new CIFSException("Automatic key rotation failed", e); } } else { // Fall back to throwing exception if no session key is available totalKeyRotations.incrementAndGet(); lastKeyRotationTime.set(System.currentTimeMillis());
Registered: Sat Dec 20 13:44:44 UTC 2025 - Last Modified: Sun Aug 31 08:00:57 UTC 2025 - 35.5K bytes - Viewed (0) -
src/test/java/jcifs/context/CIFSContextWrapperTest.java
// Test get(String url) with a malformed URL String malformedUrl = "invalid-url"; CIFSException thrown = assertThrows(CIFSException.class, () -> { cifsContextWrapper.get(malformedUrl); }); assertTrue(thrown.getMessage().contains("Invalid URL")); assertTrue(thrown.getCause() instanceof MalformedURLException); } @Test
Registered: Sat Dec 20 13:44:44 UTC 2025 - Last Modified: Thu Aug 14 05:31:44 UTC 2025 - 10.7K bytes - Viewed (0) -
src/test/java/jcifs/pac/PacUnicodeStringTest.java
String testString = "not-null"; // Expect a PACDecodingException to be thrown PACDecodingException exception = assertThrows(PACDecodingException.class, () -> { pacString.check(testString); }, "A PACDecodingException should be thrown for a non-empty string with a zero pointer."); // Verify the exception messageRegistered: Sat Dec 20 13:44:44 UTC 2025 - Last Modified: Thu Aug 14 05:31:44 UTC 2025 - 5.7K bytes - Viewed (0) -
src/test/java/jcifs/netbios/SessionRetargetResponsePacketTest.java
byte[] buffer = new byte[6]; // Assert that an IOException is thrown with the expected message. IOException thrown = assertThrows(IOException.class, () -> { packet.readTrailerWireFormat(mockInputStream, buffer, 0); }); assertTrue(thrown.getMessage().contains("unexpected EOF reading netbios retarget session response")); }
Registered: Sat Dec 20 13:44:44 UTC 2025 - Last Modified: Thu Aug 14 05:31:44 UTC 2025 - 3K bytes - Viewed (0) -
src/test/java/jcifs/smb/SmbUnsupportedOperationExceptionTest.java
// Act & Assert: the exception is propagated and interaction recorded once RuntimeException thrown = assertThrows(RuntimeException.class, supplier::get); assertInstanceOf(SmbUnsupportedOperationException.class, thrown.getCause()); assertEquals("boom", thrown.getCause().getMessage()); verify(supplier, times(1)).get(); verifyNoMoreInteractions(supplier); } @TestRegistered: Sat Dec 20 13:44:44 UTC 2025 - Last Modified: Thu Aug 14 05:31:44 UTC 2025 - 5.2K bytes - Viewed (0) -
src/test/java/jcifs/dcerpc/msrpc/SamrAliasHandleTest.java
}).when(mockDcerpcHandle).sendrecv(any(MsrpcSamrOpenAlias.class)); // Act & Assert SmbException thrown = assertThrows(SmbException.class, () -> { new SamrAliasHandle(mockDcerpcHandle, mockSamrDomainHandle, access, rid); }); assertEquals(errorCode, thrown.getNtStatus()); } @Test void close_shouldCloseAliasSuccessfully() throws IOException { // Arrange
Registered: Sat Dec 20 13:44:44 UTC 2025 - Last Modified: Thu Aug 14 05:31:44 UTC 2025 - 6.2K bytes - Viewed (0) -
src/test/java/jcifs/dcerpc/msrpc/SamrPolicyHandleTest.java
doThrow(expectedException).when(mockHandle).sendrecv(any(MsrpcSamrConnect4.class)); DcerpcException thrown = assertThrows(DcerpcException.class, () -> { new SamrPolicyHandle(mockHandle, server, access); }); assertEquals(expectedException, thrown); verify(mockHandle, times(1)).sendrecv(any(MsrpcSamrConnect4.class));
Registered: Sat Dec 20 13:44:44 UTC 2025 - Last Modified: Thu Aug 14 05:31:44 UTC 2025 - 7.4K bytes - Viewed (0)