@@ -69,6 +69,63 @@ describe("Write Tests", () => {
6969 expect ( writeTransactionStatus . minedAt ) . toBeDefined ( ) ;
7070 } ) ;
7171
72+ test . only ( "Write to a contract with untyped args" , async ( ) => {
73+ const res = await engine . deploy . deployNftDrop (
74+ CONFIG . CHAIN . id . toString ( ) ,
75+ backendWallet ,
76+ {
77+ contractMetadata : {
78+ name : "test token" ,
79+ platform_fee_basis_points : 0 ,
80+ platform_fee_recipient : zeroAddress ,
81+ symbol : "TT" ,
82+ trusted_forwarders : [ ] ,
83+ seller_fee_basis_points : 0 ,
84+ fee_recipient : zeroAddress ,
85+ } ,
86+ } ,
87+ ) ;
88+
89+ expect ( res . result . queueId ) . toBeDefined ( ) ;
90+ assert ( res . result . queueId , "queueId must be defined" ) ;
91+ expect ( res . result . deployedAddress ) . toBeDefined ( ) ;
92+ const nftDropContractAddress = res . result . deployedAddress ;
93+
94+ if ( ! nftDropContractAddress ) {
95+ throw new Error ( "nftDropContractAddress must be defined" ) ;
96+ }
97+
98+ const transactionStatus = await pollTransactionStatus (
99+ engine ,
100+ res . result . queueId ,
101+ true ,
102+ ) ;
103+
104+ expect ( transactionStatus . minedAt ) . toBeDefined ( ) ;
105+ const writeRes = await engine . contract . write (
106+ CONFIG . CHAIN . id . toString ( ) ,
107+ nftDropContractAddress ,
108+ backendWallet ,
109+ {
110+ functionName : "setApprovalForAll" ,
111+ args : [
112+ "0x1234567890123456789012345678901234567890" ,
113+ "true" , // string instead of bool
114+ ] ,
115+ } ,
116+ ) ;
117+
118+ expect ( writeRes . result . queueId ) . toBeDefined ( ) ;
119+
120+ const writeTransactionStatus = await pollTransactionStatus (
121+ engine ,
122+ writeRes . result . queueId ,
123+ true ,
124+ ) ;
125+
126+ expect ( writeTransactionStatus . minedAt ) . toBeDefined ( ) ;
127+ } ) ;
128+
72129 test ( "Write to a contract with function signature" , async ( ) => {
73130 const writeRes = await engine . contract . write (
74131 CONFIG . CHAIN . id . toString ( ) ,
0 commit comments