mirror of
https://github.com/tiennm99/ccs.git
synced 2026-10-14 18:18:21 +00:00
style: format source and test files
This commit is contained in:
1 parent
f451f4e421
commit
539afea737
34 files changed
+486
-295
No files matched your search
@@ -39,7 +39,8 @@ describe('isFirstTimeInstall logic', () => {
|
||||
createConfigJson({ profiles: { glm: '~/.ccs/glm.settings.json' } });
|
||||
|
||||
const legacyConfig = JSON.parse(fs.readFileSync(path.join(testDir, 'config.json'), 'utf8'));
|
||||
const hasLegacyProfiles = legacyConfig.profiles && Object.keys(legacyConfig.profiles).length > 0;
|
||||
const hasLegacyProfiles =
|
||||
legacyConfig.profiles && Object.keys(legacyConfig.profiles).length > 0;
|
||||
|
||||
expect(hasLegacyProfiles).toBe(true);
|
||||
});
|
||||
@@ -48,8 +49,11 @@ describe('isFirstTimeInstall logic', () => {
|
||||
createConfigYaml('version: 2\nprofiles: {}\naccounts: {}');
|
||||
createProfilesJson({ profiles: { work: { path: '/some/path' } } });
|
||||
|
||||
const legacyProfiles = JSON.parse(fs.readFileSync(path.join(testDir, 'profiles.json'), 'utf8'));
|
||||
const hasLegacyAccounts = legacyProfiles.profiles && Object.keys(legacyProfiles.profiles).length > 0;
|
||||
const legacyProfiles = JSON.parse(
|
||||
fs.readFileSync(path.join(testDir, 'profiles.json'), 'utf8')
|
||||
);
|
||||
const hasLegacyAccounts =
|
||||
legacyProfiles.profiles && Object.keys(legacyProfiles.profiles).length > 0;
|
||||
|
||||
expect(hasLegacyAccounts).toBe(true);
|
||||
});
|
||||
@@ -105,7 +109,9 @@ cliproxy_server:
|
||||
createProfilesJson({ profiles: {} });
|
||||
|
||||
const legacyConfig = JSON.parse(fs.readFileSync(path.join(testDir, 'config.json'), 'utf8'));
|
||||
const legacyProfiles = JSON.parse(fs.readFileSync(path.join(testDir, 'profiles.json'), 'utf8'));
|
||||
const legacyProfiles = JSON.parse(
|
||||
fs.readFileSync(path.join(testDir, 'profiles.json'), 'utf8')
|
||||
);
|
||||
|
||||
const hasLegacyProfiles = Object.keys(legacyConfig.profiles || {}).length > 0;
|
||||
const hasLegacyAccounts = Object.keys(legacyProfiles.profiles || {}).length > 0;
|
||||
|
||||
Reference in new issue
Block a user