@@ -38,11 +38,11 @@ describe("Installation script branding", () => {
3838 // Should not contain the upstream npm package name in install commands
3939 // (note: @opencode-ai/ as internal scope is allowed, but `opencode-ai@` as
4040 // an npm install target is not)
41- const installLines = installSrc . split ( "\n" ) . filter (
42- ( line ) =>
43- ( line . includes ( "npm" ) || line . includes ( "pnpm" ) || line . includes ( "bun" ) ) &&
44- line . includes ( "install" ) ,
45- )
41+ const installLines = installSrc
42+ . split ( "\n" )
43+ . filter (
44+ ( line ) => ( line . includes ( "npm" ) || line . includes ( "pnpm" ) || line . includes ( "bun" ) ) && line . includes ( "install" ) ,
45+ )
4646 for ( const line of installLines ) {
4747 expect ( line ) . not . toMatch ( / [ " ' ` ] o p e n c o d e - a i [ " ' ` @ ] / )
4848 }
@@ -206,13 +206,13 @@ describe("OAuth/MCP branding", () => {
206206 const oauthProviderPath = join ( srcDir , "mcp" , "oauth-provider.ts" )
207207 const oauthCallbackPath = join ( srcDir , "mcp" , "oauth-callback.ts" )
208208
209- test ( " oauth-provider.ts has client_name: \ "Altimate Code\ " not \ "OpenCode\"" , ( ) => {
209+ test ( ' oauth-provider.ts has client_name: "Altimate Code" not "OpenCode"' , ( ) => {
210210 const content = readText ( oauthProviderPath )
211211 expect ( content ) . toContain ( 'client_name: "Altimate Code"' )
212212 expect ( content ) . not . toMatch ( / c l i e n t _ n a m e : \s * " O p e n C o d e " / )
213213 } )
214214
215- test ( " oauth-callback.ts HTML titles contain \ "Altimate Code\ " not \ "OpenCode\"" , ( ) => {
215+ test ( ' oauth-callback.ts HTML titles contain "Altimate Code" not "OpenCode"' , ( ) => {
216216 const content = readText ( oauthCallbackPath )
217217 // All <title> tags should reference Altimate Code
218218 const titleMatches = content . match ( / < t i t l e > [ ^ < ] + < \/ t i t l e > / g) ?? [ ]
@@ -300,6 +300,25 @@ describe("No opencode.ai domain leaks in src/", () => {
300300 } )
301301} )
302302
303+ // ---------------------------------------------------------------------------
304+ // 5b. TUI Branding (sidebar, headers, etc.)
305+ // ---------------------------------------------------------------------------
306+ describe ( "TUI branding" , ( ) => {
307+ const sidebarPath = join ( srcDir , "cli" , "cmd" , "tui" , "routes" , "session" , "sidebar.tsx" )
308+ const sidebarContent = readText ( sidebarPath )
309+
310+ test ( "sidebar shows 'Altimate' not 'Open' as branded name" , ( ) => {
311+ // The sidebar footer must say "Altimate Code", not "OpenCode"
312+ expect ( sidebarContent ) . toContain ( "<b>Altimate</b>" )
313+ expect ( sidebarContent ) . not . toMatch ( / < b > O p e n < \/ b > \s * \n \s * < s p a n [ ^ > ] * > \s * < b > C o d e < \/ b > / )
314+ } )
315+
316+ test ( "sidebar has altimate_change marker to protect branding" , ( ) => {
317+ expect ( sidebarContent ) . toContain ( "altimate_change start" )
318+ expect ( sidebarContent ) . toContain ( "altimate_change end" )
319+ } )
320+ } )
321+
303322// ---------------------------------------------------------------------------
304323// 6. Build & Package Branding
305324// ---------------------------------------------------------------------------
0 commit comments