- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 185 for teststring (0.06 sec)
-
android/guava-tests/benchmark/com/google/common/base/WhitespaceMatcherBenchmark.java
matcher = useNew ? CharMatcher.whitespace() : OLD_WHITESPACE; teststring = newTestString(new Random(1), bitSet, percentMatching); } @Benchmark public int countIn(int reps) { int result = 0; CharMatcher matcher = this.matcher; String teststring = this.teststring; for (int i = 0; i < reps; i++) { result += matcher.countIn(teststring); } return result; } @Benchmark
Registered: Fri Sep 05 12:43:10 UTC 2025 - Last Modified: Tue May 13 18:46:00 UTC 2025 - 3.9K bytes - Viewed (0) -
src/test/java/jcifs/pac/PacUnicodeStringTest.java
PacUnicodeString pacString = new PacUnicodeString((short) 10, (short) 20, 100); String testString = "abcde"; // The check method should return the same string instance String result = pacString.check(testString); assertSame(testString, result, "The check method should return the original string on success."); } /**
Registered: Sun Sep 07 00:10:21 UTC 2025 - Last Modified: Thu Aug 14 05:31:44 UTC 2025 - 5.7K bytes - Viewed (0) -
src/test/java/jcifs/smb1/smb1/ServerMessageBlockTest.java
smb.useUnicode = false; String testString = "Hello World"; byte[] buffer = new byte[testString.length() + 1]; int len = smb.writeString(testString, buffer, 0); assertEquals(testString.length() + 1, len); String readString = smb.readString(buffer, 0); assertEquals(testString, readString); } @Test
Registered: Sun Sep 07 00:10:21 UTC 2025 - Last Modified: Thu Aug 14 05:31:44 UTC 2025 - 9.9K bytes - Viewed (0) -
guava-tests/test/com/google/common/io/MultiReaderTest.java
assertFalse(joinedReader.ready()); } public void testSimple() throws Exception { String testString = "abcdefgh"; CharSource source = newCharSource(testString); Reader joinedReader = CharSource.concat(source, source).openStream(); String expectedString = testString + testString; assertEquals(expectedString, CharStreams.toString(joinedReader)); }
Registered: Fri Sep 05 12:43:10 UTC 2025 - Last Modified: Tue May 13 18:46:00 UTC 2025 - 3.7K bytes - Viewed (0) -
src/test/java/jcifs/util/EncdecTest.java
// Given String testString = "Hello"; byte[] buffer = new byte[testString.length()]; // When - Manual string encoding using individual bytes byte[] strBytes = testString.getBytes(); System.arraycopy(strBytes, 0, buffer, 0, strBytes.length); // Then String decoded = new String(buffer); assertEquals(testString, decoded); } @Test
Registered: Sun Sep 07 00:10:21 UTC 2025 - Last Modified: Thu Aug 14 05:31:44 UTC 2025 - 5.1K bytes - Viewed (0) -
src/test/java/jcifs/internal/smb1/ServerMessageBlockTest.java
testBlock.setUseUnicode(true); byte[] buffer = new byte[100]; String testString = "Test"; int bytesWritten = testBlock.writeString(testString, buffer, 10); // Unicode strings are written as UTF-16LE with null terminator assertTrue(bytesWritten > testString.length()); // First byte should be 'T' in UTF-16LE (0x54)
Registered: Sun Sep 07 00:10:21 UTC 2025 - Last Modified: Thu Aug 14 05:31:44 UTC 2025 - 36.2K bytes - Viewed (0) -
src/test/java/jcifs/internal/smb1/net/NetShareEnumResponseTest.java
} @Test @DisplayName("Test readString with ASCII encoding") void testReadStringAscii() throws Exception { String testString = "TestString"; byte[] buffer = new byte[128]; byte[] stringBytes = testString.getBytes(StandardCharsets.US_ASCII); System.arraycopy(stringBytes, 0, buffer, 10, stringBytes.length); buffer[10 + stringBytes.length] = 0; // null terminator
Registered: Sun Sep 07 00:10:21 UTC 2025 - Last Modified: Thu Aug 14 05:31:44 UTC 2025 - 20.2K bytes - Viewed (0) -
src/test/java/jcifs/pac/PacLogonInfoTest.java
String testString = "TEST"; short length = (short) (testString.length() * 2); // Unicode length PacUnicodeString unicodeString = new PacUnicodeString(length, length, 100); // Should validate string length String result = unicodeString.check(testString); assertEquals(testString, result); // Should reject wrong length
Registered: Sun Sep 07 00:10:21 UTC 2025 - Last Modified: Thu Aug 14 05:31:44 UTC 2025 - 12.3K bytes - Viewed (0) -
src/test/java/jcifs/dcerpc/ndr/NdrBufferTest.java
} @Test void testEncDecNdrString() throws NdrException { String testString = "Hello World"; ndrBuffer.enc_ndr_string(testString); // Expected length: 4 (actual_count) + 4 (offset) + 4 (max_count) + len*2 (unicode) + 2 (null terminator) int expectedLength = 4 + 4 + 4 + (testString.length() * 2) + 2; assertEquals(expectedLength, ndrBuffer.getIndex());
Registered: Sun Sep 07 00:10:21 UTC 2025 - Last Modified: Thu Aug 14 05:31:44 UTC 2025 - 14.3K bytes - Viewed (0) -
android/guava-tests/test/com/google/common/io/CharStreamsTest.java
} public void testSkipFully() throws IOException { String testString = "abcdef"; Reader reader = new StringReader(testString); assertEquals(testString.charAt(0), reader.read()); CharStreams.skipFully(reader, 1); assertEquals(testString.charAt(2), reader.read()); CharStreams.skipFully(reader, 2); assertEquals(testString.charAt(5), reader.read()); assertEquals(-1, reader.read()); }
Registered: Fri Sep 05 12:43:10 UTC 2025 - Last Modified: Tue May 13 18:46:00 UTC 2025 - 11.3K bytes - Viewed (0)