Should return provider correctly with artifacts from other builders or pp's

This commit is contained in:
DanHam 2019-08-21 13:36:50 +01:00
parent e8336039d9
commit e9ab2203ba
No known key found for this signature in database
GPG Key ID: 58E79AEDD6AA987E
1 changed files with 8 additions and 0 deletions

View File

@ -404,6 +404,14 @@ func TestGetProvider_artifice(t *testing.T) {
t.Logf("Expected provider '%s'. Got provider '%s'", expectedProvider, provider)
}
func TestGetProvider_other(t *testing.T) {
expectedProvider := "virtualbox"
provider, _ := getProvider(expectedProvider, "foo.box", "other")
assert.Equal(t, expectedProvider, provider, "Error: Expected provider: '%s'. Got '%s'", expectedProvider, provider)
t.Logf("Expected provider '%s'. Got provider '%s'", expectedProvider, provider)
}
func newBoxFile() (boxfile *os.File, err error) {
boxfile, err = ioutil.TempFile(os.TempDir(), "test*.box")
if err != nil {