| 372 | } |
| 373 | |
| 374 | func (s *SuiteCommit) TestCommitIterNext(c *C) { |
| 375 | i := s.Commit.Parents() |
| 376 | |
| 377 | commit, err := i.Next() |
| 378 | c.Assert(err, IsNil) |
| 379 | c.Assert(commit.ID().String(), Equals, "35e85108805c84807bc66a02d91535e1e24b38b9") |
| 380 | |
| 381 | commit, err = i.Next() |
| 382 | c.Assert(err, IsNil) |
| 383 | c.Assert(commit.ID().String(), Equals, "a5b8b09e2f8fcb0bb99d3ccb0958157b40890d69") |
| 384 | |
| 385 | commit, err = i.Next() |
| 386 | c.Assert(err, Equals, io.EOF) |
| 387 | c.Assert(commit, IsNil) |
| 388 | } |
| 389 | |
| 390 | func (s *SuiteCommit) TestLongCommitMessageSerialization(c *C) { |
| 391 | encoded := &plumbing.MemoryObject{} |