Updating readConfig() to be more readable, get rid of typecasts.

Co-authored-by: Henri Maurer <[email protected]>
This commit is contained in:
Federico Builes
2022-06-14 11:29:13 +02:00
co-authored by Henri Maurer
parent f83a407eb9
commit fd6e756c7b
4 changed files with 38 additions and 42 deletions
-6
View File
@@ -41,9 +41,3 @@ test('it raises an error when given an unknown severity', async () => {
process.env['INPUT_FAIL-ON-SEVERITY'] = 'zombies!'
expect(() => readConfig()).toThrow()
})
test('it works on uppercase severities', async () => {
process.env['INPUT_FAIL-ON-SEVERITY'] = 'CRITICAL'
const options = readConfig()
expect(options.fail_on_severity).toEqual('critical')
})