Upload Kmake

This commit is contained in:
Gorochu
2026-05-26 23:36:42 -07:00
parent ba051b2f74
commit 555ec72358
41615 changed files with 13344630 additions and 1 deletions

View File

@ -0,0 +1,25 @@
'use strict';
require('../common');
// A package.json with an empty "main" property should use index.js if present.
// require.resolve() should resolve to index.js for the same reason.
//
// In fact, any "main" property that doesn't resolve to a file should result
// in index.js being used, but that's already checked for by other tests.
// This test only concerns itself with the empty string.
const assert = require('assert');
const path = require('path');
const fixtures = require('../common/fixtures');
const where = fixtures.path('require-empty-main');
const expected = path.join(where, 'index.js');
test();
setImmediate(test);
function test() {
assert.strictEqual(require.resolve(where), expected);
assert.strictEqual(require(where), 42);
assert.strictEqual(require.resolve(where), expected);
}