@@ -67,6 +67,31 @@ describe("settings commands", () => {
6767 ) . toEqual ( { value : "600" } ) ;
6868 } ) ;
6969
70+ it ( "settings.update persists appearance.terminalCopyOnSelect into user_settings" , async ( ) => {
71+ const result = await dispatch (
72+ {
73+ kind : "command" ,
74+ id : "settings-update-terminal-copy-on-select" ,
75+ op : "settings.update" ,
76+ args : {
77+ settings : {
78+ appearance : {
79+ terminalCopyOnSelect : true ,
80+ } ,
81+ } ,
82+ } ,
83+ } ,
84+ ctx
85+ ) ;
86+
87+ expect ( result . ok ) . toBe ( true ) ;
88+ expect (
89+ db
90+ . prepare ( "SELECT value FROM user_settings WHERE key = ?" )
91+ . get ( "appearance.terminalCopyOnSelect" )
92+ ) . toEqual ( { value : "true" } ) ;
93+ } ) ;
94+
7095 it ( "settings.update rejects fractional supervisor timeout values" , async ( ) => {
7196 const result = await dispatch (
7297 {
@@ -270,6 +295,26 @@ describe("settings commands", () => {
270295 } ) ;
271296 } ) ;
272297
298+ it ( "settings.get reads appearance.terminalCopyOnSelect from user_settings" , async ( ) => {
299+ db . prepare ( "INSERT INTO user_settings (key, value) VALUES (?, ?)" ) . run (
300+ "appearance.terminalCopyOnSelect" ,
301+ "true"
302+ ) ;
303+
304+ const result = await dispatch (
305+ {
306+ kind : "command" ,
307+ id : "settings-get-terminal-copy-on-select" ,
308+ op : "settings.get" ,
309+ args : { } ,
310+ } ,
311+ ctx
312+ ) ;
313+
314+ expect ( result . ok ) . toBe ( true ) ;
315+ expect ( result . data ?. [ "appearance.terminalCopyOnSelect" ] ) . toBe ( true ) ;
316+ } ) ;
317+
273318 it ( "settings.get normalizes invalid persisted supervisor timeout values" , async ( ) => {
274319 db . prepare ( "INSERT INTO user_settings (key, value) VALUES (?, ?)" ) . run (
275320 "supervisor.evaluationTimeoutSec" ,
0 commit comments