Unverified Commit a8d83123 authored by Steven Allen's avatar Steven Allen Committed by GitHub

Merge pull request #6 from petroav/enable-tests

Enable tests
parents 058210c5 d0927c2e
sudo: false os:
- linux
language: go language: go
go: go:
- 1.9.x - 1.11.x
install: install:
- make deps - make deps
...@@ -17,3 +18,5 @@ cache: ...@@ -17,3 +18,5 @@ cache:
notifications: notifications:
email: false email: false
env: GOTFLAGS="-race"
gx:
go get github.com/whyrusleeping/gx
go get github.com/whyrusleeping/gx-go
deps: gx
gx --verbose install --global
gx-go rewrite
publish:
gx-go rewrite --undo
...@@ -2,6 +2,9 @@ go-buffer-pool ...@@ -2,6 +2,9 @@ go-buffer-pool
================== ==================
[![](https://img.shields.io/badge/made%20by-Protocol%20Labs-blue.svg?style=flat-square)](https://protocol.ai) [![](https://img.shields.io/badge/made%20by-Protocol%20Labs-blue.svg?style=flat-square)](https://protocol.ai)
[![](https://img.shields.io/badge/project-libp2p-blue.svg?style=flat-square)](https://libp2p.io/)
[![](https://img.shields.io/badge/freenode-%23libp2p-blue.svg?style=flat-square)](https://webchat.freenode.net/?channels=%23libp2p)
[![codecov](https://codecov.io/gh/libp2p/go-buffer-pool/branch/master/graph/badge.svg)](https://codecov.io/gh/libp2p/go-buffer-pool)
[![Travis CI](https://travis-ci.org/libp2p/go-buffer-pool.svg?branch=master)](https://travis-ci.org/libp2p/go-buffer-pool) [![Travis CI](https://travis-ci.org/libp2p/go-buffer-pool.svg?branch=master)](https://travis-ci.org/libp2p/go-buffer-pool)
> A variable size buffer pool for go. > A variable size buffer pool for go.
......
coverage:
range: "50...100"
comment: off
...@@ -27,7 +27,7 @@ func TestAllocations(t *testing.T) { ...@@ -27,7 +27,7 @@ func TestAllocations(t *testing.T) {
runtime.GC() runtime.GC()
runtime.ReadMemStats(&m2) runtime.ReadMemStats(&m2)
frees := m2.Frees - m1.Frees frees := m2.Frees - m1.Frees
if frees > 100 { if frees > 1000 {
t.Fatalf("expected less than 100 frees after GC, got %d", frees) t.Fatalf("expected less than 100 frees after GC, got %d", frees)
} }
} }
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment