1
0
mirror of https://github.com/rancher/os.git synced 2025-06-23 05:27:03 +00:00
os/util/util_test.go
Ivan Mikushin ad832471a1 isolate and mark platform dependent code
now unit tests compile on OS X and (some of them) work
2015-07-17 16:43:09 +05:00

23 lines
447 B
Go

package util
import (
"github.com/stretchr/testify/require"
"strings"
"testing"
)
func TestLoadResourceSimple(t *testing.T) {
assert := require.New(t)
expected := `services:
- debian-console
- ubuntu-console
`
expected = strings.TrimSpace(expected)
b, e := LoadResource("https://raw.githubusercontent.com/rancherio/os-services/v0.3.4/index.yml", true, []string{})
assert.Nil(e)
assert.Equal(expected, strings.TrimSpace(string(b)))
}