Compare commits
2 Commits
Author | SHA1 | Date | |
---|---|---|---|
|
38d643e12b | ||
|
0411db0443 |
@@ -8,8 +8,6 @@ services:
|
|||||||
- docker
|
- docker
|
||||||
|
|
||||||
go:
|
go:
|
||||||
- 1.11.x
|
|
||||||
- 1.12.x
|
|
||||||
- 1.13.x
|
- 1.13.x
|
||||||
- tip
|
- tip
|
||||||
|
|
||||||
@@ -28,12 +26,12 @@ script:
|
|||||||
jobs:
|
jobs:
|
||||||
include:
|
include:
|
||||||
- stage: Fuzz regression
|
- stage: Fuzz regression
|
||||||
go: 1.12.x
|
go: 1.13.x
|
||||||
dist: bionic
|
dist: bionic
|
||||||
script: ./fuzzit.sh local-regression
|
script: ./fuzzit.sh local-regression
|
||||||
- stage: Fuzz
|
- stage: Fuzz
|
||||||
if: branch = master AND type IN (push)
|
if: branch = master AND type IN (push)
|
||||||
go: 1.12.x
|
go: 1.13.x
|
||||||
dist: bionic
|
dist: bionic
|
||||||
script: ./fuzzit.sh fuzzing
|
script: ./fuzzit.sh fuzzing
|
||||||
|
|
||||||
@@ -56,5 +54,5 @@ deploy:
|
|||||||
skip_cleanup: true
|
skip_cleanup: true
|
||||||
on:
|
on:
|
||||||
tags: true
|
tags: true
|
||||||
go: 1.12.x
|
go: 1.13.x
|
||||||
overwrite: true
|
overwrite: true
|
@@ -1,5 +1,5 @@
|
|||||||
# Default to Go 1.12
|
# Default to Go 1.13
|
||||||
ARG GO_VERSION=1.12
|
ARG GO_VERSION=1.13
|
||||||
FROM golang:${GO_VERSION}-alpine as build
|
FROM golang:${GO_VERSION}-alpine as build
|
||||||
|
|
||||||
# Necessary to run 'go get' and to compile the linked binary
|
# Necessary to run 'go get' and to compile the linked binary
|
||||||
|
@@ -32,28 +32,20 @@ func FuzzLocalStorage(fuzz []byte) int {
|
|||||||
panic("unable to save file")
|
panic("unable to save file")
|
||||||
}
|
}
|
||||||
|
|
||||||
contentType, contentLength, err := storage.Head(token, filename)
|
contentLength, err := storage.Head(token, filename)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
panic("not visible through head")
|
panic("not visible through head")
|
||||||
}
|
}
|
||||||
|
|
||||||
if contentType != applicationOctetStream {
|
|
||||||
panic("incorrect content type")
|
|
||||||
}
|
|
||||||
|
|
||||||
if contentLength != fuzzLength {
|
if contentLength != fuzzLength {
|
||||||
panic("incorrect content length")
|
panic("incorrect content length")
|
||||||
}
|
}
|
||||||
|
|
||||||
output, contentType, contentLength, err := storage.Get(token, filename)
|
output, contentLength, err := storage.Get(token, filename)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
panic("not visible through get")
|
panic("not visible through get")
|
||||||
}
|
}
|
||||||
|
|
||||||
if contentType != applicationOctetStream {
|
|
||||||
panic("incorrect content type")
|
|
||||||
}
|
|
||||||
|
|
||||||
if contentLength != fuzzLength {
|
if contentLength != fuzzLength {
|
||||||
panic("incorrect content length")
|
panic("incorrect content length")
|
||||||
}
|
}
|
||||||
@@ -81,7 +73,7 @@ func FuzzLocalStorage(fuzz []byte) int {
|
|||||||
panic("unable to delete file")
|
panic("unable to delete file")
|
||||||
}
|
}
|
||||||
|
|
||||||
_, _, err = storage.Head(token, filename)
|
_, err = storage.Head(token, filename)
|
||||||
if !storage.IsNotExist(err) {
|
if !storage.IsNotExist(err) {
|
||||||
panic("file not deleted")
|
panic("file not deleted")
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user