File tree Expand file tree Collapse file tree
crates/taurus-core/src/runtime/functions Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -565,26 +565,14 @@ mod tests {
565565 let request_headers = Struct {
566566 fields : HashMap :: from ( [ ( "x-bool" . to_string ( ) , true . to_value ( ) ) ] ) ,
567567 } ;
568- let request = Struct {
569- fields : HashMap :: from ( [
570- ( "http_method" . to_string ( ) , string_value ( "POST" ) ) ,
571- (
572- "url" . to_string ( ) ,
573- string_value ( & format ! ( "http://{}/echo?x=1" , addr) ) ,
574- ) ,
575- (
576- "headers" . to_string ( ) ,
577- Value {
578- kind : Some ( Kind :: StructValue ( request_headers) ) ,
579- } ,
580- ) ,
581- ( "payload" . to_string ( ) , request_payload) ,
582- ] ) ,
583- } ;
584-
585- let args = vec ! [ Argument :: Eval ( Value {
586- kind: Some ( Kind :: StructValue ( request) ) ,
587- } ) ] ;
568+ let args = vec ! [
569+ Argument :: Eval ( string_value( "POST" ) ) ,
570+ Argument :: Eval ( Value {
571+ kind: Some ( Kind :: StructValue ( request_headers) ) ,
572+ } ) ,
573+ Argument :: Eval ( string_value( & format!( "http://{}/echo?x=1" , addr) ) ) ,
574+ Argument :: Eval ( request_payload) ,
575+ ] ;
588576 let mut ctx = ValueStore :: default ( ) ;
589577 let mut run = |_: & crate :: handler:: argument:: Thunk , _: & mut ValueStore | Signal :: Stop ;
590578
You can’t perform that action at this time.
0 commit comments