mirror of
https://github.com/cypress-io/cypress.git
synced 2026-05-03 21:40:28 -05:00
Verify downloaded test runner zip file 812 (#4193)
* if download has checksum use it to verify downloaded file * check only filesize if no checksum available * add download tests * move checksum into util for reuse, be explicit * add comments explaining headers used to verify checksum * move hasha to dev dependency * remove unnecessary function * do not use deprecated Promise.join with spread * fix promise join callback * linting
This commit is contained in:
committed by
Zach Bloomquist
parent
bfec784e7a
commit
c57d302176
@@ -96,7 +96,7 @@ setChecksum = (filename, key) =>
|
||||
la(check.unemptyString(filename), 'expected filename', filename)
|
||||
la(check.unemptyString(key), 'expected uploaded S3 key', key)
|
||||
|
||||
checksum = hasha.fromFileSync(filename)
|
||||
checksum = hasha.fromFileSync(filename, { algorithm: 'sha512' })
|
||||
size = fs.statSync(filename).size
|
||||
console.log('SHA256 checksum %s', checksum)
|
||||
console.log('size', size)
|
||||
|
||||
Reference in New Issue
Block a user