add a regression test for when engine returns a export fail (#3407)
* add a regression test for when engine returns a export fail Signed-off-by: Jess Frazelle <github@jessfraz.com> * better errors Signed-off-by: Jess Frazelle <github@jessfraz.com> --------- Signed-off-by: Jess Frazelle <github@jessfraz.com>
This commit is contained in:
@ -952,6 +952,7 @@ class EngineConnection extends EventTarget {
|
||||
) {
|
||||
// Reject the promise with the error.
|
||||
this.engineCommandManager.pendingExport.reject(errorsString)
|
||||
toast.error(errorsString)
|
||||
this.engineCommandManager.pendingExport = undefined
|
||||
}
|
||||
} else {
|
||||
@ -1315,7 +1316,7 @@ export class EngineCommandManager extends EventTarget {
|
||||
commandLogs: CommandLog[] = []
|
||||
pendingExport?: {
|
||||
resolve: (a: null) => void
|
||||
reject: (reason: any) => void
|
||||
reject: (reason: string) => void
|
||||
commandId: string
|
||||
}
|
||||
settings: SettingsViaQueryString
|
||||
@ -1911,8 +1912,9 @@ export class EngineCommandManager extends EventTarget {
|
||||
const promise = new Promise<null>((resolve, reject) => {
|
||||
this.pendingExport = {
|
||||
resolve,
|
||||
reject: () => {
|
||||
reject: (reason: string) => {
|
||||
this.exportIntent = null
|
||||
reject(reason)
|
||||
},
|
||||
commandId: command.cmd_id,
|
||||
}
|
||||
|
Reference in New Issue
Block a user