Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 3 of 3 for assertNoMoreTasks (0.07 sec)

  1. okhttp/src/test/java/okhttp3/internal/concurrent/TaskRunnerTest.kt

        taskFaker.advanceUntil(99.µs)
        assertThat(log).containsExactly()
    
        taskFaker.advanceUntil(100.µs)
        assertThat(log).containsExactly("run@100000")
    
        taskFaker.assertNoMoreTasks()
    
        assertThat(testLogHandler.takeAll()).containsExactly(
          "FINE: Q10000 scheduled after 100 µs: task",
          "FINE: Q10000 starting              : task",
          "FINE: Q10000 finished run in   0 µs: task",
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Mon Apr 29 00:33:04 UTC 2024
    - 23K bytes
    - Viewed (0)
  2. okhttp/src/test/java/okhttp3/internal/connection/FastFallbackExchangeFinderTest.kt

          val result0 = finder.find()
          assertThat(result0).isEqualTo(plan0.connection)
        }
    
        taskFaker.runTasks()
        assertEvents(
          "take plan 0",
        )
    
        taskFaker.assertNoMoreTasks()
      }
    
      @Test
      fun takeConnectingConnection() {
        val plan0 = routePlanner.addPlan()
        plan0.tcpConnectDelayNanos = 240.ms
    
        taskRunner.newQueue().execute("connect") {
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Wed Apr 24 04:40:49 UTC 2024
    - 20.9K bytes
    - Viewed (0)
  3. okhttp-testing-support/src/main/kotlin/okhttp3/internal/concurrent/TaskFaker.kt

          nanoTime = newTime
          yieldUntil(ResumePriority.AfterOtherTasks)
        }
      }
    
      /** Confirm all tasks have completed. Used by the test thread only. */
      fun assertNoMoreTasks() {
        taskRunner.assertThreadDoesntHoldLock()
    
        taskRunner.lock.withLock {
          assertThat(activeThreads).isEqualTo(0)
        }
      }
    
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Mon Apr 29 00:33:04 UTC 2024
    - 12.6K bytes
    - Viewed (0)
Back to top