diff --git a/lib/workers/repository/index.spec.ts b/lib/workers/repository/index.spec.ts index 0f78d87efb6f6d01d48bb3ee4530f3c77658c2cc..0768a1b5aff159c73b22f02c2368ab76e2cff7b3 100644 --- a/lib/workers/repository/index.spec.ts +++ b/lib/workers/repository/index.spec.ts @@ -19,7 +19,7 @@ describe('workers/repository', () => { config = getConfig(); }); it('runs', async () => { - process.processRepo.mockResolvedValue(mock<ExtractResult>()); + process.extractDependencies.mockResolvedValue(mock<ExtractResult>()); const res = await renovateRepository(config); expect(res).toMatchSnapshot(); }); diff --git a/lib/workers/repository/index.ts b/lib/workers/repository/index.ts index 9f952c8ead23bb362acd52311d30fcdf293f76da..9e68bbb8d835d16147ee9ca8187748a69161c1b1 100644 --- a/lib/workers/repository/index.ts +++ b/lib/workers/repository/index.ts @@ -8,7 +8,7 @@ import { finaliseRepo } from './finalise'; import { initRepo } from './init'; import { ensureMasterIssue } from './master-issue'; import { ensureOnboardingPr } from './onboarding/pr'; -import { processRepo, updateRepo } from './process'; +import { extractDependencies, updateRepo } from './process'; import { ProcessResult, processResult } from './result'; let renovateVersion = 'unknown'; @@ -32,7 +32,9 @@ export async function renovateRepository( await fs.ensureDir(config.localDir); logger.debug('Using localDir: ' + config.localDir); config = await initRepo(config); - const { branches, branchList, packageFiles } = await processRepo(config); + const { branches, branchList, packageFiles } = await extractDependencies( + config + ); await ensureOnboardingPr(config, packageFiles, branches); const res = await updateRepo(config, branches, branchList); if (res !== 'automerged') { diff --git a/lib/workers/repository/process/index.spec.ts b/lib/workers/repository/process/index.spec.ts index f89830223b6b9962b57c2495c6c3a0bcb06dd4b6..0b7bff3105b7b7430eaa0649095f3c35dbb12c8a 100644 --- a/lib/workers/repository/process/index.spec.ts +++ b/lib/workers/repository/process/index.spec.ts @@ -1,6 +1,6 @@ import { RenovateConfig, getConfig, mocked } from '../../../../test/util'; import * as _extractUpdate from './extract-update'; -import { processRepo, updateRepo } from './index'; +import { extractDependencies, updateRepo } from './index'; jest.mock('./extract-update'); @@ -15,13 +15,13 @@ beforeEach(() => { describe('workers/repository/process/index', () => { describe('processRepo()', () => { it('processes single branches', async () => { - const res = await processRepo(config); + const res = await extractDependencies(config); expect(res).toMatchSnapshot(); }); it('processes baseBranches', async () => { extract.mockResolvedValue({} as never); config.baseBranches = ['branch1', 'branch2']; - const res = await processRepo(config); + const res = await extractDependencies(config); await updateRepo(config, res.branches, res.branchList); expect(res).toMatchSnapshot(); }); diff --git a/lib/workers/repository/process/index.ts b/lib/workers/repository/process/index.ts index 6b986d2e9699f547b5a5119fc86a35e5b75b5883..83da8bc043548ca7a97f03218244d8408ee0e5b4 100644 --- a/lib/workers/repository/process/index.ts +++ b/lib/workers/repository/process/index.ts @@ -6,7 +6,7 @@ import { BranchConfig } from '../../common'; import { ExtractResult, extract, update } from './extract-update'; import { WriteUpdateResult } from './write'; -export async function processRepo( +export async function extractDependencies( config: RenovateConfig ): Promise<ExtractResult> { logger.debug('processRepo()');