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(dev): Add placeholder tsconfigs for tests #5200

Merged
merged 1 commit into from
Jun 3, 2022

Conversation

lobsterkatie
Copy link
Member

Note: This is an exact duplicate of #5169, which accidentally got merged into the 7.x branch rather than master.

It is well-documented (1, 2, 3, 4, 5, 6) that VSCode doesn't support setups like ours, where multiple tsconfig files coexist in a single directory. Strangely, though, it is only recently that this has become a problem, with VSCode at random intervals forgetting that it's ever heard of expect or describe (because it's not seeing tsconfig.test.json, but taking a while to realize it).

There is an open issue tracking the addition of support for this, but it's been open for a long time, with little movement. In the meantime, this solves the problem by adding placeholder test/tsconfig.json files to each package, each pointing to its corresponding tsconfig.test.ts file. I went with this approach over simply moving and renaming the existing test tsconfigs because this allows us to stay consistent in having all flavors of tsconfig for a package live at the package root level, and provides an easy way to reverse this workaround, should VSCode ever fix the underlying problem.

@github-actions
Copy link
Contributor

github-actions bot commented Jun 3, 2022

size-limit report 📦

Path Size
@sentry/browser - ES5 CDN Bundle (gzipped + minified) 19.35 KB (-3.94% 🔽)
@sentry/browser - ES5 CDN Bundle (minified) 59.96 KB (-7.2% 🔽)
@sentry/browser - ES6 CDN Bundle (gzipped + minified) 18.17 KB (-3.66% 🔽)
@sentry/browser - ES6 CDN Bundle (minified) 53.58 KB (-7.57% 🔽)
@sentry/browser - Webpack (gzipped + minified) 19.95 KB (-14.16% 🔽)
@sentry/browser - Webpack (minified) 64.95 KB (-20.52% 🔽)
@sentry/react - Webpack (gzipped + minified) 19.97 KB (-14.2% 🔽)
@sentry/nextjs Client - Webpack (gzipped + minified) 43.7 KB (-9.06% 🔽)
@sentry/browser + @sentry/tracing - ES5 CDN Bundle (gzipped + minified) 25.35 KB (-2.77% 🔽)
@sentry/browser + @sentry/tracing - ES6 CDN Bundle (gzipped + minified) 23.88 KB (-2.48% 🔽)

@lobsterkatie lobsterkatie merged commit d48f6fd into master Jun 3, 2022
@lobsterkatie lobsterkatie deleted the kmclb-fix-test-tsconfigs branch June 3, 2022 19:35
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.

None yet

2 participants