diff options
author | Máximo Cuadros <mcuadros@gmail.com> | 2016-09-07 02:04:43 +0200 |
---|---|---|
committer | Máximo Cuadros <mcuadros@gmail.com> | 2016-09-07 02:04:43 +0200 |
commit | 56adb5be3ad26a0045ea6c6a6d24dafdff15ba1c (patch) | |
tree | bd8ecbb6674f01f03f97fb15083bed0a3e8e021d /blame_test.go | |
parent | 98a22e72a808aa0d5dd62339817404fd9e1c4db6 (diff) | |
download | go-git-56adb5be3ad26a0045ea6c6a6d24dafdff15ba1c.tar.gz |
format: packfile new interface
Diffstat (limited to 'blame_test.go')
-rw-r--r-- | blame_test.go | 10 |
1 files changed, 2 insertions, 8 deletions
diff --git a/blame_test.go b/blame_test.go index a8f7ae1..c4cdc85 100644 --- a/blame_test.go +++ b/blame_test.go @@ -1,8 +1,6 @@ package git import ( - "bytes" - "io/ioutil" "os" "gopkg.in/src-d/go-git.v4/core" @@ -26,15 +24,11 @@ func (s *BlameCommon) SetUpSuite(c *C) { f, err := os.Open(fixRepo.packfile) c.Assert(err, IsNil) - data, err := ioutil.ReadAll(f) - c.Assert(err, IsNil) - - stream := packfile.NewStream(bytes.NewReader(data)) + stream := packfile.NewScanner(f) d := packfile.NewDecoder(stream, r.s.ObjectStorage()) - err = d.Decode() + _, err = d.Decode() c.Assert(err, IsNil) - c.Assert(f.Close(), IsNil) s.repos[fixRepo.url] = r |