renovate/lib/manager/terragrunt/util.spec.ts
2020-11-12 16:37:15 +01:00

26 lines
968 B
TypeScript

import { TerragruntDependencyTypes, getTerragruntDependencyType } from './util';
describe('lib/manager/terragrunt/extract', () => {
describe('getTerragruntDependencyType()', () => {
it('returns TerragruntDependencyTypes.terragrunt', () => {
expect(getTerragruntDependencyType('terraform')).toBe(
TerragruntDependencyTypes.terragrunt
);
});
it('returns TerragruntDependencyTypes.unknown', () => {
expect(getTerragruntDependencyType('unknown')).toBe(
TerragruntDependencyTypes.unknown
);
});
it('returns TerragruntDependencyTypes.unknown on empty string', () => {
expect(getTerragruntDependencyType('')).toBe(
TerragruntDependencyTypes.unknown
);
});
it('returns TerragruntDependencyTypes.unknown on string with random chars', () => {
expect(getTerragruntDependencyType('sdfsgdsfadfhfghfhgdfsdf')).toBe(
TerragruntDependencyTypes.unknown
);
});
});
});