0
0
Fork 0
mirror of https://github.com/renovatebot/renovate.git synced 2025-01-11 13:48:55 +00:00
renovatebot_renovate/lib/config/migrations/custom/automerge-minor-migration.spec.ts
2023-11-07 15:50:29 +00:00

47 lines
1,016 B
TypeScript

import { AutomergeMinorMigration } from './automerge-minor-migration';
describe('config/migrations/custom/automerge-minor-migration', () => {
it('should migrate value to object', () => {
expect(AutomergeMinorMigration).toMigrate(
{
automergeMinor: 'some-value',
},
{
minor: {
automerge: true,
},
},
);
});
it('should migrate value to object and concat with existing minor object', () => {
expect(AutomergeMinorMigration).toMigrate(
{
automergeMinor: 'some-value',
minor: {
matchFileNames: ['test'],
},
},
{
minor: {
automerge: true,
matchFileNames: ['test'],
},
},
);
});
it('should ignore non object minor value', () => {
expect(AutomergeMinorMigration).toMigrate(
{
automergeMinor: 'some-value',
minor: null,
},
{
minor: {
automerge: true,
},
},
);
});
});