(c *C)
| 2067 | } |
| 2068 | |
| 2069 | func (s *RepositorySuite) TestLogInvalidFile(c *C) { |
| 2070 | r, _ := Init(memory.NewStorage(), nil) |
| 2071 | err := r.clone(context.Background(), &CloneOptions{ |
| 2072 | URL: s.GetBasicLocalRepositoryURL(), |
| 2073 | }) |
| 2074 | c.Assert(err, IsNil) |
| 2075 | |
| 2076 | // Throwing in a file that does not exist |
| 2077 | fileName := "vendor/foo12.go" |
| 2078 | cIter, err := r.Log(&LogOptions{FileName: &fileName}) |
| 2079 | // Not raising an error since `git log -- vendor/foo12.go` responds silently |
| 2080 | c.Assert(err, IsNil) |
| 2081 | defer cIter.Close() |
| 2082 | |
| 2083 | _, err = cIter.Next() |
| 2084 | c.Assert(err, Equals, io.EOF) |
| 2085 | } |
| 2086 | |
| 2087 | func (s *RepositorySuite) TestLogFileInitialCommit(c *C) { |
| 2088 | r, _ := Init(memory.NewStorage(), nil) |
nothing calls this directly
no test coverage detected