0
0
mirror of https://github.com/renovatebot/renovate.git synced 2024-12-22 13:38:32 +00:00
renovatebot_renovate/lib/util/git/config.spec.ts
2022-11-18 06:59:08 +00:00

27 lines
710 B
TypeScript

import { GlobalConfig } from '../../config/global';
import { simpleGitConfig } from './config';
describe('util/git/config', () => {
beforeEach(() => {
GlobalConfig.reset();
});
it('uses "close" events, ignores "exit" events from child processes', () => {
expect(simpleGitConfig()).toEqual({
completion: { onClose: true, onExit: false },
config: ['core.quotePath=false'],
});
});
it('uses timeout value from GlobalConfig', () => {
GlobalConfig.set({ gitTimeout: 50000 });
expect(simpleGitConfig()).toEqual({
completion: { onClose: true, onExit: false },
timeout: {
block: 50000,
},
config: ['core.quotePath=false'],
});
});
});