Reduce test file size

This commit is contained in:
Leonid Bugaev
2015-07-11 19:07:35 +05:00
parent 6ba0bfc614
commit 32d0557a28
+4 -4
View File
@@ -158,7 +158,7 @@ func TestInputRAWLargePayload(t *testing.T) {
quit := make(chan int)
// Generate 200kb file
dd := exec.Command("dd", "if=/dev/urandom", "of=/tmp/large", "bs=1KB", "count=200")
dd := exec.Command("dd", "if=/dev/urandom", "of=/tmp/large", "bs=1KB", "count=100")
err := dd.Run()
if err != nil {
log.Fatal("dd error:", err)
@@ -169,7 +169,7 @@ func TestInputRAWLargePayload(t *testing.T) {
defer req.Body.Close()
body, _ := ioutil.ReadAll(req.Body)
if len(body) != 200*1000 {
if len(body) != 100*1000 {
t.Error("File size should be 1mb:", len(body))
}
@@ -185,8 +185,8 @@ func TestInputRAWLargePayload(t *testing.T) {
n, _ := req.Body.Read(buf)
body := buf[0:n]
if len(body) != 200*1000 {
t.Error("File size should be 200000 bytes:", len(body))
if len(body) != 100*1000 {
t.Error("File size should be 100000 bytes:", len(body))
}
wg.Done()