(t *testing.T)
| 5 | ) |
| 6 | |
| 7 | func TestRemotePush(t *testing.T) { |
| 8 | t.Parallel() |
| 9 | repo := createBareTestRepo(t) |
| 10 | defer cleanupTestRepo(t, repo) |
| 11 | |
| 12 | localRepo := createTestRepo(t) |
| 13 | defer cleanupTestRepo(t, localRepo) |
| 14 | |
| 15 | remote, err := localRepo.Remotes.Create("test_push", repo.Path()) |
| 16 | checkFatal(t, err) |
| 17 | defer remote.Free() |
| 18 | |
| 19 | seedTestRepo(t, localRepo) |
| 20 | |
| 21 | err = remote.Push([]string{"refs/heads/master"}, nil) |
| 22 | checkFatal(t, err) |
| 23 | |
| 24 | ref, err := localRepo.References.Lookup("refs/remotes/test_push/master") |
| 25 | checkFatal(t, err) |
| 26 | defer ref.Free() |
| 27 | |
| 28 | ref, err = repo.References.Lookup("refs/heads/master") |
| 29 | checkFatal(t, err) |
| 30 | defer ref.Free() |
| 31 | } |
nothing calls this directly
no test coverage detected
searching dependent graphs…