Skip to content

(feat) internal/civisibility: add support for testify Suites#3094

Merged
tonyredondo merged 1 commit into
mainfrom
tony/civisibility-testify-support
Jan 17, 2025
Merged

(feat) internal/civisibility: add support for testify Suites#3094
tonyredondo merged 1 commit into
mainfrom
tony/civisibility-testify-support

Conversation

@tonyredondo

@tonyredondo tonyredondo commented Jan 16, 2025

Copy link
Copy Markdown
Member

What does this PR do?

This PR adds support for testify Suite kind of tests.

Ticket: SDTEST-1435

V2 PR: #3097

Note: This improvement will require a new orchestrion integration to intercept suite.Run calls

Example:

....
type USMSuite struct {
	suite.Suite
}

func TestUSMSuite(t *testing.T) {
	suite.Run(t, new(USMSuite))
}

func (s *USMSuite) TestEnableHTTPMonitoring() {
}

func (s *USMSuite) TestDisableUSM() {
}
....

Motivation

Currently the support lacks the correct identification of the Suite name, Module name and Test source affecting features like Codeowners and Impact Analysis

From:

image image

To:

image image

Reviewer's Checklist

  • Changed code has unit tests for its functionality at or near 100% coverage.
  • System-Tests covering this feature have been added and enabled with the va.b.c-dev version tag.
  • There is a benchmark for any new code, or changes to existing code.
  • If this interacts with the agent in a new way, a system test has been added.
  • Add an appropriate team label so this PR gets put in the right place for the release notes.
  • Non-trivial go.mod changes, e.g. adding new modules, are reviewed by @DataDog/dd-trace-go-guild.
  • For internal contributors, a matching PR should be created to the v2-dev branch and reviewed by @DataDog/apm-go.

Unsure? Have a question? Request a review!

@datadog-datadog-prod-us1

datadog-datadog-prod-us1 Bot commented Jan 16, 2025

Copy link
Copy Markdown

Datadog Report

Branch report: tony/civisibility-testify-support
Commit report: 395675e
Test service: dd-trace-go

✅ 0 Failed, 5185 Passed, 71 Skipped, 2m 49.04s Total Time

@pr-commenter

pr-commenter Bot commented Jan 16, 2025

Copy link
Copy Markdown

Benchmarks

Benchmark execution time: 2025-01-17 00:21:07

Comparing candidate commit 5f36bd8 in PR branch tony/civisibility-testify-support with baseline commit b49d213 in branch main.

Found 0 performance improvements and 0 performance regressions! Performance is the same for 58 metrics, 1 unstable metrics.

@tonyredondo
tonyredondo force-pushed the tony/civisibility-testify-support branch from 1738181 to 50c0f7e Compare January 16, 2025 23:21
@tonyredondo
tonyredondo marked this pull request as ready for review January 16, 2025 23:37
@tonyredondo
tonyredondo requested review from a team as code owners January 16, 2025 23:37
@tonyredondo
tonyredondo force-pushed the tony/civisibility-testify-support branch from 50c0f7e to 5f36bd8 Compare January 16, 2025 23:37
@tonyredondo
tonyredondo force-pushed the tony/civisibility-testify-support branch from 5f36bd8 to f0fa28c Compare January 17, 2025 11:20
@tonyredondo
tonyredondo enabled auto-merge (squash) January 17, 2025 11:25
@tonyredondo
tonyredondo merged commit 9a8062c into main Jan 17, 2025
@tonyredondo
tonyredondo deleted the tony/civisibility-testify-support branch January 17, 2025 11:27
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.

4 participants