Skip to content

Add integration test to validate js-compute export/type resolution behavior #1302

@harmony7

Description

@harmony7

The 3.39 change exposed legacy TypeScript configurations that relied on previous default export behavior. To prevent unintended changes to export or type resolution in the future, add a lightweight integration test to CI that validates how js-compute resolves under different TypeScript configurations.

This test should simulate real consumer behavior and fail if export or type resolution changes unexpectedly.

Scope

Create a minimal TypeScript consumer fixture and validate two scenarios:

  1. Fastly configuration
    • tsconfig includes Fastly condition (current standard tooling behavior)
    • Expected: Fastly-specific types resolve successfully
  2. Legacy/default configuration
    • No Fastly condition
    • Expected: Default types resolve according to current intended behavior (stub/default compatibility)

The CI job should run tsc and fail on unexpected resolution errors.

Acceptance Criteria

  • A GitHub Actions job runs on PR and main.
  • Two fixture projects exist:
    • consumer-fastly
    • consumer-default
  • Both compile successfully under the current intended behavior.
  • If export map or type resolution changes in a way that breaks either scenario, CI fails.

Notes

Goal is to detect accidental changes to:

  • exports map
  • conditional types resolution
  • default vs fastly behavior

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions