@outputai/cli 0.7.1-next.ae5bab4.0 → 0.7.1-next.d67ad85.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -19,20 +19,20 @@ describe('proxy bootstrap', () => {
19
19
  });
20
20
  it('does nothing when no proxy env vars are set', async () => {
21
21
  const { bootstrapProxy } = await import('./proxy.js');
22
- bootstrapProxy();
22
+ await bootstrapProxy();
23
23
  expect(mockSetGlobalDispatcher).not.toHaveBeenCalled();
24
24
  });
25
25
  it('sets global dispatcher when HTTPS_PROXY is set', async () => {
26
26
  process.env.HTTPS_PROXY = 'http://proxy:8080';
27
27
  const { bootstrapProxy } = await import('./proxy.js');
28
- bootstrapProxy();
28
+ await bootstrapProxy();
29
29
  expect(MockEnvHttpProxyAgent).toHaveBeenCalled();
30
30
  expect(mockSetGlobalDispatcher).toHaveBeenCalledTimes(1);
31
31
  });
32
32
  it('sets global dispatcher when HTTP_PROXY is set', async () => {
33
33
  process.env.HTTP_PROXY = 'http://proxy:8080';
34
34
  const { bootstrapProxy } = await import('./proxy.js');
35
- bootstrapProxy();
35
+ await bootstrapProxy();
36
36
  expect(MockEnvHttpProxyAgent).toHaveBeenCalled();
37
37
  expect(mockSetGlobalDispatcher).toHaveBeenCalledTimes(1);
38
38
  });
@@ -40,7 +40,7 @@ describe('proxy bootstrap', () => {
40
40
  process.env.HTTPS_PROXY = 'not a url';
41
41
  const warnSpy = vi.spyOn(console, 'warn').mockImplementation(() => { });
42
42
  const { bootstrapProxy } = await import('./proxy.js');
43
- bootstrapProxy();
43
+ await bootstrapProxy();
44
44
  expect(mockSetGlobalDispatcher).not.toHaveBeenCalled();
45
45
  expect(warnSpy).toHaveBeenCalled();
46
46
  warnSpy.mockRestore();