Correct error instantiation
This commit is contained in:
@@ -9,7 +9,7 @@ test.concurrent('getLinks gives a valid ILinks class', async () => {
|
||||
links instanceof LinuxLinks || links instanceof WindowsLinks
|
||||
).toBeTruthy()
|
||||
} catch (error) {
|
||||
throw new Error(error)
|
||||
throw new Error(`Error getting links: ${error}`)
|
||||
// Other OS
|
||||
}
|
||||
})
|
||||
|
||||
@@ -11,7 +11,7 @@ test.concurrent.each<Method>(['local', 'network'])(
|
||||
expect(version).toBeInstanceOf(SemVer)
|
||||
expect(version.compare(new SemVer(versionString))).toBe(0)
|
||||
} catch (error) {
|
||||
throw new Error(error)
|
||||
throw new Error(`Error parsing version: ${error}`)
|
||||
// Other OS
|
||||
}
|
||||
}
|
||||
@@ -37,7 +37,7 @@ test.concurrent.each<Method>(['local', 'network'])(
|
||||
`Version not available: ${versionString}`
|
||||
)
|
||||
} catch (error) {
|
||||
throw new Error(error)
|
||||
throw new Error(`Error checking version availability: ${error}`)
|
||||
// Other OS
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user