git-lfs/commands/version_test.go

25 lines
577 B
Go
Raw Normal View History

2014-06-04 17:40:09 +00:00
package commands
import (
"fmt"
2015-03-19 19:30:55 +00:00
"github.com/github/git-lfs/lfs"
2014-06-04 17:40:09 +00:00
"testing"
)
func TestVersionOnEmptyRepository(t *testing.T) {
repo := NewRepository(t, "empty")
2014-06-04 18:57:20 +00:00
defer repo.Test()
repo.AddPath(repo.Path, ".git")
repo.AddPath(repo.Path, "subdir")
2014-06-04 17:40:09 +00:00
cmd := repo.Command("version")
2015-03-19 19:30:55 +00:00
cmd.Output = lfs.UserAgent
2014-06-04 17:40:09 +00:00
2014-06-26 21:00:51 +00:00
cmd = repo.Command("version", "--comics")
2015-03-19 19:30:55 +00:00
cmd.Output = fmt.Sprintf("%s\nNothing may see Gah Lak Tus and survive!", lfs.UserAgent)
2014-06-26 21:00:51 +00:00
cmd = repo.Command("version", "-c")
2015-03-19 19:30:55 +00:00
cmd.Output = fmt.Sprintf("%s\nNothing may see Gah Lak Tus and survive!", lfs.UserAgent)
2014-06-04 17:40:09 +00:00
}