Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Include parameters in logged test name #22303

Merged
merged 1 commit into from
Mar 22, 2024

Conversation

rschlussel
Copy link
Contributor

@rschlussel rschlussel commented Mar 22, 2024

Include method parameters in the test name used in LogTestDurationListener. This fixes the listener when there are multiple tests in the same class with the same name, but different numbers of parameters.

Also updated the same named tests to have different names because it is better for tests to use distinct names.

Fixes: #20807

Description

Include method parameters in the test name used in LogTestDurationListener.
Also updated the same named tests to have different names because it is better for tests to use distinct names

Previously the name would look like:

com.facebook.presto.orc.metadata.statistics.TestMapColumnStatisticsBuilder::testAddMapStatisticsNoValues

Now it will look like:

com.facebook.presto.orc.metadata.statistics.TestMapColumnStatisticsBuilder::testAddMapStatisticsNoValues([Lcom.facebook.presto.orc.proto.DwrfProto$KeyInfo;)

Motivation and Context

This fixes the listener when there are multiple tests in the same class with the same name, but different numbers of parameters.

Fixes #20807

Impact

n/a

Test Plan

CI

Contributor checklist

  • Please make sure your submission complies with our development, formatting, commit message, and attribution guidelines.
  • PR description addresses the issue accurately and concisely. If the change is non-trivial, a GitHub Issue is referenced.
  • Documented new properties (with its default value), SQL syntax, functions, or other functionality.
  • If release notes are required, they follow the release notes guidelines.
  • Adequate tests were added if applicable.
  • CI passed.

Release Notes

== NO RELEASE NOTE ==

@rschlussel rschlussel requested review from sdruzkin and a team as code owners March 22, 2024 17:18
@rschlussel rschlussel requested a review from presto-oss March 22, 2024 17:18
Include method parameters in the test name used in
LogTestDurationListener.  This fixes the listener when there are
multiple tests in the same class with the same name, but different
numbers of parameters.

Also updated the same named tests to have different names because it is
better for tests to use distinct names.

Fixes: prestodb#20807
@rschlussel rschlussel force-pushed the fix-duration-listener branch from a05976f to 31c3c23 Compare March 22, 2024 17:36
@rschlussel rschlussel merged commit 7e37ed6 into prestodb:master Mar 22, 2024
56 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
3 participants