Skip to content

ref: Tidy up types and remove string coercion#1536

Merged
thomasrockhu-codecov merged 3 commits intomainfrom
nick/tidy-up-context-types
Aug 12, 2024
Merged

ref: Tidy up types and remove string coercion#1536
thomasrockhu-codecov merged 3 commits intomainfrom
nick/tidy-up-context-types

Conversation

@nicholas-codecov
Copy link
Copy Markdown

This PR adds in a package to give the correct types for GH payload events, as well this PR removes redundant string coercion that's not needed.

@codecov
Copy link
Copy Markdown

codecov Bot commented Aug 8, 2024

Codecov Report

Attention: Patch coverage is 90.90909% with 6 lines in your changes missing coverage. Please review.

Project coverage is 92.92%. Comparing base (943cea1) to head (5694bb0).

Files Patch % Lines
src/buildExec.ts 90.90% 6 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1536      +/-   ##
==========================================
+ Coverage   91.66%   92.92%   +1.25%     
==========================================
  Files           5        5              
  Lines         324      325       +1     
  Branches       86       77       -9     
==========================================
+ Hits          297      302       +5     
+ Misses         27       21       -6     
- Partials        0        2       +2     
Flag Coverage Δ
demo 92.92% <90.90%> (+1.25%) ⬆️
macos-latest 92.92% <90.90%> (+1.25%) ⬆️
script 92.92% <90.90%> (+1.25%) ⬆️
ubuntu-latest 92.92% <90.90%> (+1.25%) ⬆️
version 92.92% <90.90%> (+1.25%) ⬆️
windows-latest 92.92% <90.90%> (+1.25%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Comment thread src/buildExec.ts Outdated
Comment on lines +36 to +38
['pull_request', 'pull_request_target'].every(
(event) => event !== context.eventName,
)
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Suggested change
['pull_request', 'pull_request_target'].every(
(event) => event !== context.eventName,
)
!['pull_request', 'pull_request_target'].includes(context.eventName)

similar to below

Copy link
Copy Markdown
Author

@nicholas-codecov nicholas-codecov Aug 9, 2024

Choose a reason for hiding this comment

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

Ahhh yea that would be better ... i spent a hot minute looking at MDN docs trying to figure out the "smart" way ... and all i needed was a ! 🤦

@thomasrockhu-codecov thomasrockhu-codecov merged commit d2bac1a into main Aug 12, 2024
@thomasrockhu-codecov thomasrockhu-codecov deleted the nick/tidy-up-context-types branch August 12, 2024 17:25
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