Skip to content

Add a type test verifying #922 is resolved by #878#923

Merged
seratch merged 2 commits intoslackapi:mainfrom
seratch:issue-922
May 19, 2021
Merged

Add a type test verifying #922 is resolved by #878#923
seratch merged 2 commits intoslackapi:mainfrom
seratch:issue-922

Conversation

@seratch
Copy link
Copy Markdown
Contributor

@seratch seratch commented May 17, 2021

Summary

This pull request adds a type test verifying #922 is resolved by #878 pull request.

Requirements (place an x in each [ ])

@seratch seratch added tests M-T: Testing work only TypeScript-specific area:examples issues related to example or sample code labels May 17, 2021
@seratch seratch added this to the 3.4.0 milestone May 17, 2021
@seratch seratch self-assigned this May 17, 2021
@codecov
Copy link
Copy Markdown

codecov bot commented May 17, 2021

Codecov Report

Merging #923 (0f8f789) into main (61dbfa7) will not change coverage.
The diff coverage is n/a.

❗ Current head 0f8f789 differs from pull request most recent head 542b38f. Consider uploading reports for the commit 542b38f to get more accurate results
Impacted file tree graph

@@           Coverage Diff           @@
##             main     #923   +/-   ##
=======================================
  Coverage   66.22%   66.22%           
=======================================
  Files          13       13           
  Lines        1205     1205           
  Branches      355      355           
=======================================
  Hits          798      798           
  Misses        338      338           
  Partials       69       69           

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 61dbfa7...542b38f. Read the comment docs.

let options = [];
// Collect information in options array to send in Slack ack response
for (const result in results) {
for (const result of results) {
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

While adding the code in tests, I found that this is an obvious bug.

// Example of responding to an external_select options request
app.options('external_action', async ({ options, ack }) => {
// Get information specific to a team or channel
// (modified to satisfy TS compiler)
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

modified for TS compilation - no need to do the same in JS


if (results) {
// (modified to satisfy TS compiler)
let options: Option[] = [];
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

just for TS compatibility

@seratch seratch merged commit 2c1a1e9 into slackapi:main May 19, 2021
@seratch seratch deleted the issue-922 branch May 19, 2021 08:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area:examples issues related to example or sample code tests M-T: Testing work only TypeScript-specific

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants