Skip to content

Speed up dial timeout tests#64035

Merged
rosstimothy merged 1 commit intomasterfrom
tross/test_dial_timeout
Feb 21, 2026
Merged

Speed up dial timeout tests#64035
rosstimothy merged 1 commit intomasterfrom
tross/test_dial_timeout

Conversation

@rosstimothy
Copy link
Contributor

@rosstimothy rosstimothy commented Feb 20, 2026

Leverage synctest to exercise client dial timeout tests instead of the tests sitting idle for the entire timeout. Tests were moved to api and now test against the api.Client directly instead of indirectly via the auth.Client to exercise tests against a fake dialer in the synctest bubble.

Comparison of the old and new test

$ time ./authclient.test -test.v -test.count=1  -test.run="TestClient_DialTimeout"
=== RUN   TestClient_DialTimeout
=== PAUSE TestClient_DialTimeout
=== CONT  TestClient_DialTimeout
=== RUN   TestClient_DialTimeout/dial_timeout_set_to_valid_value
=== PAUSE TestClient_DialTimeout/dial_timeout_set_to_valid_value
=== RUN   TestClient_DialTimeout/defaults_prevent_infinite_timeout
=== PAUSE TestClient_DialTimeout/defaults_prevent_infinite_timeout
=== CONT  TestClient_DialTimeout/defaults_prevent_infinite_timeout
=== CONT  TestClient_DialTimeout/dial_timeout_set_to_valid_value
--- PASS: TestClient_DialTimeout (0.00s)
    --- PASS: TestClient_DialTimeout/dial_timeout_set_to_valid_value (0.50s)
    --- PASS: TestClient_DialTimeout/defaults_prevent_infinite_timeout (20.00s)
PASS
________________________________________________________
Executed in   21.10 secs      fish           external
   usr time   82.91 millis    0.30 millis   82.61 millis
   sys time   44.29 millis    3.26 millis   41.02 millis


$ time ./api/client.test -test.v -test.count=1 -test.run="TestDialTimeout"
=== RUN   TestDialTimeout
=== PAUSE TestDialTimeout
=== CONT  TestDialTimeout
=== RUN   TestDialTimeout/dial_timeout_set_to_valid_value
=== RUN   TestDialTimeout/defaults_prevent_infinite_timeout
--- PASS: TestDialTimeout (0.00s)
    --- PASS: TestDialTimeout/dial_timeout_set_to_valid_value (0.00s)
    --- PASS: TestDialTimeout/defaults_prevent_infinite_timeout (0.00s)
PASS

________________________________________________________
Executed in    1.05 secs      fish           external
   usr time   27.57 millis    0.21 millis   27.36 millis
   sys time   12.28 millis    1.65 millis   10.63 millis

@rosstimothy rosstimothy added no-changelog Indicates that a PR does not require a changelog entry backport/branch/v17 backport/branch/v18 labels Feb 21, 2026
Leverage synctest to exercise client dial timeout tests instead of
the tests sitting idle for the entire timeout. Tests were moved
to api and now test against the api.Client directly instead of
indirectly via the auth.Client to exercise tests against a fake
dialer in the synctest bubble.
@rosstimothy rosstimothy force-pushed the tross/test_dial_timeout branch from 831f5eb to 58084c2 Compare February 21, 2026 00:03
@rosstimothy rosstimothy marked this pull request as ready for review February 21, 2026 00:03
@github-actions github-actions bot requested review from tcsc and tigrato February 21, 2026 00:04
@public-teleport-github-review-bot public-teleport-github-review-bot bot removed the request for review from tcsc February 21, 2026 10:33
@rosstimothy rosstimothy added this pull request to the merge queue Feb 21, 2026
Merged via the queue into master with commit 14ea85c Feb 21, 2026
46 checks passed
@rosstimothy rosstimothy deleted the tross/test_dial_timeout branch February 21, 2026 17:13
@backport-bot-workflows
Copy link
Contributor

@rosstimothy See the table below for backport results.

Branch Result
branch/v17 Failed
branch/v18 Failed

rosstimothy added a commit that referenced this pull request Feb 22, 2026
Leverage synctest to exercise client dial timeout tests instead of
the tests sitting idle for the entire timeout. Tests were moved
to api and now test against the api.Client directly instead of
indirectly via the auth.Client to exercise tests against a fake
dialer in the synctest bubble.
rosstimothy added a commit that referenced this pull request Feb 22, 2026
Leverage synctest to exercise client dial timeout tests instead of
the tests sitting idle for the entire timeout. Tests were moved
to api and now test against the api.Client directly instead of
indirectly via the auth.Client to exercise tests against a fake
dialer in the synctest bubble.
rosstimothy added a commit that referenced this pull request Feb 24, 2026
Leverage synctest to exercise client dial timeout tests instead of
the tests sitting idle for the entire timeout. Tests were moved
to api and now test against the api.Client directly instead of
indirectly via the auth.Client to exercise tests against a fake
dialer in the synctest bubble.
rosstimothy added a commit that referenced this pull request Feb 26, 2026
Leverage synctest to exercise client dial timeout tests instead of
the tests sitting idle for the entire timeout. Tests were moved
to api and now test against the api.Client directly instead of
indirectly via the auth.Client to exercise tests against a fake
dialer in the synctest bubble.
rosstimothy added a commit that referenced this pull request Feb 26, 2026
Leverage synctest to exercise client dial timeout tests instead of
the tests sitting idle for the entire timeout. Tests were moved
to api and now test against the api.Client directly instead of
indirectly via the auth.Client to exercise tests against a fake
dialer in the synctest bubble.
github-merge-queue bot pushed a commit that referenced this pull request Feb 26, 2026
Leverage synctest to exercise client dial timeout tests instead of
the tests sitting idle for the entire timeout. Tests were moved
to api and now test against the api.Client directly instead of
indirectly via the auth.Client to exercise tests against a fake
dialer in the synctest bubble.
github-merge-queue bot pushed a commit that referenced this pull request Feb 27, 2026
Leverage synctest to exercise client dial timeout tests instead of
the tests sitting idle for the entire timeout. Tests were moved
to api and now test against the api.Client directly instead of
indirectly via the auth.Client to exercise tests against a fake
dialer in the synctest bubble.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backport/branch/v17 backport/branch/v18 no-changelog Indicates that a PR does not require a changelog entry size/sm

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants