Skip to content

[golang] Enable go api testing tests#6953

Draft
e-n-0 wants to merge 1 commit into
mainfrom
flavien.darche/go/api-testing
Draft

[golang] Enable go api testing tests#6953
e-n-0 wants to merge 1 commit into
mainfrom
flavien.darche/go/api-testing

Conversation

@e-n-0
Copy link
Copy Markdown
Member

@e-n-0 e-n-0 commented May 15, 2026

Motivation

Enable tests from #6915 for the go tracer following the implementation made at DataDog/dd-trace-go#4774

Changes

Workflow

  1. ⚠️ Create your PR as draft ⚠️
  2. Work on you PR until the CI passes
  3. Mark it as ready for review
    • Test logic is modified? -> Get a review from RFC owner.
    • Framework is modified, or non obvious usage of it -> get a review from R&P team

🚀 Once your PR is reviewed and the CI green, you can merge it!

🛟 #apm-shared-testing 🛟

Reviewer checklist

  • Anything but tests/ or manifests/ is modified ? I have the approval from R&P team
  • A docker base image is modified?
    • the relevant build-XXX-image label is present
  • A scenario is added, removed or renamed?

@github-actions
Copy link
Copy Markdown
Contributor

CODEOWNERS have been resolved as:

manifests/golang.yml                                                    @DataDog/dd-trace-go-guild

@datadog-datadog-prod-us1
Copy link
Copy Markdown

datadog-datadog-prod-us1 Bot commented May 15, 2026

Tests

Fix all issues with BitsAI or with Cursor

⚠️ Warnings

🧪 18 Tests failed

tests.appsec.api_security_testing.test_headers_collection.Test_SecurityTestingHeaders.test_absent_when_not_in_request[chi] from system_tests_suite   View in Datadog   (Fix with Cursor)
AssertionError: http.request.headers.x-datadog-endpoint-scan not collected on entry span
assert None == 'scan-aaaaaaaa-aaaa-aaaa-aaaa-aaaaaaaaaaaa'
 +  where None = <built-in method get of dict object at 0x7fbde86b34c0>('http.request.headers.x-datadog-endpoint-scan')
 +    where <built-in method get of dict object at 0x7fbde86b34c0> = {'_dd.p.dm': '-1', '_dd.p.ksr': '1', '_dd.p.tid': '6a07603400000000', 'component': 'go-chi/chi.v5', ...}.get
 +  and   'scan-aaaaaaaa-aaaa-aaaa-aaaa-aaaaaaaaaaaa' = Test_SecurityTestingHeaders.SCAN_VALUE

self = <tests.appsec.api_security_testing.test_headers_collection.Test_SecurityTestingHeaders object at 0x7fbe188040b0>

    def test_absent_when_not_in_request(self):
        """No security testing tag is set when the headers are not in the request."""
...
tests.appsec.api_security_testing.test_headers_collection.Test_SecurityTestingHeaders.test_absent_when_not_in_request[echo] from system_tests_suite   View in Datadog   (Fix with Cursor)
AssertionError: http.request.headers.x-datadog-endpoint-scan not collected on entry span
assert None == 'scan-aaaaaaaa-aaaa-aaaa-aaaa-aaaaaaaaaaaa'
 +  where None = <built-in method get of dict object at 0x7fc26da845c0>('http.request.headers.x-datadog-endpoint-scan')
 +    where <built-in method get of dict object at 0x7fc26da845c0> = {'_dd.p.dm': '-1', '_dd.p.ksr': '1', '_dd.p.tid': '6a07604f00000000', 'component': 'labstack/echo.v4', ...}.get
 +  and   'scan-aaaaaaaa-aaaa-aaaa-aaaa-aaaaaaaaaaaa' = Test_SecurityTestingHeaders.SCAN_VALUE

self = <tests.appsec.api_security_testing.test_headers_collection.Test_SecurityTestingHeaders object at 0x7fc290b5eea0>

    def test_absent_when_not_in_request(self):
        """No security testing tag is set when the headers are not in the request."""
...
tests.appsec.api_security_testing.test_headers_collection.Test_SecurityTestingHeaders.test_absent_when_not_in_request[gin] from system_tests_suite   View in Datadog   (Fix with Cursor)
AssertionError: http.request.headers.x-datadog-endpoint-scan not collected on entry span
assert None == 'scan-aaaaaaaa-aaaa-aaaa-aaaa-aaaaaaaaaaaa'
 +  where None = <built-in method get of dict object at 0x7fbde0288fc0>('http.request.headers.x-datadog-endpoint-scan')
 +    where <built-in method get of dict object at 0x7fbde0288fc0> = {'_dd.p.dm': '-1', '_dd.p.ksr': '1', '_dd.p.tid': '6a07604000000000', 'component': 'gin-gonic/gin', ...}.get
 +  and   'scan-aaaaaaaa-aaaa-aaaa-aaaa-aaaaaaaaaaaa' = Test_SecurityTestingHeaders.SCAN_VALUE

self = <tests.appsec.api_security_testing.test_headers_collection.Test_SecurityTestingHeaders object at 0x7fbdf8a1db50>

    def test_absent_when_not_in_request(self):
        """No security testing tag is set when the headers are not in the request."""
...
View all

ℹ️ Info

No other issues found (see more)

❄️ No new flaky tests detected

Useful? React with 👍 / 👎

This comment will be updated automatically if new data arrives.
🔗 Commit SHA: 5da02ca | Docs | Datadog PR Page | Give us feedback!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant