Adding a test to confirm lists work properly in config files.

This commit is contained in:
Federico Builes
2022-11-15 22:25:26 +01:00
parent 1dd7392739
commit ba127cac5e

View File

@@ -250,4 +250,14 @@ describe('licenses that are not valid SPDX licenses', () => {
'Invalid license(s) in deny-licenses: BSD, GPL 2'
)
})
test('it supports comma-separated license lists', async () => {
setInput(
'config-file',
'./__tests__/fixtures/inline-license-config-sample.yml'
)
let config = await readConfig()
expect(config.allow_licenses).toEqual(['BSD', 'GPL 2'])
})
})