mirror of
https://github.com/atom/atom.git
synced 2026-01-22 13:28:01 -05:00
fix timeout
This commit is contained in:
@@ -370,7 +370,7 @@ describe("CommandRegistry", () => {
|
||||
registry.add('.grandchild', 'command', () => 1);
|
||||
registry.add('.grandchild', 'command', () => Promise.resolve(2));
|
||||
registry.add('.grandchild', 'command', () => new Promise((resolve) => {
|
||||
setTimeout(() => { resolve(3); }, 100);
|
||||
global.setTimeout(() => { resolve(3); }, 100);
|
||||
}));
|
||||
|
||||
const values = await registry.dispatch(grandchild, 'command');
|
||||
@@ -381,7 +381,7 @@ describe("CommandRegistry", () => {
|
||||
registry.add('.grandchild', 'command', () => 1);
|
||||
registry.add('.grandchild', 'command', () => Promise.resolve(2));
|
||||
registry.add('.grandchild', 'command', () => new Promise((resolve, reject) => {
|
||||
setTimeout(() => { reject(3); }, 100);
|
||||
global.setTimeout(() => { reject(3); }, 100);
|
||||
}));
|
||||
|
||||
let value;
|
||||
|
||||
Reference in New Issue
Block a user