@@ -55,8 +55,9 @@ func Test_Hook_Execute_V2_Protocol(t *testing.T) {
5555 opts : HookExecOpts {
5656 Hook : HookScript {Name : "happypath" , Command : "echo {}" },
5757 Env : map [string ]string {
58- "batman" : "robin" ,
59- "yin" : "yang" ,
58+ "BATMAN" : "robin" ,
59+ "WHOAMI" : "lumpy space princess" ,
60+ "YIN" : "yang" ,
6061 },
6162 Exec : & MockExec {
6263 mockCommand : & MockCommand {
@@ -68,16 +69,17 @@ func Test_Hook_Execute_V2_Protocol(t *testing.T) {
6869 check : func (t * testing.T , response string , err error , mockExec ExecInterface ) {
6970 require .Equal (t , `{"message": "hello world"}` , response )
7071 require .Equal (t , nil , err )
71- require .Contains (t , mockExec .(* MockExec ).mockCommand .Env , `batman="robin"` )
72- require .Contains (t , mockExec .(* MockExec ).mockCommand .Env , `yin="yang"` )
72+ require .Contains (t , mockExec .(* MockExec ).mockCommand .Env , `BATMAN=robin` )
73+ require .Contains (t , mockExec .(* MockExec ).mockCommand .Env , `WHOAMI=lumpy space princess` )
74+ require .Contains (t , mockExec .(* MockExec ).mockCommand .Env , `YIN=yang` )
7375 },
7476 },
7577 "successful execution with payload > 64kb" : {
7678 opts : HookExecOpts {
7779 Hook : HookScript {Name : "happypath" , Command : "echo {}" },
7880 Env : map [string ]string {
79- "batman " : "robin" ,
80- "yin " : "yang" ,
81+ "BATMAN " : "robin" ,
82+ "YIN " : "yang" ,
8183 },
8284 Exec : & MockExec {
8385 mockCommand : & MockCommand {
@@ -89,8 +91,8 @@ func Test_Hook_Execute_V2_Protocol(t *testing.T) {
8991 check : func (t * testing.T , response string , err error , mockExec ExecInterface ) {
9092 require .Equal (t , sixtyFourKBString , response )
9193 require .Equal (t , nil , err )
92- require .Contains (t , mockExec .(* MockExec ).mockCommand .Env , `batman=" robin" ` )
93- require .Contains (t , mockExec .(* MockExec ).mockCommand .Env , `yin=" yang" ` )
94+ require .Contains (t , mockExec .(* MockExec ).mockCommand .Env , `BATMAN= robin` )
95+ require .Contains (t , mockExec .(* MockExec ).mockCommand .Env , `YIN= yang` )
9496 },
9597 },
9698 "successful execution with payload > 512kb" : {
0 commit comments