test: fixed input_test.go

Signed-off-by: Sam Alba <sam.alba@gmail.com>
This commit is contained in:
Sam Alba 2021-04-02 17:32:05 -07:00
parent ce6ce871ab
commit a79e13a35c

View File

@ -10,13 +10,13 @@ func TestInputDir(t *testing.T) {
st := &DeploymentState{ st := &DeploymentState{
PlanSource: DirInput("/tmp/source", []string{}), PlanSource: DirInput("/tmp/source", []string{}),
} }
require.NoError(t, st.SetInput("www.source", DirInput(".", []string{}))) require.NoError(t, st.SetInput("www.source", DirInput("/", []string{})))
deployment, err := NewDeployment(st) deployment, err := NewDeployment(st)
require.NoError(t, err) require.NoError(t, err)
localdirs := deployment.LocalDirs() localdirs := deployment.LocalDirs()
require.Len(t, localdirs, 2) require.Len(t, localdirs, 2)
require.Contains(t, localdirs, ".") require.Contains(t, localdirs, "/")
require.Contains(t, localdirs, "/tmp/source") require.Contains(t, localdirs, "/tmp/source")
} }