dbgate-query-splitter
Advanced tools
Comparing version 4.10.4 to 4.10.5
@@ -36,3 +36,3 @@ "use strict"; | ||
flushBuffer() { | ||
const lineContext = Object.assign(Object.assign({}, this.context), { position: 0, currentCommandStart: 0, wasDataOnLine: false, source: this.lineBuffer, end: this.lineBuffer.length, streamPosition: this.context.streamPosition, line: this.context.line, column: this.context.column, commandStartPosition: this.context.commandStartPosition, commandStartLine: this.context.commandStartLine, commandStartColumn: this.context.commandStartColumn, noWhitePosition: this.context.noWhitePosition, noWhiteLine: this.context.noWhiteLine, noWhiteColumn: this.context.noWhiteColumn, trimCommandStartPosition: this.context.trimCommandStartPosition, trimCommandStartLine: this.context.trimCommandStartLine, trimCommandStartColumn: this.context.trimCommandStartColumn, wasDataInCommand: this.context.wasDataInCommand }); | ||
const lineContext = Object.assign(Object.assign({}, this.context), { position: 0, currentCommandStart: 0, wasDataOnLine: false, source: this.lineBuffer, end: this.lineBuffer.length, streamPosition: this.context.streamPosition, line: this.context.line, column: this.context.column, commandStartPosition: this.context.commandStartPosition, commandStartLine: this.context.commandStartLine, commandStartColumn: this.context.commandStartColumn, noWhitePosition: this.context.noWhitePosition, noWhiteLine: this.context.noWhiteLine, noWhiteColumn: this.context.noWhiteColumn, trimCommandStartPosition: this.context.trimCommandStartPosition, trimCommandStartLine: this.context.trimCommandStartLine, trimCommandStartColumn: this.context.trimCommandStartColumn, wasDataInCommand: this.context.wasDataInCommand, isCopyFromStdin: this.context.isCopyFromStdin, isCopyFromStdinCandidate: this.context.isCopyFromStdinCandidate }); | ||
(0, splitQuery_1.splitQueryLine)(lineContext); | ||
@@ -54,2 +54,4 @@ this.context.commandPart = lineContext.commandPart; | ||
this.context.wasDataInCommand = lineContext.wasDataInCommand; | ||
this.context.isCopyFromStdin = lineContext.isCopyFromStdin; | ||
this.context.isCopyFromStdinCandidate = lineContext.isCopyFromStdinCandidate; | ||
this.lineBuffer = ''; | ||
@@ -56,0 +58,0 @@ } |
@@ -66,1 +66,7 @@ "use strict"; | ||
})); | ||
test('pgdump test', () => __awaiter(void 0, void 0, void 0, function* () { | ||
console.log(process.cwd()); | ||
const fileStream = fs_1.default.createReadStream('sql/pgdump.sql', 'utf-8'); | ||
const output = yield streamToArray((0, splitQueryStream_1.splitQueryStream)(fileStream, Object.assign(Object.assign({}, options_1.postgreSplitterOptions), { copyFromStdin: true, returnRichInfo: true }))); | ||
expect(output['length']).toEqual(7); | ||
})); |
{ | ||
"version": "4.10.4", | ||
"version": "4.10.5", | ||
"name": "dbgate-query-splitter", | ||
@@ -4,0 +4,0 @@ "main": "lib/index.js", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
48581
1039