@gearbox-protocol/sdk 1.2.10 → 1.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (44) hide show
  1. package/lib/core/creditAccount.js +1 -0
  2. package/lib/core/creditManager.js +10 -8
  3. package/lib/pathfinder/path.js +1 -1
  4. package/lib/pathfinder/yVault.js +1 -1
  5. package/lib/types/contracts/interfaces/V1/{IPriceOracle.sol/IPriceOracleV2.d.ts → IPriceOracle.d.ts} +4 -4
  6. package/lib/types/contracts/interfaces/V1/{IPriceOracle.sol/IPriceOracleV2.js → IPriceOracle.js} +0 -0
  7. package/lib/types/contracts/interfaces/V1/index.d.ts +1 -2
  8. package/lib/types/contracts/pathfinder/interfaces/IDepositor.sol/IDepositorOptions.d.ts +31 -8
  9. package/lib/types/contracts/pathfinder/interfaces/IPathFinder.d.ts +36 -7
  10. package/lib/types/contracts/test/index.d.ts +2 -0
  11. package/lib/types/contracts/test/suites/index.d.ts +2 -0
  12. package/lib/types/contracts/{interfaces/V1/IPriceOracle.sol → test/suites}/index.js +0 -0
  13. package/lib/types/contracts/test/suites/mainnet/IPriceFeedsRegistry.d.ts +42 -0
  14. package/lib/types/contracts/test/suites/mainnet/IPriceFeedsRegistry.js +2 -0
  15. package/lib/types/contracts/test/suites/mainnet/ITokenTestSuite.d.ts +58 -0
  16. package/lib/types/contracts/test/suites/mainnet/ITokenTestSuite.js +2 -0
  17. package/lib/types/contracts/test/suites/mainnet/index.d.ts +2 -0
  18. package/lib/types/contracts/test/suites/mainnet/index.js +2 -0
  19. package/lib/types/factories/contracts/interfaces/V1/{IPriceOracle.sol/IPriceOracleV2__factory.d.ts → IPriceOracle__factory.d.ts} +4 -4
  20. package/lib/types/factories/contracts/interfaces/V1/{IPriceOracle.sol/IPriceOracleV2__factory.js → IPriceOracle__factory.js} +8 -8
  21. package/lib/types/factories/contracts/interfaces/V1/index.d.ts +1 -1
  22. package/lib/types/factories/contracts/interfaces/V1/index.js +3 -25
  23. package/lib/types/factories/contracts/pathfinder/interfaces/IDepositor.sol/IDepositorOptions__factory.js +235 -0
  24. package/lib/types/factories/contracts/pathfinder/interfaces/IPathFinder__factory.js +45 -28
  25. package/lib/types/factories/contracts/support/MultiCall.sol/Multicall2__factory.d.ts +1 -1
  26. package/lib/types/factories/contracts/support/MultiCall.sol/Multicall2__factory.js +1 -1
  27. package/lib/types/factories/contracts/test/index.d.ts +1 -0
  28. package/lib/types/factories/contracts/test/index.js +2 -1
  29. package/lib/types/factories/contracts/test/suites/index.d.ts +1 -0
  30. package/lib/types/factories/contracts/test/suites/index.js +30 -0
  31. package/lib/types/factories/contracts/test/suites/mainnet/IPriceFeedsRegistry__factory.d.ts +32 -0
  32. package/lib/types/factories/contracts/test/suites/mainnet/IPriceFeedsRegistry__factory.js +52 -0
  33. package/lib/types/factories/contracts/test/suites/mainnet/ITokenTestSuite__factory.d.ts +32 -0
  34. package/lib/types/factories/contracts/test/suites/mainnet/ITokenTestSuite__factory.js +90 -0
  35. package/lib/types/factories/contracts/test/suites/mainnet/index.d.ts +2 -0
  36. package/lib/types/factories/contracts/test/suites/mainnet/index.js +10 -0
  37. package/lib/types/index.d.ts +6 -0
  38. package/lib/types/index.js +7 -1
  39. package/lib/utils/extracter.d.ts +1 -1
  40. package/lib/utils/loading.js +1 -1
  41. package/package.json +1 -1
  42. package/lib/types/contracts/interfaces/V1/IPriceOracle.sol/index.d.ts +0 -1
  43. package/lib/types/factories/contracts/interfaces/V1/IPriceOracle.sol/index.d.ts +0 -1
  44. package/lib/types/factories/contracts/interfaces/V1/IPriceOracle.sol/index.js +0 -8
@@ -248,6 +248,16 @@ var _abi = [
248
248
  },
249
249
  {
250
250
  inputs: [
251
+ {
252
+ internalType: "enum TokenType",
253
+ name: "ttIn",
254
+ type: "uint8",
255
+ },
256
+ {
257
+ internalType: "address",
258
+ name: "tokenIn",
259
+ type: "address",
260
+ },
251
261
  {
252
262
  internalType: "address",
253
263
  name: "tokenOut",
@@ -471,6 +481,231 @@ var _abi = [
471
481
  stateMutability: "view",
472
482
  type: "function",
473
483
  },
484
+ {
485
+ inputs: [
486
+ {
487
+ internalType: "address",
488
+ name: "tokenOut",
489
+ type: "address",
490
+ },
491
+ {
492
+ components: [
493
+ {
494
+ internalType: "address",
495
+ name: "creditAccount",
496
+ type: "address",
497
+ },
498
+ {
499
+ components: [
500
+ {
501
+ internalType: "address",
502
+ name: "token",
503
+ type: "address",
504
+ },
505
+ {
506
+ internalType: "uint256",
507
+ name: "balance",
508
+ type: "uint256",
509
+ },
510
+ ],
511
+ internalType: "struct Balance[]",
512
+ name: "balances",
513
+ type: "tuple[]",
514
+ },
515
+ {
516
+ internalType: "address",
517
+ name: "target",
518
+ type: "address",
519
+ },
520
+ {
521
+ internalType: "address[]",
522
+ name: "connectors",
523
+ type: "address[]",
524
+ },
525
+ {
526
+ internalType: "address[]",
527
+ name: "adapters",
528
+ type: "address[]",
529
+ },
530
+ {
531
+ internalType: "uint256",
532
+ name: "slippage",
533
+ type: "uint256",
534
+ },
535
+ {
536
+ internalType: "enum TokenType",
537
+ name: "targetType",
538
+ type: "uint8",
539
+ },
540
+ {
541
+ components: [
542
+ {
543
+ internalType: "address",
544
+ name: "token",
545
+ type: "address",
546
+ },
547
+ {
548
+ internalType: "address[]",
549
+ name: "adapters",
550
+ type: "address[]",
551
+ },
552
+ ],
553
+ internalType: "struct TokenAdapters[]",
554
+ name: "foundAdapters",
555
+ type: "tuple[]",
556
+ },
557
+ {
558
+ internalType: "uint256",
559
+ name: "gasPriceTargetRAY",
560
+ type: "uint256",
561
+ },
562
+ {
563
+ internalType: "uint256",
564
+ name: "gasUsage",
565
+ type: "uint256",
566
+ },
567
+ {
568
+ internalType: "uint256",
569
+ name: "initTargetBalance",
570
+ type: "uint256",
571
+ },
572
+ {
573
+ components: [
574
+ {
575
+ internalType: "address",
576
+ name: "target",
577
+ type: "address",
578
+ },
579
+ {
580
+ internalType: "bytes",
581
+ name: "callData",
582
+ type: "bytes",
583
+ },
584
+ ],
585
+ internalType: "struct MultiCall[]",
586
+ name: "calls",
587
+ type: "tuple[]",
588
+ },
589
+ ],
590
+ internalType: "struct StrategyPathTask",
591
+ name: "task",
592
+ type: "tuple",
593
+ },
594
+ ],
595
+ name: "depositAllTokens",
596
+ outputs: [
597
+ {
598
+ internalType: "uint256",
599
+ name: "amountOut",
600
+ type: "uint256",
601
+ },
602
+ {
603
+ components: [
604
+ {
605
+ internalType: "address",
606
+ name: "creditAccount",
607
+ type: "address",
608
+ },
609
+ {
610
+ components: [
611
+ {
612
+ internalType: "address",
613
+ name: "token",
614
+ type: "address",
615
+ },
616
+ {
617
+ internalType: "uint256",
618
+ name: "balance",
619
+ type: "uint256",
620
+ },
621
+ ],
622
+ internalType: "struct Balance[]",
623
+ name: "balances",
624
+ type: "tuple[]",
625
+ },
626
+ {
627
+ internalType: "address",
628
+ name: "target",
629
+ type: "address",
630
+ },
631
+ {
632
+ internalType: "address[]",
633
+ name: "connectors",
634
+ type: "address[]",
635
+ },
636
+ {
637
+ internalType: "address[]",
638
+ name: "adapters",
639
+ type: "address[]",
640
+ },
641
+ {
642
+ internalType: "uint256",
643
+ name: "slippage",
644
+ type: "uint256",
645
+ },
646
+ {
647
+ internalType: "enum TokenType",
648
+ name: "targetType",
649
+ type: "uint8",
650
+ },
651
+ {
652
+ components: [
653
+ {
654
+ internalType: "address",
655
+ name: "token",
656
+ type: "address",
657
+ },
658
+ {
659
+ internalType: "address[]",
660
+ name: "adapters",
661
+ type: "address[]",
662
+ },
663
+ ],
664
+ internalType: "struct TokenAdapters[]",
665
+ name: "foundAdapters",
666
+ type: "tuple[]",
667
+ },
668
+ {
669
+ internalType: "uint256",
670
+ name: "gasPriceTargetRAY",
671
+ type: "uint256",
672
+ },
673
+ {
674
+ internalType: "uint256",
675
+ name: "gasUsage",
676
+ type: "uint256",
677
+ },
678
+ {
679
+ internalType: "uint256",
680
+ name: "initTargetBalance",
681
+ type: "uint256",
682
+ },
683
+ {
684
+ components: [
685
+ {
686
+ internalType: "address",
687
+ name: "target",
688
+ type: "address",
689
+ },
690
+ {
691
+ internalType: "bytes",
692
+ name: "callData",
693
+ type: "bytes",
694
+ },
695
+ ],
696
+ internalType: "struct MultiCall[]",
697
+ name: "calls",
698
+ type: "tuple[]",
699
+ },
700
+ ],
701
+ internalType: "struct StrategyPathTask",
702
+ name: "",
703
+ type: "tuple",
704
+ },
705
+ ],
706
+ stateMutability: "view",
707
+ type: "function",
708
+ },
474
709
  {
475
710
  inputs: [
476
711
  {
@@ -72,34 +72,51 @@ var _abi = [
72
72
  {
73
73
  inputs: [
74
74
  {
75
- internalType: "address",
76
- name: "tokenIn",
77
- type: "address",
78
- },
79
- {
80
- internalType: "uint256",
81
- name: "amount",
82
- type: "uint256",
83
- },
84
- {
85
- internalType: "address",
86
- name: "tokenOut",
87
- type: "address",
88
- },
89
- {
90
- internalType: "address",
91
- name: "creditAccount",
92
- type: "address",
93
- },
94
- {
95
- internalType: "address[]",
96
- name: "connectors",
97
- type: "address[]",
98
- },
99
- {
100
- internalType: "uint256",
101
- name: "slippage",
102
- type: "uint256",
75
+ components: [
76
+ {
77
+ internalType: "enum SwapOperation",
78
+ name: "swapOperation",
79
+ type: "uint8",
80
+ },
81
+ {
82
+ internalType: "address",
83
+ name: "creditAccount",
84
+ type: "address",
85
+ },
86
+ {
87
+ internalType: "address",
88
+ name: "tokenIn",
89
+ type: "address",
90
+ },
91
+ {
92
+ internalType: "address",
93
+ name: "tokenOut",
94
+ type: "address",
95
+ },
96
+ {
97
+ internalType: "address[]",
98
+ name: "connectors",
99
+ type: "address[]",
100
+ },
101
+ {
102
+ internalType: "uint256",
103
+ name: "amount",
104
+ type: "uint256",
105
+ },
106
+ {
107
+ internalType: "uint256",
108
+ name: "slippage",
109
+ type: "uint256",
110
+ },
111
+ {
112
+ internalType: "bool",
113
+ name: "externalSlippage",
114
+ type: "bool",
115
+ },
116
+ ],
117
+ internalType: "struct SwapTask",
118
+ name: "swapTask",
119
+ type: "tuple",
103
120
  },
104
121
  ],
105
122
  name: "findAllSwaps",
@@ -12,7 +12,7 @@ export declare class Multicall2__factory extends ContractFactory {
12
12
  }): TransactionRequest;
13
13
  attach(address: string): Multicall2;
14
14
  connect(signer: Signer): Multicall2__factory;
15
- static readonly bytecode = "0x608060405234801561001057600080fd5b50610b51806100206000396000f3fe608060405234801561001057600080fd5b50600436106100d45760003560e01c806372425d9d11610081578063bce38bd71161005b578063bce38bd714610181578063c3077fa9146101a1578063ee82ac5e146101b457600080fd5b806372425d9d1461016757806386d516e81461016d578063a8b0574e1461017357600080fd5b8063399542e9116100b2578063399542e91461011757806342cbb15c146101395780634d2301cc1461013f57600080fd5b80630f28c97d146100d9578063252dba42146100ee57806327e86d6e1461010f575b600080fd5b425b6040519081526020015b60405180910390f35b6101016100fc3660046107df565b6101c6565b6040516100e5929190610896565b6100db610373565b61012a61012536600461091e565b610386565b6040516100e5939291906109db565b436100db565b6100db61014d366004610a03565b73ffffffffffffffffffffffffffffffffffffffff163190565b446100db565b456100db565b6040514181526020016100e5565b61019461018f36600461091e565b61039e565b6040516100e59190610a25565b61012a6101af3660046107df565b610599565b6100db6101c2366004610a38565b4090565b8051439060609067ffffffffffffffff8111156101e5576101e56105b6565b60405190808252806020026020018201604052801561021857816020015b60608152602001906001900390816102035790505b50905060005b835181101561036d5760008085838151811061023c5761023c610a51565b60200260200101516000015173ffffffffffffffffffffffffffffffffffffffff1686848151811061027057610270610a51565b6020026020010151602001516040516102899190610a80565b6000604051808303816000865af19150503d80600081146102c6576040519150601f19603f3d011682016040523d82523d6000602084013e6102cb565b606091505b50915091508161033c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4d756c746963616c6c206167677265676174653a2063616c6c206661696c656460448201526064015b60405180910390fd5b8084848151811061034f5761034f610a51565b602002602001018190525050508061036690610acb565b905061021e565b50915091565b6000610380600143610b04565b40905090565b4380406060610395858561039e565b90509250925092565b6060815167ffffffffffffffff8111156103ba576103ba6105b6565b60405190808252806020026020018201604052801561040057816020015b6040805180820190915260008152606060208201528152602001906001900390816103d85790505b50905060005b82518110156105925760008084838151811061042457610424610a51565b60200260200101516000015173ffffffffffffffffffffffffffffffffffffffff1685848151811061045857610458610a51565b6020026020010151602001516040516104719190610a80565b6000604051808303816000865af19150503d80600081146104ae576040519150601f19603f3d011682016040523d82523d6000602084013e6104b3565b606091505b5091509150851561054b578161054b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602160248201527f4d756c746963616c6c32206167677265676174653a2063616c6c206661696c6560448201527f64000000000000000000000000000000000000000000000000000000000000006064820152608401610333565b604051806040016040528083151581526020018281525084848151811061057457610574610a51565b602002602001018190525050508061058b90610acb565b9050610406565b5092915050565b60008060606105a9600185610386565b9196909550909350915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6040805190810167ffffffffffffffff81118282101715610608576106086105b6565b60405290565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715610655576106556105b6565b604052919050565b803573ffffffffffffffffffffffffffffffffffffffff8116811461068157600080fd5b919050565b6000601f838184011261069857600080fd5b8235602067ffffffffffffffff808311156106b5576106b56105b6565b8260051b6106c483820161060e565b93845286810183019383810190898611156106de57600080fd5b84890192505b858310156107d2578235848111156106fc5760008081fd5b890160407fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0828d0381018213156107335760008081fd5b61073b6105e5565b61074689850161065d565b8152828401358881111561075a5760008081fd5b8085019450508d603f8501126107705760008081fd5b8884013588811115610784576107846105b6565b6107938a848e8401160161060e565b92508083528e848287010111156107aa5760008081fd5b808486018b85013760009083018a0152808901919091528452505091840191908401906106e4565b9998505050505050505050565b6000602082840312156107f157600080fd5b813567ffffffffffffffff81111561080857600080fd5b61081484828501610686565b949350505050565b60005b8381101561083757818101518382015260200161081f565b83811115610846576000848401525b50505050565b6000815180845261086481602086016020860161081c565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b600060408201848352602060408185015281855180845260608601915060608160051b870101935082870160005b82811015610910577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa08887030184526108fe86835161084c565b955092840192908401906001016108c4565b509398975050505050505050565b6000806040838503121561093157600080fd5b8235801515811461094157600080fd5b9150602083013567ffffffffffffffff81111561095d57600080fd5b61096985828601610686565b9150509250929050565b6000815180845260208085019450848260051b860182860160005b858110156109ce578383038952815180511515845285015160408685018190526109ba8186018361084c565b9a87019a945050509084019060010161098e565b5090979650505050505050565b8381528260208201526060604082015260006109fa6060830184610973565b95945050505050565b600060208284031215610a1557600080fd5b610a1e8261065d565b9392505050565b602081526000610a1e6020830184610973565b600060208284031215610a4a57600080fd5b5035919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60008251610a9281846020870161081c565b9190910192915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff821415610afd57610afd610a9c565b5060010190565b600082821015610b1657610b16610a9c565b50039056fea2646970667358221220125df3e1e21b5f72a198b151923a51a6f30c33ef274b23d8593ad64b95e7c91f64736f6c634300080a0033";
15
+ static readonly bytecode = "0x608060405234801561001057600080fd5b50610b51806100206000396000f3fe608060405234801561001057600080fd5b50600436106100d45760003560e01c806372425d9d11610081578063bce38bd71161005b578063bce38bd714610181578063c3077fa9146101a1578063ee82ac5e146101b457600080fd5b806372425d9d1461016757806386d516e81461016d578063a8b0574e1461017357600080fd5b8063399542e9116100b2578063399542e91461011757806342cbb15c146101395780634d2301cc1461013f57600080fd5b80630f28c97d146100d9578063252dba42146100ee57806327e86d6e1461010f575b600080fd5b425b6040519081526020015b60405180910390f35b6101016100fc3660046107df565b6101c6565b6040516100e5929190610896565b6100db610373565b61012a61012536600461091e565b610386565b6040516100e5939291906109db565b436100db565b6100db61014d366004610a03565b73ffffffffffffffffffffffffffffffffffffffff163190565b446100db565b456100db565b6040514181526020016100e5565b61019461018f36600461091e565b61039e565b6040516100e59190610a25565b61012a6101af3660046107df565b610599565b6100db6101c2366004610a38565b4090565b8051439060609067ffffffffffffffff8111156101e5576101e56105b6565b60405190808252806020026020018201604052801561021857816020015b60608152602001906001900390816102035790505b50905060005b835181101561036d5760008085838151811061023c5761023c610a51565b60200260200101516000015173ffffffffffffffffffffffffffffffffffffffff1686848151811061027057610270610a51565b6020026020010151602001516040516102899190610a80565b6000604051808303816000865af19150503d80600081146102c6576040519150601f19603f3d011682016040523d82523d6000602084013e6102cb565b606091505b50915091508161033c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4d756c746963616c6c206167677265676174653a2063616c6c206661696c656460448201526064015b60405180910390fd5b8084848151811061034f5761034f610a51565b602002602001018190525050508061036690610acb565b905061021e565b50915091565b6000610380600143610b04565b40905090565b4380406060610395858561039e565b90509250925092565b6060815167ffffffffffffffff8111156103ba576103ba6105b6565b60405190808252806020026020018201604052801561040057816020015b6040805180820190915260008152606060208201528152602001906001900390816103d85790505b50905060005b82518110156105925760008084838151811061042457610424610a51565b60200260200101516000015173ffffffffffffffffffffffffffffffffffffffff1685848151811061045857610458610a51565b6020026020010151602001516040516104719190610a80565b6000604051808303816000865af19150503d80600081146104ae576040519150601f19603f3d011682016040523d82523d6000602084013e6104b3565b606091505b5091509150851561054b578161054b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602160248201527f4d756c746963616c6c32206167677265676174653a2063616c6c206661696c6560448201527f64000000000000000000000000000000000000000000000000000000000000006064820152608401610333565b604051806040016040528083151581526020018281525084848151811061057457610574610a51565b602002602001018190525050508061058b90610acb565b9050610406565b5092915050565b60008060606105a9600185610386565b9196909550909350915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6040805190810167ffffffffffffffff81118282101715610608576106086105b6565b60405290565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715610655576106556105b6565b604052919050565b803573ffffffffffffffffffffffffffffffffffffffff8116811461068157600080fd5b919050565b6000601f838184011261069857600080fd5b8235602067ffffffffffffffff808311156106b5576106b56105b6565b8260051b6106c483820161060e565b93845286810183019383810190898611156106de57600080fd5b84890192505b858310156107d2578235848111156106fc5760008081fd5b890160407fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0828d0381018213156107335760008081fd5b61073b6105e5565b61074689850161065d565b8152828401358881111561075a5760008081fd5b8085019450508d603f8501126107705760008081fd5b8884013588811115610784576107846105b6565b6107938a848e8401160161060e565b92508083528e848287010111156107aa5760008081fd5b808486018b85013760009083018a0152808901919091528452505091840191908401906106e4565b9998505050505050505050565b6000602082840312156107f157600080fd5b813567ffffffffffffffff81111561080857600080fd5b61081484828501610686565b949350505050565b60005b8381101561083757818101518382015260200161081f565b83811115610846576000848401525b50505050565b6000815180845261086481602086016020860161081c565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b600060408201848352602060408185015281855180845260608601915060608160051b870101935082870160005b82811015610910577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa08887030184526108fe86835161084c565b955092840192908401906001016108c4565b509398975050505050505050565b6000806040838503121561093157600080fd5b8235801515811461094157600080fd5b9150602083013567ffffffffffffffff81111561095d57600080fd5b61096985828601610686565b9150509250929050565b6000815180845260208085019450848260051b860182860160005b858110156109ce578383038952815180511515845285015160408685018190526109ba8186018361084c565b9a87019a945050509084019060010161098e565b5090979650505050505050565b8381528260208201526060604082015260006109fa6060830184610973565b95945050505050565b600060208284031215610a1557600080fd5b610a1e8261065d565b9392505050565b602081526000610a1e6020830184610973565b600060208284031215610a4a57600080fd5b5035919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60008251610a9281846020870161081c565b9190910192915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff821415610afd57610afd610a9c565b5060010190565b600082821015610b1657610b16610a9c565b50039056fea26469706673582212202c69e970f479545d7be246c48610ba0d642f18252c98dea6e14ebbeeb819c8f864736f6c634300080a0033";
16
16
  static readonly abi: {
17
17
  inputs: ({
18
18
  internalType: string;
@@ -333,7 +333,7 @@ var _abi = [
333
333
  type: "function",
334
334
  },
335
335
  ];
336
- var _bytecode = "0x608060405234801561001057600080fd5b50610b51806100206000396000f3fe608060405234801561001057600080fd5b50600436106100d45760003560e01c806372425d9d11610081578063bce38bd71161005b578063bce38bd714610181578063c3077fa9146101a1578063ee82ac5e146101b457600080fd5b806372425d9d1461016757806386d516e81461016d578063a8b0574e1461017357600080fd5b8063399542e9116100b2578063399542e91461011757806342cbb15c146101395780634d2301cc1461013f57600080fd5b80630f28c97d146100d9578063252dba42146100ee57806327e86d6e1461010f575b600080fd5b425b6040519081526020015b60405180910390f35b6101016100fc3660046107df565b6101c6565b6040516100e5929190610896565b6100db610373565b61012a61012536600461091e565b610386565b6040516100e5939291906109db565b436100db565b6100db61014d366004610a03565b73ffffffffffffffffffffffffffffffffffffffff163190565b446100db565b456100db565b6040514181526020016100e5565b61019461018f36600461091e565b61039e565b6040516100e59190610a25565b61012a6101af3660046107df565b610599565b6100db6101c2366004610a38565b4090565b8051439060609067ffffffffffffffff8111156101e5576101e56105b6565b60405190808252806020026020018201604052801561021857816020015b60608152602001906001900390816102035790505b50905060005b835181101561036d5760008085838151811061023c5761023c610a51565b60200260200101516000015173ffffffffffffffffffffffffffffffffffffffff1686848151811061027057610270610a51565b6020026020010151602001516040516102899190610a80565b6000604051808303816000865af19150503d80600081146102c6576040519150601f19603f3d011682016040523d82523d6000602084013e6102cb565b606091505b50915091508161033c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4d756c746963616c6c206167677265676174653a2063616c6c206661696c656460448201526064015b60405180910390fd5b8084848151811061034f5761034f610a51565b602002602001018190525050508061036690610acb565b905061021e565b50915091565b6000610380600143610b04565b40905090565b4380406060610395858561039e565b90509250925092565b6060815167ffffffffffffffff8111156103ba576103ba6105b6565b60405190808252806020026020018201604052801561040057816020015b6040805180820190915260008152606060208201528152602001906001900390816103d85790505b50905060005b82518110156105925760008084838151811061042457610424610a51565b60200260200101516000015173ffffffffffffffffffffffffffffffffffffffff1685848151811061045857610458610a51565b6020026020010151602001516040516104719190610a80565b6000604051808303816000865af19150503d80600081146104ae576040519150601f19603f3d011682016040523d82523d6000602084013e6104b3565b606091505b5091509150851561054b578161054b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602160248201527f4d756c746963616c6c32206167677265676174653a2063616c6c206661696c6560448201527f64000000000000000000000000000000000000000000000000000000000000006064820152608401610333565b604051806040016040528083151581526020018281525084848151811061057457610574610a51565b602002602001018190525050508061058b90610acb565b9050610406565b5092915050565b60008060606105a9600185610386565b9196909550909350915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6040805190810167ffffffffffffffff81118282101715610608576106086105b6565b60405290565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715610655576106556105b6565b604052919050565b803573ffffffffffffffffffffffffffffffffffffffff8116811461068157600080fd5b919050565b6000601f838184011261069857600080fd5b8235602067ffffffffffffffff808311156106b5576106b56105b6565b8260051b6106c483820161060e565b93845286810183019383810190898611156106de57600080fd5b84890192505b858310156107d2578235848111156106fc5760008081fd5b890160407fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0828d0381018213156107335760008081fd5b61073b6105e5565b61074689850161065d565b8152828401358881111561075a5760008081fd5b8085019450508d603f8501126107705760008081fd5b8884013588811115610784576107846105b6565b6107938a848e8401160161060e565b92508083528e848287010111156107aa5760008081fd5b808486018b85013760009083018a0152808901919091528452505091840191908401906106e4565b9998505050505050505050565b6000602082840312156107f157600080fd5b813567ffffffffffffffff81111561080857600080fd5b61081484828501610686565b949350505050565b60005b8381101561083757818101518382015260200161081f565b83811115610846576000848401525b50505050565b6000815180845261086481602086016020860161081c565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b600060408201848352602060408185015281855180845260608601915060608160051b870101935082870160005b82811015610910577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa08887030184526108fe86835161084c565b955092840192908401906001016108c4565b509398975050505050505050565b6000806040838503121561093157600080fd5b8235801515811461094157600080fd5b9150602083013567ffffffffffffffff81111561095d57600080fd5b61096985828601610686565b9150509250929050565b6000815180845260208085019450848260051b860182860160005b858110156109ce578383038952815180511515845285015160408685018190526109ba8186018361084c565b9a87019a945050509084019060010161098e565b5090979650505050505050565b8381528260208201526060604082015260006109fa6060830184610973565b95945050505050565b600060208284031215610a1557600080fd5b610a1e8261065d565b9392505050565b602081526000610a1e6020830184610973565b600060208284031215610a4a57600080fd5b5035919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60008251610a9281846020870161081c565b9190910192915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff821415610afd57610afd610a9c565b5060010190565b600082821015610b1657610b16610a9c565b50039056fea2646970667358221220125df3e1e21b5f72a198b151923a51a6f30c33ef274b23d8593ad64b95e7c91f64736f6c634300080a0033";
336
+ var _bytecode = "0x608060405234801561001057600080fd5b50610b51806100206000396000f3fe608060405234801561001057600080fd5b50600436106100d45760003560e01c806372425d9d11610081578063bce38bd71161005b578063bce38bd714610181578063c3077fa9146101a1578063ee82ac5e146101b457600080fd5b806372425d9d1461016757806386d516e81461016d578063a8b0574e1461017357600080fd5b8063399542e9116100b2578063399542e91461011757806342cbb15c146101395780634d2301cc1461013f57600080fd5b80630f28c97d146100d9578063252dba42146100ee57806327e86d6e1461010f575b600080fd5b425b6040519081526020015b60405180910390f35b6101016100fc3660046107df565b6101c6565b6040516100e5929190610896565b6100db610373565b61012a61012536600461091e565b610386565b6040516100e5939291906109db565b436100db565b6100db61014d366004610a03565b73ffffffffffffffffffffffffffffffffffffffff163190565b446100db565b456100db565b6040514181526020016100e5565b61019461018f36600461091e565b61039e565b6040516100e59190610a25565b61012a6101af3660046107df565b610599565b6100db6101c2366004610a38565b4090565b8051439060609067ffffffffffffffff8111156101e5576101e56105b6565b60405190808252806020026020018201604052801561021857816020015b60608152602001906001900390816102035790505b50905060005b835181101561036d5760008085838151811061023c5761023c610a51565b60200260200101516000015173ffffffffffffffffffffffffffffffffffffffff1686848151811061027057610270610a51565b6020026020010151602001516040516102899190610a80565b6000604051808303816000865af19150503d80600081146102c6576040519150601f19603f3d011682016040523d82523d6000602084013e6102cb565b606091505b50915091508161033c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820181905260248201527f4d756c746963616c6c206167677265676174653a2063616c6c206661696c656460448201526064015b60405180910390fd5b8084848151811061034f5761034f610a51565b602002602001018190525050508061036690610acb565b905061021e565b50915091565b6000610380600143610b04565b40905090565b4380406060610395858561039e565b90509250925092565b6060815167ffffffffffffffff8111156103ba576103ba6105b6565b60405190808252806020026020018201604052801561040057816020015b6040805180820190915260008152606060208201528152602001906001900390816103d85790505b50905060005b82518110156105925760008084838151811061042457610424610a51565b60200260200101516000015173ffffffffffffffffffffffffffffffffffffffff1685848151811061045857610458610a51565b6020026020010151602001516040516104719190610a80565b6000604051808303816000865af19150503d80600081146104ae576040519150601f19603f3d011682016040523d82523d6000602084013e6104b3565b606091505b5091509150851561054b578161054b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602160248201527f4d756c746963616c6c32206167677265676174653a2063616c6c206661696c6560448201527f64000000000000000000000000000000000000000000000000000000000000006064820152608401610333565b604051806040016040528083151581526020018281525084848151811061057457610574610a51565b602002602001018190525050508061058b90610acb565b9050610406565b5092915050565b60008060606105a9600185610386565b9196909550909350915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6040805190810167ffffffffffffffff81118282101715610608576106086105b6565b60405290565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715610655576106556105b6565b604052919050565b803573ffffffffffffffffffffffffffffffffffffffff8116811461068157600080fd5b919050565b6000601f838184011261069857600080fd5b8235602067ffffffffffffffff808311156106b5576106b56105b6565b8260051b6106c483820161060e565b93845286810183019383810190898611156106de57600080fd5b84890192505b858310156107d2578235848111156106fc5760008081fd5b890160407fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0828d0381018213156107335760008081fd5b61073b6105e5565b61074689850161065d565b8152828401358881111561075a5760008081fd5b8085019450508d603f8501126107705760008081fd5b8884013588811115610784576107846105b6565b6107938a848e8401160161060e565b92508083528e848287010111156107aa5760008081fd5b808486018b85013760009083018a0152808901919091528452505091840191908401906106e4565b9998505050505050505050565b6000602082840312156107f157600080fd5b813567ffffffffffffffff81111561080857600080fd5b61081484828501610686565b949350505050565b60005b8381101561083757818101518382015260200161081f565b83811115610846576000848401525b50505050565b6000815180845261086481602086016020860161081c565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b600060408201848352602060408185015281855180845260608601915060608160051b870101935082870160005b82811015610910577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa08887030184526108fe86835161084c565b955092840192908401906001016108c4565b509398975050505050505050565b6000806040838503121561093157600080fd5b8235801515811461094157600080fd5b9150602083013567ffffffffffffffff81111561095d57600080fd5b61096985828601610686565b9150509250929050565b6000815180845260208085019450848260051b860182860160005b858110156109ce578383038952815180511515845285015160408685018190526109ba8186018361084c565b9a87019a945050509084019060010161098e565b5090979650505050505050565b8381528260208201526060604082015260006109fa6060830184610973565b95945050505050565b600060208284031215610a1557600080fd5b610a1e8261065d565b9392505050565b602081526000610a1e6020830184610973565b600060208284031215610a4a57600080fd5b5035919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60008251610a9281846020870161081c565b9190910192915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff821415610afd57610afd610a9c565b5060010190565b600082821015610b1657610b16610a9c565b50039056fea26469706673582212202c69e970f479545d7be246c48610ba0d642f18252c98dea6e14ebbeeb819c8f864736f6c634300080a0033";
337
337
  var isSuperArgs = function (xs) { return xs.length > 1; };
338
338
  var Multicall2__factory = /** @class */ (function (_super) {
339
339
  __extends(Multicall2__factory, _super);
@@ -1,2 +1,3 @@
1
1
  export * as mocks from "./mocks";
2
2
  export * as sigp from "./sigp";
3
+ export * as suites from "./suites";
@@ -23,9 +23,10 @@ var __importStar = (this && this.__importStar) || function (mod) {
23
23
  return result;
24
24
  };
25
25
  Object.defineProperty(exports, "__esModule", { value: true });
26
- exports.sigp = exports.mocks = void 0;
26
+ exports.suites = exports.sigp = exports.mocks = void 0;
27
27
  /* Autogenerated file. Do not edit manually. */
28
28
  /* tslint:disable */
29
29
  /* eslint-disable */
30
30
  exports.mocks = __importStar(require("./mocks"));
31
31
  exports.sigp = __importStar(require("./sigp"));
32
+ exports.suites = __importStar(require("./suites"));
@@ -0,0 +1 @@
1
+ export * as mainnet from "./mainnet";
@@ -0,0 +1,30 @@
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
14
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
15
+ }) : function(o, v) {
16
+ o["default"] = v;
17
+ });
18
+ var __importStar = (this && this.__importStar) || function (mod) {
19
+ if (mod && mod.__esModule) return mod;
20
+ var result = {};
21
+ if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
22
+ __setModuleDefault(result, mod);
23
+ return result;
24
+ };
25
+ Object.defineProperty(exports, "__esModule", { value: true });
26
+ exports.mainnet = void 0;
27
+ /* Autogenerated file. Do not edit manually. */
28
+ /* tslint:disable */
29
+ /* eslint-disable */
30
+ exports.mainnet = __importStar(require("./mainnet"));
@@ -0,0 +1,32 @@
1
+ import { Signer } from "ethers";
2
+ import type { Provider } from "@ethersproject/providers";
3
+ import type { IPriceFeedsRegistry, IPriceFeedsRegistryInterface } from "../../../../../contracts/test/suites/mainnet/IPriceFeedsRegistry";
4
+ export declare class IPriceFeedsRegistry__factory {
5
+ static readonly abi: ({
6
+ inputs: {
7
+ internalType: string;
8
+ name: string;
9
+ type: string;
10
+ }[];
11
+ name: string;
12
+ type: string;
13
+ outputs?: undefined;
14
+ stateMutability?: undefined;
15
+ } | {
16
+ inputs: {
17
+ internalType: string;
18
+ name: string;
19
+ type: string;
20
+ }[];
21
+ name: string;
22
+ outputs: {
23
+ internalType: string;
24
+ name: string;
25
+ type: string;
26
+ }[];
27
+ stateMutability: string;
28
+ type: string;
29
+ })[];
30
+ static createInterface(): IPriceFeedsRegistryInterface;
31
+ static connect(address: string, signerOrProvider: Signer | Provider): IPriceFeedsRegistry;
32
+ }
@@ -0,0 +1,52 @@
1
+ "use strict";
2
+ /* Autogenerated file. Do not edit manually. */
3
+ /* tslint:disable */
4
+ /* eslint-disable */
5
+ Object.defineProperty(exports, "__esModule", { value: true });
6
+ exports.IPriceFeedsRegistry__factory = void 0;
7
+ var ethers_1 = require("ethers");
8
+ var _abi = [
9
+ {
10
+ inputs: [
11
+ {
12
+ internalType: "enum Tokens",
13
+ name: "",
14
+ type: "uint8",
15
+ },
16
+ ],
17
+ name: "PriceFeedNotFoundException",
18
+ type: "error",
19
+ },
20
+ {
21
+ inputs: [
22
+ {
23
+ internalType: "enum Tokens",
24
+ name: "token",
25
+ type: "uint8",
26
+ },
27
+ ],
28
+ name: "priceFeeds",
29
+ outputs: [
30
+ {
31
+ internalType: "address",
32
+ name: "",
33
+ type: "address",
34
+ },
35
+ ],
36
+ stateMutability: "view",
37
+ type: "function",
38
+ },
39
+ ];
40
+ var IPriceFeedsRegistry__factory = /** @class */ (function () {
41
+ function IPriceFeedsRegistry__factory() {
42
+ }
43
+ IPriceFeedsRegistry__factory.createInterface = function () {
44
+ return new ethers_1.utils.Interface(_abi);
45
+ };
46
+ IPriceFeedsRegistry__factory.connect = function (address, signerOrProvider) {
47
+ return new ethers_1.Contract(address, _abi, signerOrProvider);
48
+ };
49
+ IPriceFeedsRegistry__factory.abi = _abi;
50
+ return IPriceFeedsRegistry__factory;
51
+ }());
52
+ exports.IPriceFeedsRegistry__factory = IPriceFeedsRegistry__factory;
@@ -0,0 +1,32 @@
1
+ import { Signer } from "ethers";
2
+ import type { Provider } from "@ethersproject/providers";
3
+ import type { ITokenTestSuite, ITokenTestSuiteInterface } from "../../../../../contracts/test/suites/mainnet/ITokenTestSuite";
4
+ export declare class ITokenTestSuite__factory {
5
+ static readonly abi: ({
6
+ inputs: {
7
+ internalType: string;
8
+ name: string;
9
+ type: string;
10
+ }[];
11
+ name: string;
12
+ type: string;
13
+ outputs?: undefined;
14
+ stateMutability?: undefined;
15
+ } | {
16
+ inputs: {
17
+ internalType: string;
18
+ name: string;
19
+ type: string;
20
+ }[];
21
+ name: string;
22
+ outputs: {
23
+ internalType: string;
24
+ name: string;
25
+ type: string;
26
+ }[];
27
+ stateMutability: string;
28
+ type: string;
29
+ })[];
30
+ static createInterface(): ITokenTestSuiteInterface;
31
+ static connect(address: string, signerOrProvider: Signer | Provider): ITokenTestSuite;
32
+ }
@@ -0,0 +1,90 @@
1
+ "use strict";
2
+ /* Autogenerated file. Do not edit manually. */
3
+ /* tslint:disable */
4
+ /* eslint-disable */
5
+ Object.defineProperty(exports, "__esModule", { value: true });
6
+ exports.ITokenTestSuite__factory = void 0;
7
+ var ethers_1 = require("ethers");
8
+ var _abi = [
9
+ {
10
+ inputs: [
11
+ {
12
+ internalType: "address",
13
+ name: "",
14
+ type: "address",
15
+ },
16
+ ],
17
+ name: "PriceFeedNotFoundException",
18
+ type: "error",
19
+ },
20
+ {
21
+ inputs: [
22
+ {
23
+ internalType: "enum Tokens",
24
+ name: "t",
25
+ type: "uint8",
26
+ },
27
+ ],
28
+ name: "addressOf",
29
+ outputs: [
30
+ {
31
+ internalType: "address",
32
+ name: "",
33
+ type: "address",
34
+ },
35
+ ],
36
+ stateMutability: "view",
37
+ type: "function",
38
+ },
39
+ {
40
+ inputs: [
41
+ {
42
+ internalType: "enum Tokens",
43
+ name: "t",
44
+ type: "uint8",
45
+ },
46
+ ],
47
+ name: "priceFeeds",
48
+ outputs: [
49
+ {
50
+ internalType: "address",
51
+ name: "",
52
+ type: "address",
53
+ },
54
+ ],
55
+ stateMutability: "view",
56
+ type: "function",
57
+ },
58
+ {
59
+ inputs: [
60
+ {
61
+ internalType: "address",
62
+ name: "token",
63
+ type: "address",
64
+ },
65
+ ],
66
+ name: "priceFeeds",
67
+ outputs: [
68
+ {
69
+ internalType: "address",
70
+ name: "",
71
+ type: "address",
72
+ },
73
+ ],
74
+ stateMutability: "view",
75
+ type: "function",
76
+ },
77
+ ];
78
+ var ITokenTestSuite__factory = /** @class */ (function () {
79
+ function ITokenTestSuite__factory() {
80
+ }
81
+ ITokenTestSuite__factory.createInterface = function () {
82
+ return new ethers_1.utils.Interface(_abi);
83
+ };
84
+ ITokenTestSuite__factory.connect = function (address, signerOrProvider) {
85
+ return new ethers_1.Contract(address, _abi, signerOrProvider);
86
+ };
87
+ ITokenTestSuite__factory.abi = _abi;
88
+ return ITokenTestSuite__factory;
89
+ }());
90
+ exports.ITokenTestSuite__factory = ITokenTestSuite__factory;
@@ -0,0 +1,2 @@
1
+ export { IPriceFeedsRegistry__factory } from "./IPriceFeedsRegistry__factory";
2
+ export { ITokenTestSuite__factory } from "./ITokenTestSuite__factory";