feat: Show untrusted status in the Footer (#6210)

Co-authored-by: Jacob Richman <jacob314@gmail.com>
This commit is contained in:
shrutip90
2025-08-14 11:15:48 -07:00
committed by GitHub
parent 69d666cfaf
commit 69c5582723
10 changed files with 221 additions and 60 deletions

View File

@@ -1809,7 +1809,14 @@ describe('loadCliConfig trustedFolder', () => {
description,
} of testCases) {
it(`should be correct for: ${description}`, async () => {
(isWorkspaceTrusted as vi.Mock).mockReturnValue(mockTrustValue);
(isWorkspaceTrusted as vi.Mock).mockImplementation(
(settings: Settings) => {
const featureIsEnabled =
(settings.folderTrustFeature ?? false) &&
(settings.folderTrust ?? true);
return featureIsEnabled ? mockTrustValue : true;
},
);
const argv = await parseArguments();
const settings: Settings = { folderTrustFeature, folderTrust };
const config = await loadCliConfig(settings, [], 'test-session', argv);