- Sort Score
- Result 10 results
- Languages All
Results 81 - 90 of 105 for NullPointerException (0.41 sec)
-
src/main/java/jcifs/http/NtlmHttpURLConnection.java
this.connection.setReadTimeout(timeout); } @Override public void setRequestProperty(final String key, final String value) { if (key == null) { throw new NullPointerException(); } final List<String> values = new ArrayList<>(); values.add(value); boolean found = false;
Registered: Sat Dec 20 13:44:44 UTC 2025 - Last Modified: Sat Aug 16 01:32:48 UTC 2025 - 25.6K bytes - Viewed (0) -
src/test/java/jcifs/smb/SpnegoContextTest.java
void testInitSecContextNullBufferNonZeroLen() throws Exception { SpnegoContext ctx = newContext(); // A null buffer with non-zero len leads to NPE while slicing input assertThrows(NullPointerException.class, () -> ctx.initSecContext(null, 0, 1)); verify(this.mechContext, never()).initSecContext(any(), anyInt(), anyInt()); } @Test
Registered: Sat Dec 20 13:44:44 UTC 2025 - Last Modified: Thu Aug 14 05:31:44 UTC 2025 - 9.3K bytes - Viewed (0) -
src/test/java/jcifs/internal/smb2/io/Smb2WriteRequestTest.java
request.setData(null, 0, 100); byte[] buffer = new byte[256]; // Should handle gracefully or throw appropriate exception assertThrows(NullPointerException.class, () -> request.writeBytesWireFormat(buffer, 0)); } @Test @DisplayName("Should handle data offset beyond array bounds") void testDataOffsetBeyondBounds() {
Registered: Sat Dec 20 13:44:44 UTC 2025 - Last Modified: Thu Aug 14 05:31:44 UTC 2025 - 22.4K bytes - Viewed (0) -
fess-crawler-opensearch/src/test/java/org/codelibs/fess/crawler/client/FesenClientTest.java
when(mockHealthResponse.isTimedOut()).thenReturn(false); when(mockFuture.actionGet(anyLong(), any(TimeUnit.class))).thenReturn(mockHealthResponse); // Should not throw NullPointerException try { // Note: We can't easily test connect() fully without mocking createClient() // This test verifies the null check logic indirectly
Registered: Sat Dec 20 11:21:39 UTC 2025 - Last Modified: Thu Nov 20 08:44:44 UTC 2025 - 17K bytes - Viewed (0) -
src/test/java/jcifs/internal/smb1/trans2/Trans2QueryPathInformationResponseTest.java
void testGetInfoWithTypeWhenNull() { response = new Trans2QueryPathInformationResponse(mockConfig, FileInformation.FILE_BASIC_INFO); assertThrows(NullPointerException.class, () -> { response.getInfo(FileBasicInfo.class); }); } @Test @DisplayName("Test getInfo with compatible type") void testGetInfoWithCompatibleType() throws Exception {
Registered: Sat Dec 20 13:44:44 UTC 2025 - Last Modified: Thu Aug 14 05:31:44 UTC 2025 - 11.9K bytes - Viewed (0) -
src/test/java/jcifs/smb/FileEntryAdapterIteratorTest.java
assertEquals("Not supported", ex.getMessage()); } @Test @DisplayName("Null delegate causes NPE") void nullDelegate() { assertThrows(NullPointerException.class, () -> { new FileEntryAdapterIterator(parent, null, null) { @Override protected SmbResource adapt(FileEntry e) { return resource;
Registered: Sat Dec 20 13:44:44 UTC 2025 - Last Modified: Thu Aug 14 07:14:38 UTC 2025 - 10.6K bytes - Viewed (0) -
src/test/java/jcifs/smb/FileEntryTest.java
void nullReference_throwsNPE() { // Arrange FileEntry e = null; // Act & Assert: demonstrate invalid usage results in NPE assertThrows(NullPointerException.class, () -> e.getName()); } @Nested @DisplayName("Mockito stubbing for edge cases") class MockitoEdgeCases { @Test
Registered: Sat Dec 20 13:44:44 UTC 2025 - Last Modified: Thu Aug 14 05:31:44 UTC 2025 - 10K bytes - Viewed (0) -
src/test/java/jcifs/internal/smb2/tree/Smb2TreeConnectRequestTest.java
// Then - should not throw during construction assertNotNull(reqWithNull); // But should throw when trying to use the null path assertThrows(NullPointerException.class, () -> { reqWithNull.size(); }); } @Test @DisplayName("Should write consistent structure at different offsets")Registered: Sat Dec 20 13:44:44 UTC 2025 - Last Modified: Thu Aug 14 05:31:44 UTC 2025 - 18.6K bytes - Viewed (0) -
src/test/java/jcifs/netbios/NodeStatusRequestTest.java
// Arrange nodeStatusRequest = new NodeStatusRequest(mockConfig, null); byte[] dst = new byte[100]; // Act & Assert assertThrows(NullPointerException.class, () -> { nodeStatusRequest.writeBodyWireFormat(dst, 0); }); } @Test void multipleWriteBodyWireFormat_shouldProduceSameResult() { // ArrangeRegistered: Sat Dec 20 13:44:44 UTC 2025 - Last Modified: Thu Aug 14 05:31:44 UTC 2025 - 13.9K bytes - Viewed (0) -
src/test/java/jcifs/ntlmssp/Type1MessageTest.java
}); } @Test @DisplayName("Should handle parsing null message bytes") void testNullMessageBytes() { // When/Then assertThrows(NullPointerException.class, () -> { new Type1Message((byte[]) null); }); } @Test @DisplayName("Should create string representation") void testStringRepresentation() {Registered: Sat Dec 20 13:44:44 UTC 2025 - Last Modified: Thu Aug 14 05:31:44 UTC 2025 - 12.1K bytes - Viewed (0)