(ctx context.Context, t *testctx.T, c *dagger.Client, devEngine *dagger.Service)
| 139 | } |
| 140 | |
| 141 | func engineClientContainer(ctx context.Context, t *testctx.T, c *dagger.Client, devEngine *dagger.Service) *dagger.Container { |
| 142 | daggerCli := daggerCliFile(t, c) |
| 143 | |
| 144 | cliBinPath := "/bin/dagger" |
| 145 | endpoint, err := devEngine.Endpoint(ctx, dagger.ServiceEndpointOpts{Port: 1234, Scheme: "tcp"}) |
| 146 | require.NoError(t, err) |
| 147 | return c.Container().From(alpineImage). |
| 148 | WithServiceBinding("dev-engine", devEngine). |
| 149 | WithMountedFile(cliBinPath, daggerCli). |
| 150 | WithEnvVariable("_EXPERIMENTAL_DAGGER_CLI_BIN", cliBinPath). |
| 151 | WithEnvVariable("_EXPERIMENTAL_DAGGER_RUNNER_HOST", endpoint) |
| 152 | } |
| 153 | |
| 154 | // withNonNestedDevEngine configures a Container to use the same dev engine |
| 155 | // as the tests are running against but while avoiding use of a nested exec. |
no test coverage detected