test(async): extend #1013 coverage to cross-module property-return shape#1068
Merged
Conversation
Per PR #1064 review (@andrewtdiz): the original gscmaster-api repro used cross-module imported async helpers that awaited an inner lookup and returned a property read off the resolved value (`return user.accessToken`). The previous test only pinned the same-file literal-return shape, which covers the dispatch bug but not the exact reported async/module/property boundary. Added `test-files/fixtures/issue_1013/user_lookup.ts` exporting `getAccessToken` / `getUserPlan` against an inner `await lookupUser(id)`, returning property reads. The test now destructures both shapes from `Promise.all` and verifies byte-for-byte parity with Node.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Follow-up to PR #1064 per @andrewtdiz's review feedback (comment).
PR #1064 pinned the same-file literal-return shape — covers the dispatch bug. The original gscmaster-api repro from #1013 used cross-module imported async helpers that awaited an inner lookup and returned a property read off the resolved value (
return user.accessToken). That shape isn't exercised by the previous test.This PR adds
test-files/fixtures/issue_1013/user_lookup.tsexportinggetAccessToken/getUserPlanagainst an innerawait lookupUser(id), each returning a property read. The test now destructures both shapes fromPromise.all:Verified byte-for-byte against
node --experimental-strip-types.No version bump or changelog change.