aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGravatar Aliaksandr Valialkin <valyala@gmail.com> 2016-02-21 13:34:55 +0200
committerGravatar Aliaksandr Valialkin <valyala@gmail.com> 2016-02-21 13:34:55 +0200
commit21a70cc5b896808ce7626f0ac319909ce7273f7d (patch)
treecfb53b17b2448baf3caddee2c60c53d2a244aa1c
parentAdded RequestURI helper to Request (diff)
downloadfasthttp-21a70cc5b896808ce7626f0ac319909ce7273f7d.tar.gz
fasthttp-21a70cc5b896808ce7626f0ac319909ce7273f7d.tar.bz2
fasthttp-21a70cc5b896808ce7626f0ac319909ce7273f7d.zip
reduced the time required to run tests with race detector enabled
-rw-r--r--client_test.go12
-rw-r--r--fs_test.go2
2 files changed, 7 insertions, 7 deletions
diff --git a/client_test.go b/client_test.go
index 2329304..4617f87 100644
--- a/client_test.go
+++ b/client_test.go
@@ -454,8 +454,8 @@ func TestClientHTTPSConcurrent(t *testing.T) {
}
go func() {
defer wg.Done()
- testClientGet(t, &defaultClient, addr, 300)
- testClientPost(t, &defaultClient, addr, 100)
+ testClientGet(t, &defaultClient, addr, 30)
+ testClientPost(t, &defaultClient, addr, 10)
}()
}
wg.Wait()
@@ -512,8 +512,8 @@ func TestClientConcurrent(t *testing.T) {
wg.Add(1)
go func() {
defer wg.Done()
- testClientGet(t, &defaultClient, addr, 300)
- testClientPost(t, &defaultClient, addr, 100)
+ testClientGet(t, &defaultClient, addr, 30)
+ testClientPost(t, &defaultClient, addr, 10)
}()
}
wg.Wait()
@@ -548,8 +548,8 @@ func TestHostClientConcurrent(t *testing.T) {
wg.Add(1)
go func() {
defer wg.Done()
- testHostClientGet(t, c, 300)
- testHostClientPost(t, c, 100)
+ testHostClientGet(t, c, 30)
+ testHostClientPost(t, c, 10)
}()
}
wg.Wait()
diff --git a/fs_test.go b/fs_test.go
index 27ea0cc..5ec1d9c 100644
--- a/fs_test.go
+++ b/fs_test.go
@@ -326,7 +326,7 @@ func TestFSCompressConcurrent(t *testing.T) {
ch := make(chan struct{}, concurrency)
for i := 0; i < concurrency; i++ {
go func() {
- for j := 0; j < 10; j++ {
+ for j := 0; j < 5; j++ {
testFSCompress(t, h, "/fs.go")
testFSCompress(t, h, "/")
testFSCompress(t, h, "/README.md")