1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27
|
package command
import (
"testing"
"github.com/isacikgoz/gitbatch/internal/git"
"github.com/stretchr/testify/require"
)
func TestMerge(t *testing.T) {
th := git.InitTestRepositoryFromLocal(t)
defer th.CleanUp(t)
opts := &MergeOptions{
BranchName: th.Repository.State.Branch.Upstream.Name,
}
var tests = []struct {
inp1 *git.Repository
inp2 *MergeOptions
}{
{th.Repository, opts},
}
for _, test := range tests {
err := Merge(test.inp1, test.inp2)
require.NoError(t, err)
}
}
|