fix: internalModuleReadJSON for unpacked JSON (#26749)

This commit is contained in:
Vadim 2020-12-02 11:33:39 +06:00 committed by GitHub
parent c2909a3b8d
commit efca7007b6
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 2 deletions

View file

@ -1444,7 +1444,8 @@ describe('asar package', function () {
it('reads a normal file with unpacked files', function () {
const p = path.join(asarDir, 'unpack.asar', 'a.txt');
expect(internalModuleReadJSON(p).toString().trim()).to.equal('a');
const [s, c] = internalModuleReadJSON(p);
expect([s.toString().trim(), c]).to.eql(['a', true]);
});
});