@@ -1091,7 +1091,7 @@ describe("scripts/crabbox-wrapper", () => {
10911091 ) ;
10921092 } ) ;
10931093
1094- it ( "honors direct-cloud debugging during automatic readiness checks" , ( ) => {
1094+ it ( "ignores direct-cloud debugging during automatic readiness checks" , ( ) => {
10951095 const result = runWrapper (
10961096 "provider: aws, azure, blacksmith-testbox, or daytona\n" ,
10971097 [ "run" , "--workload" , "desktop" , "--" , "echo ok" ] ,
@@ -1104,9 +1104,10 @@ describe("scripts/crabbox-wrapper", () => {
11041104 } ,
11051105 ) ;
11061106
1107- expect ( result . status ) . toBe ( 0 ) ;
1108- expect ( parseFakeCrabboxOutput ( result ) . args ) . toContain ( "azure" ) ;
1109- expect ( result . stderr ) . toContain ( "selected=azure" ) ;
1107+ expect ( result . status ) . toBe ( 2 ) ;
1108+ expect ( result . stdout ) . toBe ( "" ) ;
1109+ expect ( result . stderr ) . toContain ( "no ready provider for workload=desktop" ) ;
1110+ expect ( result . stderr ) . toContain ( "managed Crabbox broker auth unavailable" ) ;
11101111 } ) ;
11111112
11121113 it ( "keeps workload configuration away from administrative commands" , ( ) => {
@@ -1234,22 +1235,23 @@ describe("scripts/crabbox-wrapper", () => {
12341235 expect ( parseFakeCrabboxOutput ( result ) . args ) . toContain ( "daytona" ) ;
12351236 } ) ;
12361237
1237- it ( "allows automatic direct Daytona routing on older Crabbox versions " , ( ) => {
1238+ it ( "does not allow direct cloud overrides inside workload routing " , ( ) => {
12381239 const result = runWrapper (
12391240 "provider: aws, azure, blacksmith-testbox, or daytona\n" ,
12401241 [ "run" , "--workload" , "interactive" , "--" , "echo ok" ] ,
12411242 {
12421243 configJson : { coordinator : "" , brokerAuth : "missing" } ,
12431244 env : {
1244- OPENCLAW_FAKE_CRABBOX_VERSION : "crabbox 0.39.9 " ,
1245+ OPENCLAW_FAKE_CRABBOX_VERSION : "crabbox 0.40.0 " ,
12451246 OPENCLAW_CRABBOX_ALLOW_DIRECT_CLOUD : "1" ,
12461247 } ,
12471248 } ,
12481249 ) ;
12491250
1250- expect ( result . status ) . toBe ( 0 ) ;
1251- expect ( parseFakeCrabboxOutput ( result ) . args ) . toContain ( "daytona" ) ;
1252- expect ( result . stderr ) . toContain ( "selected=daytona" ) ;
1251+ expect ( result . status ) . toBe ( 2 ) ;
1252+ expect ( result . stdout ) . toBe ( "" ) ;
1253+ expect ( result . stderr ) . toContain ( "no ready provider for workload=interactive" ) ;
1254+ expect ( result . stderr ) . toContain ( "managed Crabbox broker auth unavailable" ) ;
12531255 } ) ;
12541256
12551257 it ( "fails closed when no policy provider is ready" , ( ) => {
0 commit comments