Skip to content
This repository has been archived by the owner on May 27, 2022. It is now read-only.

Commit

Permalink
more tests, fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
caarlos0 committed Sep 5, 2015
1 parent 5381737 commit 895db31
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 3 deletions.
7 changes: 4 additions & 3 deletions antibody_test.go
Expand Up @@ -5,16 +5,17 @@ import (
"testing"

"github.com/caarlos0/antibody"
"github.com/caarlos0/antibody/bundle"
"github.com/caarlos0/antibody/internal"
"github.com/stretchr/testify/assert"
)

func TestBundleAndUpdate(t *testing.T) {
home := internal.TempHome()
defer os.RemoveAll(home)
a := antibody.New([]antibody.Bundle{
antibody.NewBundle("caarlos0/zsh-pg", home),
antibody.NewBundle("caarlos0/zsh-open-pr", home),
a := antibody.New([]bundle.Bundle{
bundle.New("caarlos0/zsh-pg", home),
bundle.New("caarlos0/zsh-open-pr", home),
})
a.Download()
a.Update()
Expand Down
8 changes: 8 additions & 0 deletions bundle/bundle_test.go
Expand Up @@ -24,6 +24,14 @@ func TestSourceablesWithoutDownload(t *testing.T) {
assert.Empty(t, b.Sourceables())
}

func TestSourceablesDotSh(t *testing.T) {
home := internal.TempHome()
defer os.RemoveAll(home)
b := bundle.New("rupa/z", home)
b.Download()
assert.Len(t, b.Sourceables(), 1)
}

func TestListEmptyFolder(t *testing.T) {
home := internal.TempHome()
defer os.RemoveAll(home)
Expand Down

0 comments on commit 895db31

Please sign in to comment.