@@ -183,7 +183,7 @@ func TestDevcontainerCLI_ArgsAndParsing(t *testing.T) {
183
183
cmd : "echo" ,
184
184
cmdArgs : []string {"hello" },
185
185
opts : []agentcontainers.DevcontainerCLIExecOptions {agentcontainers .WithExecContainerID ("test-container-123" )},
186
- wantArgs : "exec --container-id test-container-123 echo hello" ,
186
+ wantArgs : "exec --workspace-folder /test/workspace -- container-id test-container-123 echo hello" ,
187
187
wantError : false ,
188
188
},
189
189
{
@@ -193,7 +193,7 @@ func TestDevcontainerCLI_ArgsAndParsing(t *testing.T) {
193
193
cmd : "bash" ,
194
194
cmdArgs : []string {"-c" , "ls -la" },
195
195
opts : []agentcontainers.DevcontainerCLIExecOptions {agentcontainers .WithExecContainerID ("my-container" )},
196
- wantArgs : "exec --container-id my-container --config /test/config.json bash -c ls -la" ,
196
+ wantArgs : "exec --workspace-folder /test/workspace --config /test/config.json --container-id my-container bash -c ls -la" ,
197
197
wantError : false ,
198
198
},
199
199
{
@@ -205,7 +205,7 @@ func TestDevcontainerCLI_ArgsAndParsing(t *testing.T) {
205
205
opts : []agentcontainers.DevcontainerCLIExecOptions {
206
206
agentcontainers .WithExecContainerID ("test-container-789" ),
207
207
},
208
- wantArgs : "exec --container-id test-container-789 cat /etc/hostname" ,
208
+ wantArgs : "exec --workspace-folder /test/workspace -- container-id test-container-789 cat /etc/hostname" ,
209
209
wantError : false ,
210
210
},
211
211
}
@@ -293,7 +293,7 @@ func TestDevcontainerCLI_WithOutput(t *testing.T) {
293
293
errBuf := & bytes.Buffer {}
294
294
295
295
// Simulate CLI execution for exec command with container ID.
296
- wantArgs := "exec --container-id test-container-456 echo hello"
296
+ wantArgs := "exec --workspace-folder /test/workspace -- container-id test-container-456 echo hello"
297
297
testExecer := & testDevcontainerExecer {
298
298
testExePath : testExePath ,
299
299
wantArgs : wantArgs ,
0 commit comments