Skip to content

Keep Fastly identity tests off the network and behind a resolvable origin #1560

Open

Description

@dhruv8sh

Follow-up from PR #1487 (review round 3).

Description

The page-phase identity test in crates/trusted-server-adapter-fastly sends a real provider lookup during routing. Dispatch uses FastlyPlatformHttpClient; the counting test client only replaces it at collect. Viceroy logs a DNS error for the fictional provider host (ids.example.com), and no assertion checks the send count, so the test passes whether or not the lookup was sent.

All the Viceroy identity tests also run behind a Trusted-Server-generated 502, because the fixture origin does not resolve. They therefore exercise the origin-unreachable path rather than a normal page response.

Done when

  • The lookup client is injected at dispatch, so the test client sees every send and no real network request leaves the test.
  • Each identity test asserts the expected provider send count.
  • The Viceroy fixture has a resolvable origin (for example a local backend), so identity tests run against a normal origin response; the 502 path is covered by an explicit test where intended.
  • Viceroy test logs show no DNS errors for provider or origin hosts.

Affected area

Fastly runtime

Code: crates/trusted-server-adapter-fastly (identity Viceroy tests, FastlyPlatformHttpClient dispatch path).

Activity

  1. added this to the 202611 milestone on Nov 12, 2026
  2. added theissue type on Nov 12, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions