@prisma/generator-helper
Advanced tools
Comparing version 0.0.9 to 0.0.11
@@ -44,7 +44,9 @@ "use strict"; | ||
describe('generatorHandler', () => { | ||
test('not executable', () => __awaiter(void 0, void 0, void 0, function* () { | ||
expect(() => { | ||
const generator = new GeneratorProcess_1.GeneratorProcess(path_1.default.join(__dirname, 'not-executable')); | ||
}).toThrow('is not executable'); | ||
})); | ||
// test('not executable', async () => { | ||
// expect(() => { | ||
// const generator = new GeneratorProcess( | ||
// path.join(__dirname, 'not-executable'), | ||
// ) | ||
// }).toThrow('is not executable') | ||
// }) | ||
test('parsing error', () => __awaiter(void 0, void 0, void 0, function* () { | ||
@@ -51,0 +53,0 @@ const generator = new GeneratorProcess_1.GeneratorProcess(path_1.default.join(__dirname, 'invalid-executable')); |
@@ -18,3 +18,2 @@ "use strict"; | ||
const fs_1 = __importDefault(require("fs")); | ||
const path_1 = __importDefault(require("path")); | ||
const chalk_1 = __importDefault(require("chalk")); | ||
@@ -40,5 +39,2 @@ let globalMessageId = 1; | ||
} | ||
if (!hasChmodX(executablePath)) { | ||
throw new Error(`${chalk_1.default.bold(executablePath)} is not executable. Please run ${chalk_1.default.greenBright(`chmod +x ${path_1.default.relative(process.cwd(), executablePath)}`)}`); | ||
} | ||
} | ||
@@ -45,0 +41,0 @@ init() { |
{ | ||
"name": "@prisma/generator-helper", | ||
"version": "0.0.9", | ||
"version": "0.0.11", | ||
"main": "dist/index.js", | ||
@@ -5,0 +5,0 @@ "types": "dist/index.d.ts", |
@@ -33,9 +33,9 @@ import { GeneratorProcess } from '../GeneratorProcess' | ||
describe('generatorHandler', () => { | ||
test('not executable', async () => { | ||
expect(() => { | ||
const generator = new GeneratorProcess( | ||
path.join(__dirname, 'not-executable'), | ||
) | ||
}).toThrow('is not executable') | ||
}) | ||
// test('not executable', async () => { | ||
// expect(() => { | ||
// const generator = new GeneratorProcess( | ||
// path.join(__dirname, 'not-executable'), | ||
// ) | ||
// }).toThrow('is not executable') | ||
// }) | ||
test('parsing error', async () => { | ||
@@ -42,0 +42,0 @@ const generator = new GeneratorProcess( |
@@ -31,12 +31,2 @@ import { ChildProcessByStdio, spawn } from 'child_process' | ||
} | ||
if (!hasChmodX(executablePath)) { | ||
throw new Error( | ||
`${chalk.bold( | ||
executablePath, | ||
)} is not executable. Please run ${chalk.greenBright( | ||
`chmod +x ${path.relative(process.cwd(), executablePath)}`, | ||
)}`, | ||
) | ||
} | ||
} | ||
@@ -43,0 +33,0 @@ async init() { |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
57260
1357