@@ -98,8 +98,8 @@ func TestAccounts(t *testing.T) {
9898 serviceAcc ,
9999 []crypto.PublicKey {pubKey },
100100 []int {1000 },
101- crypto .ECDSA_P256 ,
102- crypto .SHA3_256 ,
101+ [] crypto.SignatureAlgorithm { crypto . ECDSA_P256 } ,
102+ [] crypto.HashAlgorithm { crypto . SHA3_256 } ,
103103 nil ,
104104 )
105105
@@ -134,8 +134,8 @@ func TestAccounts(t *testing.T) {
134134 serviceAcc ,
135135 []crypto.PublicKey {pubKey },
136136 []int {1000 },
137- crypto .ECDSA_P256 ,
138- crypto .SHA3_256 ,
137+ [] crypto.SignatureAlgorithm { crypto . ECDSA_P256 } ,
138+ [] crypto.HashAlgorithm { crypto . SHA3_256 } ,
139139 []string {"Hello:contractHello.cdc" },
140140 )
141141
@@ -296,8 +296,8 @@ func TestAccountsCreate_Integration(t *testing.T) {
296296 account * flowkit.Account
297297 pubKeys []crypto.PublicKey
298298 weights []int
299- sigAlgo crypto.SignatureAlgorithm
300- hashAlgo crypto.HashAlgorithm
299+ sigAlgo [] crypto.SignatureAlgorithm
300+ hashAlgo [] crypto.HashAlgorithm
301301 args []string
302302 }
303303
@@ -316,19 +316,29 @@ func TestAccountsCreate_Integration(t *testing.T) {
316316 srvAcc , _ := state .EmulatorServiceAccount ()
317317
318318 accIn := []accountsIn {{
319- account : srvAcc ,
320- sigAlgo : crypto .ECDSA_P256 ,
321- hashAlgo : crypto .SHA3_256 ,
322- args : nil ,
319+ account : srvAcc ,
320+ sigAlgo : []crypto.SignatureAlgorithm {
321+ tests .SigAlgos ()[0 ],
322+ },
323+ hashAlgo : []crypto.HashAlgorithm {
324+ tests .HashAlgos ()[0 ],
325+ },
326+ args : nil ,
323327 pubKeys : []crypto.PublicKey {
324328 tests .PubKeys ()[0 ],
325329 },
326330 weights : []int {flow .AccountKeyWeightThreshold },
327331 }, {
328- account : srvAcc ,
329- args : nil ,
330- sigAlgo : crypto .ECDSA_P256 ,
331- hashAlgo : crypto .SHA3_256 ,
332+ account : srvAcc ,
333+ args : nil ,
334+ sigAlgo : []crypto.SignatureAlgorithm {
335+ tests .SigAlgos ()[0 ],
336+ tests .SigAlgos ()[1 ],
337+ },
338+ hashAlgo : []crypto.HashAlgorithm {
339+ tests .HashAlgos ()[0 ],
340+ tests .HashAlgos ()[1 ],
341+ },
332342 pubKeys : []crypto.PublicKey {
333343 tests .PubKeys ()[0 ],
334344 tests .PubKeys ()[1 ],
@@ -342,8 +352,12 @@ func TestAccountsCreate_Integration(t *testing.T) {
342352 tests .ContractSimple .Filename ,
343353 ),
344354 },
345- sigAlgo : crypto .ECDSA_P256 ,
346- hashAlgo : crypto .SHA3_256 ,
355+ sigAlgo : []crypto.SignatureAlgorithm {
356+ tests .SigAlgos ()[0 ],
357+ },
358+ hashAlgo : []crypto.HashAlgorithm {
359+ tests .HashAlgos ()[0 ],
360+ },
347361 pubKeys : []crypto.PublicKey {
348362 tests .PubKeys ()[0 ],
349363 },
@@ -393,8 +407,8 @@ func TestAccountsCreate_Integration(t *testing.T) {
393407 for x , k := range acc .Keys {
394408 assert .Equal (t , k .PublicKey , a .pubKeys [x ])
395409 assert .Equal (t , k .Weight , c .weights [x ])
396- assert .Equal (t , k .SigAlgo , a .sigAlgo )
397- assert .Equal (t , k .HashAlgo , a .hashAlgo )
410+ assert .Equal (t , k .SigAlgo , a .sigAlgo [ x ] )
411+ assert .Equal (t , k .HashAlgo , a .hashAlgo [ x ] )
398412 }
399413
400414 }
@@ -418,35 +432,35 @@ func TestAccountsCreate_Integration(t *testing.T) {
418432 accIn := []accountsIn {
419433 {
420434 account : srvAcc ,
421- sigAlgo : crypto .ECDSA_P256 ,
422- hashAlgo : crypto .SHA3_256 ,
435+ sigAlgo : [] crypto.SignatureAlgorithm { crypto . ECDSA_P256 } ,
436+ hashAlgo : [] crypto.HashAlgorithm { crypto . SHA3_256 } ,
423437 args : []string {"Invalid:Invalid" },
424438 pubKeys : []crypto.PublicKey {
425439 tests .PubKeys ()[0 ],
426440 },
427441 weights : []int {1000 },
428442 }, {
429443 account : srvAcc ,
430- sigAlgo : crypto .UnknownSignatureAlgorithm ,
431- hashAlgo : crypto .SHA3_256 ,
444+ sigAlgo : [] crypto.SignatureAlgorithm { crypto . UnknownSignatureAlgorithm } ,
445+ hashAlgo : [] crypto.HashAlgorithm { crypto . SHA3_256 } ,
432446 args : nil ,
433447 pubKeys : []crypto.PublicKey {
434448 tests .PubKeys ()[0 ],
435449 },
436450 weights : []int {1000 },
437451 }, {
438452 account : srvAcc ,
439- sigAlgo : crypto .UnknownSignatureAlgorithm ,
440- hashAlgo : crypto .UnknownHashAlgorithm ,
453+ sigAlgo : [] crypto.SignatureAlgorithm { crypto . UnknownSignatureAlgorithm } ,
454+ hashAlgo : [] crypto.HashAlgorithm { crypto . UnknownHashAlgorithm } ,
441455 args : nil ,
442456 pubKeys : []crypto.PublicKey {
443457 tests .PubKeys ()[0 ],
444458 },
445459 weights : []int {1000 },
446460 }, {
447461 account : srvAcc ,
448- sigAlgo : crypto .ECDSA_P256 ,
449- hashAlgo : crypto .SHA3_256 ,
462+ sigAlgo : [] crypto.SignatureAlgorithm { crypto . ECDSA_P256 } ,
463+ hashAlgo : [] crypto.HashAlgorithm { crypto . SHA3_256 } ,
450464 args : nil ,
451465 pubKeys : []crypto.PublicKey {
452466 tests .PubKeys ()[0 ],
@@ -455,8 +469,8 @@ func TestAccountsCreate_Integration(t *testing.T) {
455469 weights : []int {1000 },
456470 }, {
457471 account : srvAcc ,
458- sigAlgo : crypto .ECDSA_P256 ,
459- hashAlgo : crypto .SHA3_256 ,
472+ sigAlgo : [] crypto.SignatureAlgorithm { crypto . ECDSA_P256 } ,
473+ hashAlgo : [] crypto.HashAlgorithm { crypto . SHA3_256 } ,
460474 args : nil ,
461475 pubKeys : []crypto.PublicKey {
462476 tests .PubKeys ()[0 ],
0 commit comments