File
Blob: src/cloudflare/internal/test-tracing-wrapper.ts
| 1 | // Copyright (c) 2025 Cloudflare, Inc. |
| 2 | // Licensed under the Apache 2.0 license found in the LICENSE file or at: |
| 3 | // https://opensource.org/licenses/Apache-2.0 |
| 4 | |
| 5 | // TEST-ONLY MODULE - DO NOT USE IN PRODUCTION |
| 6 | // This wrapper exists solely to expose internal tracing utilities for testing. |
| 7 | // It must be in the internal/ directory to be compiled as part of the cloudflare bundle, |
| 8 | // but it should never be used outside of test configurations. |
| 9 | |
| 10 | import { withSpan } from 'cloudflare-internal:tracing-helpers'; |
| 11 | |
| 12 | interface TestWrapper { |
| 13 | withSpan: typeof withSpan; |
| 14 | } |
| 15 | |
| 16 | // Wrapper function that provides test utilities for tracing |
| 17 | export default function (_env: unknown): TestWrapper { |
| 18 | return { |
| 19 | // Export withSpan for testing |
| 20 | withSpan, |
| 21 | }; |
| 22 | } |