airshipctl/pkg/container/container_test.go
Dmitry Ukov b37b6f3703 [AIR-137] Add logic to isogen subcommand
* Add add default values for isogen subcommand keys
* Introduce container interface
* Implement docker driver
* Add stdin support to container interface
* Implement volume mount for container

Change-Id: Ide0ecd474b1ccce358bdc9c85ef0006f230490b5
2019-11-01 12:27:35 +00:00

22 lines
445 B
Go

package container
import (
"context"
"fmt"
"testing"
"github.com/stretchr/testify/assert"
)
func TestNewContainer(t *testing.T) {
ctx := context.Background()
_, actualErr := NewContainer(&ctx, "test_drv", "")
expectedErr := ErrContainerDrvNotSupported{Driver: "test_drv"}
errS := fmt.Sprintf(
"Call NewContainer should have returned error %s, got %s",
expectedErr,
actualErr,
)
assert.Equal(t, actualErr, expectedErr, errS)
}