rm some silly logic, better comments

This commit is contained in:
zricethezav committed 2018-03-12 17:50:02 -05:00
1 parent fa498287b9
commit 8e59bf766a
7 files changed
+60 -83

No files matched your search

+8 -5
View File
@@ -5,13 +5,16 @@ import (
"testing"
)
func TestNewLocalRepo(t *testing.T) {
r := newLocalRepo("")
if r.path != "" {
func TestNewRepo(t *testing.T) {
// local mode
r := newRepo("repo", "", "some/repo")
if r.name != "repo" || r.path != "some/repo" {
t.Error()
}
r = newLocalRepo("some/path")
if r.name != "path" || r.path != "some/path" {
// repo/owner mode
r = newRepo("repo", "github.com/owner/repo", "some/repo")
if r.name != "repo" || r.path != "some/repo" {
t.Error()
}
}