Search Options

Display Count
Sort
Preferred Language
Advanced Search

Results 101 - 110 of 576 for 50 (0.02 seconds)

  1. docs/zh/docs/tutorial/query-params-str-validations.md

    有了 `Annotated` 之后,我们就可以放入更多信息(本例中是额外的校验)。在 `Annotated` 中添加 `Query`,并把参数 `max_length` 设为 `50`:
    
    {* ../../docs_src/query_params_str_validations/tutorial002_an_py310.py hl[9] *}
    
    注意默认值依然是 `None`,所以该参数仍是可选的。
    
    但现在把 `Query(max_length=50)` 放到 `Annotated` 里,我们就在告诉 FastAPI,这个值需要**额外校验**,最大长度为 50 个字符。😎
    
    /// tip | 提示
    
    Created: Sun Apr 05 07:19:11 GMT 2026
    - Last Modified: Fri Mar 20 17:06:37 GMT 2026
    - 15.4K bytes
    - Click Count (0)
  2. src/test/java/jcifs/internal/smb2/lock/Smb2LockRequestTest.java

                // Write to buffer
                byte[] buffer = new byte[512];
                int bytesWritten = lockRequest.writeBytesWireFormat(buffer, 50);
                assertEquals(24 + (24 * 2), bytesWritten);
    
                // Verify written structure
                assertEquals(48, SMBUtil.readInt2(buffer, 50)); // Structure size
                assertEquals(2, SMBUtil.readInt2(buffer, 52)); // Lock count
    Created: Sun Apr 05 00:10:12 GMT 2026
    - Last Modified: Thu Aug 14 05:31:44 GMT 2025
    - 25.3K bytes
    - Click Count (0)
  3. src/test/java/jcifs/internal/smb1/com/SmbComRenameTest.java

            String oldFileName = "old.txt";
            String newFileName = "new.txt";
            byte[] dst = new byte[200];
            smbComRename = new SmbComRename(config, oldFileName, newFileName);
            int dstIndex = 50; // Start at offset 50
    
            // When
            int result = smbComRename.writeBytesWireFormat(dst, dstIndex);
    
            // Then
            assertTrue(result > 0);
    Created: Sun Apr 05 00:10:12 GMT 2026
    - Last Modified: Thu Aug 14 05:31:44 GMT 2025
    - 12.5K bytes
    - Click Count (0)
  4. src/test/java/jcifs/internal/smb1/AndXServerMessageBlockTest.java

            buffer[0] = 4; // wordCount
            buffer[1] = (byte) 0x42; // andxCommand
            SMBUtil.writeInt2(50, buffer, 3); // andxOffset
            SMBUtil.writeInt2(20, buffer, 9); // byteCount
    
            // Setup andx command data at offset 50 (absolute position)
            buffer[50] = 4; // andx wordCount
            SMBUtil.writeInt2(20, buffer, 59); // andx byteCount
    
    Created: Sun Apr 05 00:10:12 GMT 2026
    - Last Modified: Thu Aug 14 05:31:44 GMT 2025
    - 19.4K bytes
    - Click Count (0)
  5. src/test/java/jcifs/util/ServerResponseValidatorTest.java

                validator.validateBuffer(null, 100, 1024);
            });
        }
    
        @Test
        public void testBufferTooSmall() throws Exception {
            byte[] buffer = new byte[50];
            assertThrows(SmbException.class, () -> {
                validator.validateBuffer(buffer, 100, 1024);
            });
        }
    
        @Test
        public void testBufferTooLarge() throws Exception {
    Created: Sun Apr 05 00:10:12 GMT 2026
    - Last Modified: Sat Aug 30 05:58:03 GMT 2025
    - 14.2K bytes
    - Click Count (0)
  6. android/guava-tests/test/com/google/common/util/concurrent/FakeTimeLimiterTest.java

     * Unit test for {@link FakeTimeLimiter}.
     *
     * @author Jens Nyman
     */
    @NullUnmarked
    @GwtIncompatible
    @J2ktIncompatible
    public class FakeTimeLimiterTest extends TestCase {
    
      private static final int DELAY_MS = 50;
      private static final String RETURN_VALUE = "abc";
    
      private TimeLimiter timeLimiter;
    
      @Override
      protected void setUp() throws Exception {
        super.setUp();
        timeLimiter = new FakeTimeLimiter();
      }
    Created: Fri Apr 03 12:43:13 GMT 2026
    - Last Modified: Mon Mar 16 22:45:21 GMT 2026
    - 4.1K bytes
    - Click Count (0)
  7. src/test/java/jcifs/internal/smb2/Smb2SigningDigestTest.java

            @DisplayName("Should handle high concurrency without deadlock")
            void testHighConcurrencyNoDeadlock() throws InterruptedException {
                int threadCount = 100;
                int operationsPerThread = 50;
                ExecutorService executor = Executors.newFixedThreadPool(threadCount);
                CountDownLatch startLatch = new CountDownLatch(1);
                CountDownLatch endLatch = new CountDownLatch(threadCount);
    Created: Sun Apr 05 00:10:12 GMT 2026
    - Last Modified: Sat Aug 30 05:58:03 GMT 2025
    - 43.7K bytes
    - Click Count (0)
  8. src/test/java/jcifs/smb1/smb1/SmbComSessionSetupAndXTest.java

            mockTransport.sessionKey = 0x12345678;
            mockTransport.capabilities = SmbConstants.CAP_UNICODE | SmbConstants.CAP_NT_SMBS;
            mockTransport.snd_buf_size = 16644;
            mockTransport.maxMpxCount = 50;
    
            // Configure mock session
            mockSession.transport = mockTransport;
    
            // Configure authentication - set fields directly since NtlmPasswordAuthentication is final
            mockAuth.username = "testuser";
    Created: Sun Apr 05 00:10:12 GMT 2026
    - Last Modified: Thu Aug 14 05:31:44 GMT 2025
    - 4.5K bytes
    - Click Count (0)
  9. src/test/java/jcifs/internal/smb2/tree/Smb2TreeConnectRequestTest.java

        @Test
        @DisplayName("Should write correct bytes to wire format")
        void testWriteBytesWireFormat() throws Exception {
            // Given
            byte[] buffer = new byte[512];
            int headerStart = 50;
            int bodyOffset = headerStart + Smb2Constants.SMB2_HEADER_LENGTH;
    
            // Encode the full message to set headerStart
            request.encode(buffer, headerStart);
    
    Created: Sun Apr 05 00:10:12 GMT 2026
    - Last Modified: Thu Aug 14 05:31:44 GMT 2025
    - 18.6K bytes
    - Click Count (0)
  10. src/test/java/jcifs/tests/persistent/HandleInfoTest.java

            // Test persistent handle (never expires)
            HandleInfo persistentInfo = new HandleInfo("/test/file2.txt", new HandleGuid(), testFileId, HandleType.PERSISTENT, 0, null);
    
            try {
                Thread.sleep(50);
            } catch (InterruptedException e) {
                Thread.currentThread().interrupt();
            }
    
            assertFalse(persistentInfo.isExpired());
        }
    
        @Test
        public void testUpdateAccessTime() {
    Created: Sun Apr 05 00:10:12 GMT 2026
    - Last Modified: Thu Aug 21 04:51:33 GMT 2025
    - 4.6K bytes
    - Click Count (0)
Back to Top