From d250293c2e0a4a50f5ef6b4b6cd3257730338d13 Mon Sep 17 00:00:00 2001
From: shrutip90 <shruti.p90@gmail.com>
Date: Tue, 19 Aug 2025 21:20:41 -0700
Subject: Ignore workspace settings for untrusted folders (#6606)

---
 packages/cli/src/test-utils/render.tsx | 9 ++++++++-
 1 file changed, 8 insertions(+), 1 deletion(-)

(limited to 'packages/cli/src/test-utils/render.tsx')

diff --git a/packages/cli/src/test-utils/render.tsx b/packages/cli/src/test-utils/render.tsx
index 05b92532..111bc5ff 100644
--- a/packages/cli/src/test-utils/render.tsx
+++ b/packages/cli/src/test-utils/render.tsx
@@ -7,12 +7,19 @@
 import { render } from 'ink-testing-library';
 import React from 'react';
 import { KeypressProvider } from '../ui/contexts/KeypressContext.js';
+import { SettingsContext } from '../ui/contexts/SettingsContext.js';
+import { LoadedSettings } from '../config/settings.js';
 
 export const renderWithProviders = (
   component: React.ReactElement,
+  settings?: LoadedSettings,
 ): ReturnType<typeof render> =>
   render(
     <KeypressProvider kittyProtocolEnabled={true}>
-      {component}
+      <SettingsContext.Provider
+        value={{ settings: settings!, recomputeSettings: () => {} }}
+      >
+        {component}
+      </SettingsContext.Provider>
     </KeypressProvider>,
   );
-- 
cgit v1.2.3

