(t *testing.T)
| 31 | } |
| 32 | |
| 33 | func TestGetConfigDetailsStdin(t *testing.T) { |
| 34 | content := ` |
| 35 | version: "3.0" |
| 36 | services: |
| 37 | foo: |
| 38 | image: alpine:3.5 |
| 39 | ` |
| 40 | details, err := getConfigDetails([]string{"-"}, strings.NewReader(content)) |
| 41 | assert.NilError(t, err) |
| 42 | cwd, err := os.Getwd() |
| 43 | assert.NilError(t, err) |
| 44 | assert.Check(t, is.Equal(cwd, details.WorkingDir)) |
| 45 | assert.Assert(t, is.Len(details.ConfigFiles, 1)) |
| 46 | assert.Check(t, is.Equal("3.0", details.ConfigFiles[0].Config["version"])) |
| 47 | assert.Check(t, is.Len(details.Environment, len(os.Environ()))) |
| 48 | } |
| 49 | |
| 50 | func TestBuildEnvironment(t *testing.T) { |
| 51 | inputEnv := []string{ |
nothing calls this directly
no test coverage detected
searching dependent graphs…