mirror of
https://github.com/renovatebot/renovate.git
synced 2024-12-22 13:38:32 +00:00
46 lines
1.4 KiB
TypeScript
46 lines
1.4 KiB
TypeScript
import { partial } from '../../../../test/util';
|
|
import type { CustomManager } from '../../../modules/manager/custom/types';
|
|
import { CustomManagersMigration } from './custom-managers-migration';
|
|
|
|
describe('config/migrations/custom/custom-managers-migration', () => {
|
|
it('migrates', () => {
|
|
expect(CustomManagersMigration).toMigrate(
|
|
{
|
|
customManagers: partial<CustomManager>([
|
|
{
|
|
fileMatch: ['js', '***$}{]]['],
|
|
matchStrings: ['^(?<depName>foo)(?<currentValue>bar)$'],
|
|
datasourceTemplate: 'maven',
|
|
versioningTemplate: 'gradle',
|
|
},
|
|
{
|
|
customType: 'regex',
|
|
fileMatch: ['js', '***$}{]]['],
|
|
matchStrings: ['^(?<depName>foo)(?<currentValue>bar)$'],
|
|
datasourceTemplate: 'maven',
|
|
versioningTemplate: 'gradle',
|
|
},
|
|
]),
|
|
},
|
|
{
|
|
customManagers: [
|
|
{
|
|
customType: 'regex',
|
|
fileMatch: ['js', '***$}{]]['],
|
|
matchStrings: ['^(?<depName>foo)(?<currentValue>bar)$'],
|
|
datasourceTemplate: 'maven',
|
|
versioningTemplate: 'gradle',
|
|
},
|
|
{
|
|
customType: 'regex',
|
|
fileMatch: ['js', '***$}{]]['],
|
|
matchStrings: ['^(?<depName>foo)(?<currentValue>bar)$'],
|
|
datasourceTemplate: 'maven',
|
|
versioningTemplate: 'gradle',
|
|
},
|
|
],
|
|
},
|
|
);
|
|
});
|
|
});
|