@@ -1804,6 +1804,36 @@ describe("orchestration v2 provider switching", () => {
18041804 [ "queued" , CLAUDE_MODEL_SELECTION . instanceId ] ,
18051805 ] ,
18061806 ) ;
1807+ yield * orchestrator . dispatch ( {
1808+ type : "message.dispatch" ,
1809+ createdBy : "agent" ,
1810+ creationSource : "server" ,
1811+ commandId : CommandId . make ( "command:queued-unpicked-follow-up:monitor" ) ,
1812+ threadId,
1813+ messageId : MessageId . make ( "message:queued-unpicked-follow-up:monitor" ) ,
1814+ text : "Monitor update" ,
1815+ attachments : [ ] ,
1816+ dispatchMode : { type : "queue_after_active" } ,
1817+ notification : { source : { kind : "monitor" } , outcome : "updated" , summary : "Update" } ,
1818+ } ) ;
1819+ yield * orchestrator . dispatch ( {
1820+ type : "message.dispatch" ,
1821+ createdBy : "user" ,
1822+ creationSource : "mobile" ,
1823+ commandId : CommandId . make ( "command:queued-unpicked-follow-up:after-monitor" ) ,
1824+ threadId,
1825+ messageId : MessageId . make ( "message:queued-unpicked-follow-up:after-monitor" ) ,
1826+ text : "Follow-up after a monitor update" ,
1827+ attachments : [ ] ,
1828+ dispatchMode : { type : "queue_after_active" } ,
1829+ } ) ;
1830+ const afterMonitor = yield * orchestrator . getThreadProjection ( threadId ) ;
1831+ assert . equal (
1832+ afterMonitor . runs . find (
1833+ ( run ) => run . userMessageId === "message:queued-unpicked-follow-up:after-monitor" ,
1834+ ) ?. modelSelection . instanceId ,
1835+ CLAUDE_MODEL_SELECTION . instanceId ,
1836+ ) ;
18071837 yield * orchestrator . dispatch ( {
18081838 type : "message.dispatch" ,
18091839 createdBy : "user" ,
0 commit comments