mirror of
https://github.com/tailscale/tailscale.git
synced 2026-04-21 05:21:12 +02:00
TestEncodeAndUploadMessages waited on the default 2s FlushDelay, making the logtail package the slowest non-integration test in the tree (~2s real time). Switch the shared harness from an httptest.Server-on-loopback to a memnet.Listener-backed *http.Server and run the tests inside synctest.Test, so fake time advances the flush timer instantly. Drops the net/http/httptest dependency from these tests. Combined with the TestMain non-localhost dial guard added in the previous commit, no test in this package can accidentally reach the real log.tailscale.com server. Whole package now runs in ~7ms. Updates tailscale/corp#28679 Change-Id: Ie0e7a6a79641384ed0eecb99d767e17cda8bb944 Signed-off-by: Brad Fitzpatrick <bradfitz@tailscale.com>
Tailscale Logs Service
This github repository contains libraries, documentation, and examples for working with the public API of the tailscale logs service.
For a very quick introduction to the core features, read the API docs and peruse the logs reprocessing example.
For more information, write to info@tailscale.io.