Clarify variable names.
This commit is contained in:
@@ -48,12 +48,12 @@ let rubyChange: Change = {
|
|||||||
|
|
||||||
test('hasInvalidLicenses fails a licenses outside the allow list is found', async () => {
|
test('hasInvalidLicenses fails a licenses outside the allow list is found', async () => {
|
||||||
const changes: Changes = [npmChange, rubyChange]
|
const changes: Changes = [npmChange, rubyChange]
|
||||||
const result = hasInvalidLicenses(changes, ['BSD'], [])
|
const invalidChanges = hasInvalidLicenses(changes, {allow: ['BSD']})
|
||||||
expect(result[0]).toBe(npmChange)
|
expect(invalidChanges[0]).toBe(npmChange)
|
||||||
})
|
})
|
||||||
|
|
||||||
test('hasInvalidLicenses fails if a denied license is found', async () => {
|
test('hasInvalidLicenses fails if a denied license is found', async () => {
|
||||||
const changes: Changes = [npmChange, rubyChange]
|
const changes: Changes = [npmChange, rubyChange]
|
||||||
const result = hasInvalidLicenses(changes, [], ['BSD'])
|
const invalidChanges = hasInvalidLicenses(changes, {deny: ['BSD']})
|
||||||
expect(result[0]).toBe(rubyChange)
|
expect(invalidChanges[0]).toBe(rubyChange)
|
||||||
})
|
})
|
||||||
|
|||||||
Reference in New Issue
Block a user