(t *testing.T)
| 76 | } |
| 77 | |
| 78 | func TestPushBranch(t *testing.T) { |
| 79 | ctx := testutil.Context(t) |
| 80 | te := setup(t) |
| 81 | bc := te.Service |
| 82 | |
| 83 | rem := NewRemote(bc, te.Volume) |
| 84 | gitInit(t, te) |
| 85 | cmd(t, te, "git", "remote", "add", "test1", FmtURL(te.URL)) |
| 86 | for i := range 10 { |
| 87 | putFile(t, te, "file1.txt", fmt.Appendf(nil, "hello world %d", i)) |
| 88 | gitCommit(t, te, "file1.txt") |
| 89 | gitPush(t, te, "test1", "master") |
| 90 | } |
| 91 | |
| 92 | // check what's there |
| 93 | it, err := rem.OpenIterator(ctx) |
| 94 | require.NoError(t, err) |
| 95 | actualRefs, err := streams.Collect(ctx, it, 1<<20) |
| 96 | require.NoError(t, err) |
| 97 | require.Len(t, actualRefs, 1) |
| 98 | require.NoError(t, it.Close()) |
| 99 | } |
| 100 | |
| 101 | func TestPushPull(t *testing.T) { |
| 102 | te1 := setup(t) |
nothing calls this directly
no test coverage detected