File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -85,6 +85,24 @@ describe("getAppHref", () => {
8585 expect ( href ) . toBe ( "vscode://example.com?token=user-session-token" ) ;
8686 } ) ;
8787
88+ it ( "replaces the session token for Antigravity IDE URLs" , ( ) => {
89+ const externalApp = {
90+ ...MockWorkspaceApp ,
91+ external : true ,
92+ url : `antigravity-ide://coder.coder-remote/open?token=${ SESSION_TOKEN_PLACEHOLDER } ` ,
93+ } ;
94+ const href = getAppHref ( externalApp , {
95+ host : "*.apps-host.tld" ,
96+ path : "/path-base" ,
97+ agent : MockWorkspaceAgent ,
98+ workspace : MockWorkspace ,
99+ token : "user-session-token" ,
100+ } ) ;
101+ expect ( href ) . toBe (
102+ "antigravity-ide://coder.coder-remote/open?token=user-session-token" ,
103+ ) ;
104+ } ) ;
105+
88106 it ( "doesn't return the URL with the session token replaced when using the HTTP protocol" , ( ) => {
89107 const externalApp = {
90108 ...MockWorkspaceApp ,
Original file line number Diff line number Diff line change @@ -26,6 +26,7 @@ const ALLOWED_EXTERNAL_APP_PROTOCOLS = [
2626 "kiro:" ,
2727 "positron:" ,
2828 "antigravity:" ,
29+ "antigravity-ide:" ,
2930] ;
3031
3132type GetVSCodeHrefParams = {
You can’t perform that action at this time.
0 commit comments