redundant type composite literal
This commit is contained in:
parent
420d527926
commit
8ffd0d59f6
3 changed files with 10 additions and 10 deletions
|
|
@ -95,12 +95,12 @@ func Test_resolvedRemotes_triangularSetup(t *testing.T) {
|
||||||
},
|
},
|
||||||
Network: api.RepoNetworkResult{
|
Network: api.RepoNetworkResult{
|
||||||
Repositories: []*api.Repository{
|
Repositories: []*api.Repository{
|
||||||
&api.Repository{
|
{
|
||||||
Name: "NEWNAME",
|
Name: "NEWNAME",
|
||||||
Owner: api.RepositoryOwner{Login: "NEWOWNER"},
|
Owner: api.RepositoryOwner{Login: "NEWOWNER"},
|
||||||
ViewerPermission: "READ",
|
ViewerPermission: "READ",
|
||||||
},
|
},
|
||||||
&api.Repository{
|
{
|
||||||
Name: "REPO",
|
Name: "REPO",
|
||||||
Owner: api.RepositoryOwner{Login: "MYSELF"},
|
Owner: api.RepositoryOwner{Login: "MYSELF"},
|
||||||
ViewerPermission: "ADMIN",
|
ViewerPermission: "ADMIN",
|
||||||
|
|
@ -163,7 +163,7 @@ func Test_resolvedRemotes_forkLookup(t *testing.T) {
|
||||||
},
|
},
|
||||||
Network: api.RepoNetworkResult{
|
Network: api.RepoNetworkResult{
|
||||||
Repositories: []*api.Repository{
|
Repositories: []*api.Repository{
|
||||||
&api.Repository{
|
{
|
||||||
Name: "NEWNAME",
|
Name: "NEWNAME",
|
||||||
Owner: api.RepositoryOwner{Login: "NEWOWNER"},
|
Owner: api.RepositoryOwner{Login: "NEWOWNER"},
|
||||||
ViewerPermission: "READ",
|
ViewerPermission: "READ",
|
||||||
|
|
@ -196,7 +196,7 @@ func Test_resolvedRemotes_clonedFork(t *testing.T) {
|
||||||
},
|
},
|
||||||
Network: api.RepoNetworkResult{
|
Network: api.RepoNetworkResult{
|
||||||
Repositories: []*api.Repository{
|
Repositories: []*api.Repository{
|
||||||
&api.Repository{
|
{
|
||||||
Name: "REPO",
|
Name: "REPO",
|
||||||
Owner: api.RepositoryOwner{Login: "OWNER"},
|
Owner: api.RepositoryOwner{Login: "OWNER"},
|
||||||
ViewerPermission: "ADMIN",
|
ViewerPermission: "ADMIN",
|
||||||
|
|
|
||||||
|
|
@ -15,9 +15,9 @@ func Test_UncommittedChangeCount(t *testing.T) {
|
||||||
Output string
|
Output string
|
||||||
}
|
}
|
||||||
cases := []c{
|
cases := []c{
|
||||||
c{Label: "no changes", Expected: 0, Output: ""},
|
{Label: "no changes", Expected: 0, Output: ""},
|
||||||
c{Label: "one change", Expected: 1, Output: " M poem.txt"},
|
{Label: "one change", Expected: 1, Output: " M poem.txt"},
|
||||||
c{Label: "untracked file", Expected: 2, Output: " M poem.txt\n?? new.txt"},
|
{Label: "untracked file", Expected: 2, Output: " M poem.txt\n?? new.txt"},
|
||||||
}
|
}
|
||||||
|
|
||||||
teardown := run.SetPrepareCmd(func(*exec.Cmd) run.Runnable {
|
teardown := run.SetPrepareCmd(func(*exec.Cmd) run.Runnable {
|
||||||
|
|
|
||||||
|
|
@ -36,9 +36,9 @@ func Test_Translator(t *testing.T) {
|
||||||
tr := m.Translator()
|
tr := m.Translator()
|
||||||
|
|
||||||
cases := [][]string{
|
cases := [][]string{
|
||||||
[]string{"ssh://gh/o/r", "ssh://github.com/o/r"},
|
{"ssh://gh/o/r", "ssh://github.com/o/r"},
|
||||||
[]string{"ssh://github.com/o/r", "ssh://github.com/o/r"},
|
{"ssh://github.com/o/r", "ssh://github.com/o/r"},
|
||||||
[]string{"https://gh/o/r", "https://gh/o/r"},
|
{"https://gh/o/r", "https://gh/o/r"},
|
||||||
}
|
}
|
||||||
for _, c := range cases {
|
for _, c := range cases {
|
||||||
u, _ := url.Parse(c[0])
|
u, _ := url.Parse(c[0])
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue