- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 105 for NullPointerException (0.56 sec)
-
src/test/java/jcifs/pac/PacUnicodeStringTest.java
String testString = null; // Expect a NullPointerException due to null string assertThrows(NullPointerException.class, () -> { pacString.check(testString); }, "A NullPointerException should be thrown for a null string with non-zero pointer."); }Registered: 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/pac/kerberos/KerberosRelevantAuthDataTest.java
"The exception should be either PACDecodingException or NullPointerException."); if (exception instanceof PACDecodingException) { assertEquals("Malformed kerberos ticket", exception.getMessage(), "PAC exception should indicate malformed ticket."); } else if (exception instanceof NullPointerException) { // Empty input causes null ASN1 object, which is expected behaviorRegistered: Sat Dec 20 13:44:44 UTC 2025 - Last Modified: Thu Aug 14 05:31:44 UTC 2025 - 9K bytes - Viewed (0) -
src/test/java/jcifs/smb1/dcerpc/ndr/NdrHyperTest.java
/** * Ensure encode throws NPE when passed a null buffer. */ @Test @DisplayName("Encode with null buffer throws NullPointerException") public void testEncodeNullBuffer() throws NdrException { NdrHyper hyper = new NdrHyper(5L); assertThrows(NullPointerException.class, () -> hyper.encode(null)); } /** * Ensure decode throws NPE when passed a null buffer. */ @TestRegistered: Sat Dec 20 13:44:44 UTC 2025 - Last Modified: Thu Aug 14 05:31:44 UTC 2025 - 4.3K bytes - Viewed (0) -
src/test/java/jcifs/smb/CredentialsInternalTest.java
void unwrap_null_type_throws() { TestCredentials creds = new TestCredentials("DOM", false, false, new Subject(), false); // Act & Assert NullPointerException npe = assertThrows(NullPointerException.class, () -> creds.unwrap(null)); assertEquals("type", npe.getMessage()); } @Test @DisplayName("clone returns a distinct copy with same properties")
Registered: Sat Dec 20 13:44:44 UTC 2025 - Last Modified: Thu Aug 14 05:31:44 UTC 2025 - 9.9K bytes - Viewed (0) -
src/test/java/jcifs/smb/SmbPipeOutputStreamTest.java
@Test @DisplayName("Null handle triggers NullPointerException") void ctor_nullHandle_throwsNPE() { // Act + Assert assertThrows(NullPointerException.class, () -> new SmbPipeOutputStream(null, tree)); } @Test @DisplayName("Null tree handle triggers NullPointerException") void ctor_nullTree_throwsNPE() { // ArrangeRegistered: Sat Dec 20 13:44:44 UTC 2025 - Last Modified: Thu Aug 14 05:31:44 UTC 2025 - 5.4K bytes - Viewed (0) -
src/test/java/jcifs/smb/SmbFilenameFilterTest.java
throw new NullPointerException("dir and name must be non-null"); } return true; }; NullPointerException npe1 = assertThrows(NullPointerException.class, () -> filter.accept(null, "x")); assertTrue(npe1.getMessage().contains("non-null")); NullPointerException npe2 = assertThrows(NullPointerException.class, () -> filter.accept(mockDir, null));Registered: Sat Dec 20 13:44:44 UTC 2025 - Last Modified: Thu Aug 14 05:31:44 UTC 2025 - 7.3K bytes - Viewed (0) -
src/test/java/jcifs/smb/NetServerEnumIteratorTest.java
} @Test @DisplayName("Constructor should handle null parent") void testConstructor_NullParent_ThrowsNPE() { // When & Then: Null parent should cause NullPointerException assertThrows(NullPointerException.class, () -> new NetServerEnumIterator(null, treeHandle, "*", 0, null)); } @Test @DisplayName("Constructor should handle null tree handle")Registered: Sat Dec 20 13:44:44 UTC 2025 - Last Modified: Thu Aug 14 05:31:44 UTC 2025 - 9.8K bytes - Viewed (0) -
src/test/java/org/codelibs/fess/suggest/index/writer/SuggestWriterResultTest.java
result.addFailure(new RuntimeException("RuntimeException")); result.addFailure(new IllegalStateException("IllegalStateException")); result.addFailure(new NullPointerException("NullPointerException")); assertEquals(4, result.getFailures().size()); assertTrue(result.getFailures().get(0) instanceof Exception); assertTrue(result.getFailures().get(1) instanceof RuntimeException);
Registered: Sat Dec 20 13:04:59 UTC 2025 - Last Modified: Thu Nov 13 00:40:54 UTC 2025 - 4.3K bytes - Viewed (0) -
src/test/java/jcifs/smb/SmbFileOutputStreamTest.java
// Close the stream outputStream.close(); // When & Then - after close, tmp is null so write(int) will throw NullPointerException // This is the actual behavior of the implementation assertThrows(NullPointerException.class, () -> outputStream.write(65)); } @Test void testWriteNullArray() throws CIFSException { // GivenRegistered: Sat Dec 20 13:44:44 UTC 2025 - Last Modified: Thu Aug 14 05:31:44 UTC 2025 - 15.8K bytes - Viewed (0) -
src/test/java/jcifs/smb1/smb1/NtlmChallengeTest.java
NtlmChallenge nc = new NtlmChallenge(null, dc); // Hexdump.toHexString will throw NPE when accessing challenge.length assertThrows(NullPointerException.class, nc::toString); } @Test @DisplayName("toString with null dc throws NPE") void testToStringWithNullDcThrowsNPE() { byte[] challenge = new byte[] { 1, 2, 3 };Registered: Sat Dec 20 13:44:44 UTC 2025 - Last Modified: Thu Aug 14 05:31:44 UTC 2025 - 6K bytes - Viewed (0)