Skip to content

Commit

Permalink
Indicate progress when testing bigger files
Browse files Browse the repository at this point in the history
  • Loading branch information
felixge committed Jan 11, 2015
1 parent e9ebeb0 commit 842cfa1
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions xxd_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ package main
import (
"bytes"
"flag"
"fmt"
"io"
"io/ioutil"
"os/exec"
Expand All @@ -24,6 +25,7 @@ func TestXXD(t *testing.T) {
test := func(fn func(r io.Reader, w io.Writer) error) func(n uint64) []string {
return func(n uint64) []string {
size := n % uint64(len(data))
fmt.Printf("%d\n", size)
var out bytes.Buffer
if err := fn(bytes.NewBuffer(data[0:size]), &out); err != nil {
return []string{err.Error()}
Expand Down

0 comments on commit 842cfa1

Please sign in to comment.