mirror of
https://github.com/google-gemini/gemini-cli.git
synced 2026-04-09 04:41:19 -07:00
feat(settings): rename negative settings to positive naming (disable* -> enable*) (#14142)
Co-authored-by: jacob314 <jacob314@gmail.com>
This commit is contained in:
@@ -34,7 +34,7 @@ describe('checkForUpdates', () => {
|
||||
mockSettings = {
|
||||
merged: {
|
||||
general: {
|
||||
disableUpdateNag: false,
|
||||
enableAutoUpdateNotification: true,
|
||||
},
|
||||
},
|
||||
} as LoadedSettings;
|
||||
@@ -45,8 +45,8 @@ describe('checkForUpdates', () => {
|
||||
vi.restoreAllMocks();
|
||||
});
|
||||
|
||||
it('should return null if disableUpdateNag is true', async () => {
|
||||
mockSettings.merged.general.disableUpdateNag = true;
|
||||
it('should return null if enableAutoUpdateNotification is false', async () => {
|
||||
mockSettings.merged.general.enableAutoUpdateNotification = false;
|
||||
const result = await checkForUpdates(mockSettings);
|
||||
expect(result).toBeNull();
|
||||
expect(getPackageJson).not.toHaveBeenCalled();
|
||||
|
||||
@@ -51,7 +51,7 @@ export async function checkForUpdates(
|
||||
settings: LoadedSettings,
|
||||
): Promise<UpdateObject | null> {
|
||||
try {
|
||||
if (settings.merged.general.disableUpdateNag) {
|
||||
if (!settings.merged.general.enableAutoUpdateNotification) {
|
||||
return null;
|
||||
}
|
||||
// Skip update check when running from source (development mode)
|
||||
|
||||
Reference in New Issue
Block a user