runHandler property

FutureOr<void> Function(TestRunRequest, CancellationToken) get runHandler

Handler called to start a test run. When invoked, the function should call {@link TestController.createTestRun} at least once, and all test runs associated with the request should be created before the function returns or the returned promise is resolved.

If {@link supportsContinuousRun} is set, then {@link TestRunRequest.continuous} may be true. In this case, the profile should observe changes to source code and create new test runs by calling {@link TestController.createTestRun}, until the cancellation is requested on the token.

@param request Request information for the test run. @param cancellationToken Token that signals the used asked to abort the test run. If cancellation is requested on this token, all {@link TestRun} instances associated with the request will be automatically cancelled as well.

Implementation

_i4.FutureOr<void> Function(
  _i3.TestRunRequest,
  _i3.CancellationToken,
) get runHandler => (
      _i3.TestRunRequest p0,
      _i3.CancellationToken p1,
    ) =>
        _i5.callMethod(
          _i5.getProperty(
            this,
            'runHandler',
          ),
          r'call',
          [
            this,
            p0,
            p1,
          ],
        );
set runHandler (FutureOr<void> value(TestRunRequest, CancellationToken))

Implementation

set runHandler(
    _i4.FutureOr<void> Function(
      _i3.TestRunRequest,
      _i3.CancellationToken,
    ) value) {
  _i5.setProperty(
    this,
    'runHandler',
    _i5.allowInterop((
      p0,
      p1,
    ) =>
        _i6.Promise.futureOr(() => value(
              p0,
              p1,
            ))),
  );
}