use Harness.IO instead of sys in harness#4394
Conversation
|
ok, something is broken I need to re-run tests on Linux box since on Windows machine everything works fine |
|
The browser stuff in package.json is so that webpack/browserify don't shim those modules. They're not actually needed at runtime in the browser and shimming them just adds to the filesize without actually doing anything. |
|
I'm ok with putting back 'fs', 'os' and 'path' since these modules should not be used in tests. However currently test harness uses 'buffer' so it needs to be shimmed. It can be re-added to 'package.json' if there is a way to tell browserify cli to either ignore 'package.json' or include some module if even if it was skipped in "browser" section - after few minutes of experimenting I have not found it. |
|
pinging @mhegazy |
Gotcha. +1, I think this is much better than rolling back #4308 |
|
👍 |
use Harness.IO instead of sys in harness
alternative fix for #4359.
It is ok for
systo be undefined since it is just an implementation detail of the default version ofCompilerHost. Compiler and language service can already handle this. However test harness still usessysall over the place, in this PR usages ofsysin tests were replaced withHarness.IO. Also I've kept onlyfsin 'package.json' since this is the only module we use that is not shimmed by the 'webpack'.