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

fix(ui): Add missing 'return' statement in <StructuredEventData /> #71148

Merged
merged 2 commits into from
May 23, 2024

Conversation

floels
Copy link
Contributor

@floels floels commented May 18, 2024

Goal

The goal of this PR is to add a missing return statement in the declaration of the <StructuredEventData /> component in static/app/components/structuredEventData/index.tsx.

Approach

We also add a test in the existing test file (index.spec.tsx) to cover the corresponding use case (multiline strings). You can check that this test fails if you remove the fix in index.tsx.

Legal Boilerplate

Look, I get it. The entity doing business as "Sentry" was incorporated in the State of Delaware in 2015 as Functional Software, Inc. and is gonna need some rights from me in order to utilize my contributions in this here PR. So here's the deal: I retain all rights, title and interest in and to my contributions, and by keeping this boilerplate intact I confirm that Sentry can use, modify, copy, and redistribute my contributions, under Sentry's choice of terms.

Add a missing 'return' statement in the declaration of the <StructuredEventData />
component in 'static/app/components/structuredEventData/index.tsx'. Add a test
to cover the corresponding use case (multiline strings).
@github-actions github-actions bot added the Scope: Frontend Automatically applied to PRs that change frontend components label May 18, 2024
</Wrapper>;
return (
<Wrapper>
<ValueMultiLineString data-test-id="value-multiline-string">
Copy link
Contributor Author

Choose a reason for hiding this comment

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

We also add a test id for the purpose of the test added in index.spec.tsx above.

Copy link

codecov bot commented May 18, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 77.87%. Comparing base (3e186d5) to head (e882b19).

Additional details and impacted files
@@           Coverage Diff           @@
##           master   #71148   +/-   ##
=======================================
  Coverage   77.87%   77.87%           
=======================================
  Files        6538     6538           
  Lines      291213   291213           
  Branches    50389    50389           
=======================================
  Hits       226792   226792           
  Misses      58184    58184           
  Partials     6237     6237           
Files Coverage Δ
...tatic/app/components/structuredEventData/index.tsx 96.22% <100.00%> (ø)

@HazAT HazAT enabled auto-merge (squash) May 23, 2024 09:25
@lforst lforst added the Trigger: getsentry tests once code is reviewed: apply label to PR to trigger getsentry tests label May 23, 2024
@HazAT HazAT merged commit 42ccc4a into getsentry:master May 23, 2024
42 of 44 checks passed
Copy link

sentry-io bot commented May 23, 2024

Suspect Issues

This pull request was deployed and Sentry observed the following issues:

  • ‼️ TestingLibraryElementError: Unable to find an accessible element with the role "link" Object.?(index.spec.tsx) View Issue

Did you find this useful? React with a 👍 or 👎

@github-actions github-actions bot locked and limited conversation to collaborators Jun 8, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Scope: Frontend Automatically applied to PRs that change frontend components Trigger: getsentry tests once code is reviewed: apply label to PR to trigger getsentry tests
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants