(c *C)
| 1640 | } |
| 1641 | |
| 1642 | func (s *RepositorySuite) TestPushContext(c *C) { |
| 1643 | url := c.MkDir() |
| 1644 | |
| 1645 | _, err := PlainInit(url, true) |
| 1646 | c.Assert(err, IsNil) |
| 1647 | |
| 1648 | _, err = s.Repository.CreateRemote(&config.RemoteConfig{ |
| 1649 | Name: "foo", |
| 1650 | URLs: []string{url}, |
| 1651 | }) |
| 1652 | c.Assert(err, IsNil) |
| 1653 | |
| 1654 | ctx, cancel := context.WithCancel(context.Background()) |
| 1655 | cancel() |
| 1656 | |
| 1657 | err = s.Repository.PushContext(ctx, &PushOptions{ |
| 1658 | RemoteName: "foo", |
| 1659 | }) |
| 1660 | c.Assert(err, NotNil) |
| 1661 | } |
| 1662 | |
| 1663 | // installPreReceiveHook installs a pre-receive hook in the .git |
| 1664 | // directory at path which prints message m before exiting |
nothing calls this directly
no test coverage detected