tsenart/vegeta — pull request #54 by xla (2014-04-30 18:25:29+00:00)
Title: NewMetrics panics if it receives an empty slice of results

When `NewMetrics` is called with an empty slice of results it panics with the following error:

```
panic: runtime error: index out of range

goroutine 15 [running]:
runtime.panic(0x28dbc0, 0x5d75b7)
/usr/local/Cellar/go/1.2.1/libexec/src/pkg/runtime/panic.c:266 +0xb6
testing.func·005()
/usr/local/Cellar/go/1.2.1/libexec/src/pkg/testing/testing.go:385 +0xe8
runtime.panic(0x28dbc0, 0x5d75b7)
/usr/local/Cellar/go/1.2.1/libexec/src/pkg/runtime/panic.c:248 +0x106
github.com/xla/vegeta/lib.NewMetrics(0x11a5f38, 0x0, 0x0, 0x11a5f60)
/Users/alx/dev/src/github.com/xla/vegeta/lib/metrics.go:65 +0x7bd
```

I added a stub test for the behaviour.