Skip to content

Conversation

@realark
Copy link
Contributor

@realark realark commented Dec 21, 2017

  • Provide a test framework which extends spock to automatically retransform instrumentation classes at test setup.
  • Move bytebuddy logic into tooling to allow the core agent and the test framework to share the same codepath for configuring the bytebuddy agent.

This allows us to test instrumentation entirely in the ide/spock (no -javaagent flag required).

There are still some tests in the dd-java-agent-ittests project which should be moved into their integration subproject and converted to the new test framework. These will eventually be moved over, but they're not a super high priority at the moment.

@realark realark added the tag: do not merge Do not merge changes label Dec 21, 2017
@realark realark force-pushed the ark/agent_test_framework branch 11 times, most recently from d11a8de to d41897e Compare December 28, 2017 02:16
@realark realark added dev/tooling type: enhancement Enhancements and improvements inst: others All other instrumentations and removed tag: do not merge Do not merge changes labels Dec 28, 2017
@realark realark added this to the 0.2.12 milestone Dec 28, 2017
@realark realark requested a review from tylerbenson December 28, 2017 02:40
@realark realark force-pushed the ark/agent_test_framework branch from 28d8e05 to 1a80e44 Compare December 28, 2017 17:49
* in an initialized state.
* </ul>
*/
@SpecMetadata(filename = "AgentTestRunner.java", line = 0)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just out of curiosity... what does this line do?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Spock expects subclasses of spock.lang.Specification to have this annotation; adding it allows us to extend Specification from a java class.

Copy link
Contributor

@tylerbenson tylerbenson left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice work!

@realark realark merged commit cd0cc3b into master Jan 2, 2018
@realark realark deleted the ark/agent_test_framework branch January 2, 2018 17:11
@PerfectSlayer PerfectSlayer added comp: tooling Build & Tooling and removed dev/tooling labels Jun 23, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

comp: tooling Build & Tooling inst: others All other instrumentations type: enhancement Enhancements and improvements

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants