Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

refactor: replace all bigints to use bn.js library instead #468

Merged
merged 21 commits into from
Sep 6, 2022

Conversation

LuizAsFight
Copy link
Contributor

@LuizAsFight LuizAsFight commented Aug 23, 2022

This PR introduces a refactor to add bn.js and replace bigint.

Main problems of bigint:

  • if it's used by JSON.stringify, it breaks the code
  • projects using SDK need to be using es2020 minimum
  • tricky to convert and calculate btw number bigint UIntArray hex strings

Main benefits of using bn.js npm:

  • remove mandatory es2020+ project
  • remove code breaking when using JSON.stringify (it will be parsed to hex string. i.e: 0x00022ab23
  • has a lot of helpers to help correctly dealing with big numbers math operations
  • no number limitations anymore as it's

Optimized for elliptic curves that work with 256-bit numbers. There is no limitation on the size of the numbers.

Summary of Code changes:

  • added bn helpers method as a way to create BN instance
  • added/improved some helpers (we can avoid using ethers a lot of times with these):
    • toHex -> convert to hex string, also allowing padding to match byte syze
    • toArray -> convert to Uint8Array, also allowing padding to match byte syze
    • toNumber -> convert to number (already validates if number is gonna be too big and lose precision)
  • improved many methods of bn.js, to accept a wide range of inputs. (called BNInput)
  • accept BigNumberish as INPUT of contract calls with u64
  • return BN instance as OUTPUT of contract calls with u64
  • removed all bigint usages
  • fixed all tests
  • added U64Coder to encode/decode only u64 types
  • removed things not needed with new helpers, like: hexZeroPad, zeroPad, uIntPad and other... and sometimes even hexlify, arrayify

Closes #280

@LuizAsFight LuizAsFight self-assigned this Aug 23, 2022
@github-actions
Copy link
Contributor

Total Coverage: 89.82%

Coverage Report
FileBranchesFuncsLinesUncovered Lines
packages/abi-coder/src
   abi-coder.ts90.32%100%96.05%118, 119, 36, 46, 56, 57
   index.ts100%53.85%100%
   interface.ts73.08%90.91%90.32%113, 114, 132, 144, 144, 144, 146, 146, 147, 150, 42, 47, 92
   json-abi.ts85.71%100%96.67%125, 126, 75, 76
   utilities.ts100%100%100%
packages/abi-coder/src/coders
   abstract-coder.ts100%100%87.50%48
   array.ts50%100%93.75%23, 24
   b256.ts66.67%100%94.44%30, 31
   boolean.ts60%100%81.25%16, 18, 19, 30, 31
   byte.ts0%100%92.86%25, 26
   enum.ts66.67%100%97.22%61, 62
   number.ts100%100%100%
   string.ts100%100%100%
   struct.ts100%100%100%
   tuple.ts100%100%100%
   u64.ts100%100%100%
packages/abi-coder/src/fragments
   fragment.ts100%100%100%
   function-fragment.ts100%100%100%
   param-type.ts83.33%100%97.37%105, 106, 71, 75
packages/address/src
   address.ts71.43%100%95.65%107, 25, 26
   index.ts100%100%100%
   utils.ts87.50%100%96.55%83, 84
packages/constants/src
   index.ts100%100%100%
packages/contract/src
   index.ts100%100%100%
   scripts.ts81.25%100%94.12%38, 39, 91, 92, 94, 95
   util.ts0%100%96%41, 42
packages/contract/src/__test__
   test-utils.ts0%100%100%13, 20
packages/contract/src/contracts
   contract-factory.ts57.14%80%78.38%33, 37, 38, 43, 46, 46, 46, 47, 48, 50, 51, 56, 60, 61
   contract.ts80%100%100%23
packages/contract/src/contracts/functions
   base-invocation-scope.ts94.12%100%100%143, 166
   invocation-results.ts66.67%100%100%15, 29
   invocation-scope.ts60%100%100%23, 40
   multicall-scope.ts100%100%100%
packages/contract/src/contracts/multicall/static-out
   multicall-bin.ts100%100%100%
packages/example-contract/src/example-contract-types
   index.ts100%100%100%
packages/example-contract/src/example-contract-types/factories
   ExampleContractAbi__factory.ts100%50%83.33%37
packages/fuels/src
   index.ts100%100%100%
packages/hasher/src
   hasher.ts87.50%100%97.50%40, 58
   index.ts100%100%100%
packages/hdwallet/src
   hdwallet-spec.ts100%100%100%
   hdwallet.ts80.39%100%95.96%127, 128, 190, 191, 22, 22, 229, 24, 26, 39, 42, 43, 96, 97
   index.ts100%100%100%
packages/interfaces/src
   index.ts100%100%100%
packages/keystore/src
   aes-ctr-node.ts100%100%100%
   aes-ctr-web.ts100%0%24%15, 16, 17, 18, 19, 24, 25, 27, 39, 40, 41, 42, 44, 49, 51, 52, 54, 55, 57
   aes-ctr.ts80%75%72.22%19, 19, 20, 23, 26, 38
   index.ts100%100%100%
   keystore.ts50%75%100%17, 27
   randomBytes.ts50%100%100%4
   universal-crypto.ts83.33%100%72.73%15, 18, 19, 29
packages/math/src
   bn.ts100%100%100%
   convert.ts71.43%100%88.89%35, 36, 38, 39
   index.ts100%100%100%
   math.ts100%100%100%
packages/merkle-shared/src
   common.ts100%100%100%
   cryptography.ts100%100%100%
   index.ts100%100%100%
packages/merkle/src
   binaryMerkleTree.ts71.43%100%97.01%110, 113, 72, 73
   index.ts100%100%100%
packages/merkle/src/types
   node.ts100%100%100%
packages/merklesum/src
   sumMerkleTree.ts83.33%100%97.06%129, 133, 134
packages/merklesum/src/types
   node.ts100%100%100%
   proof.ts100%100%100%
packages/mnemonic/src
   index.ts100%100%100%
   mnemonic-specs.ts100%100%100%
   mnemonic.ts80.95%100%96.08%141, 142, 157, 40, 41, 83
   utils.ts56.25%100%79.17%17, 20, 20, 20, 21, 22, 24, 24, 24, 24, 25, 29, 30, 31, 32, 33, 35, 36, 37, 58, 62, 63
packages/predicate/src
   predicate.ts100%100%100%
packages/predicate/src/test-predicate-address
   index.ts100%100%100%
packages/predicate/src/test-predicate-false
   index.ts100%100%100%
packages/predicate/src/test-predicate-struct
   index.ts100%100%100%
packages/predicate/src/test-predicate-true
   index.ts100%100%100%
packages/predicate/src/test-predicate-u32
   index.ts100%100%100%
packages/providers/src
   coin-quantity.ts66.67%100%100%17, 20
   coin.ts100%0%100%
   index.ts100%100%100%
   provider.ts47.37%73.53%71.43%106, 114, 204, 214, 215, 253, 254, 257, 258, 349, 406, 406, 406, 407, 408, 408, 408, 409, 411, 414, 416, 416, 417, 420, 425, 437, 437, 437, 438, 439, 439, 439, 440, 442, 445, 447, 447, 448, 451, 456, 458, 467, 468, 468, 469, 471, 480, 481, 481, 482, 484, 531, 572, 573, 574, 604, 605, 610
   util.ts27.27%42.86%39.39%16, 17, 17, 17, 17, 19, 20, 23, 26, 30, 31, 31, 32, 42, 45, 46, 46, 46, 46, 46, 48, 55, 61, 69, 74, 78, 80, 82
packages/providers/src/__generated__
   operations.ts100%64%81.44%1457, 1459, 1486, 1488, 1500, 1502, 1515, 1517, 1529, 1531, 1544, 1546, 1558, 1560, 1600, 1602, 1698, 1700
packages/providers/src/transaction-request
   index.ts100%100%100%
   input.ts77.78%100%90.91%36, 50, 70
   output.ts71.43%100%84.62%107, 58, 58, 76
   storage-slot.ts50%100%83.33%25, 26, 27
   transaction-request.ts65.22%70.37%77.30%123, 133, 145, 146, 147, 196, 197, 203, 204, 209, 210, 237, 239, 239, 240, 243, 270, 271, 294, 321, 361, 362, 374, 381, 382, 407, 408, 417, 463, 463, 464, 466, 480, 488, 489, 491, 497, 498, 506, 507, 513, 515, 542, 542, 547, 550, 79, 80, 84, 85, 86, 87, 92, 93, 94, 95
   witness.ts100%100%100%
packages/providers/src/transaction-response
   index.ts100%100%100%
   transaction-response.ts33.33%100%76.47%101, 102, 111, 111, 111, 114, 117, 118, 119, 139, 148, 149, 64, 72
packages/script/src
   constants.ts100%100%100%
   errors.ts0%0%30%13, 13, 13, 16, 16, 16, 20, 21, 22, 24, 24, 24, 27, 31, 32, 32, 32, 34, 34, 34, 37, 40, 40, 46, 47, 51, 52, 52, 53, 53
   index.ts100%100%100%
   script.ts28.57%66.67%76.47%114, 42, 43, 45, 46, 49, 50, 52, 53, 57, 87, 95, 96
   scripts.ts100%0%50%18, 19
   utils.ts0%0%37.50%11, 11, 12, 13, 14, 14, 18, 6, 6, 6
packages/signer/src
   index.ts100%100%100%
   signer.ts75%100%97.44%34, 34, 36
packages/sparsemerkle/src
   deepSparseMerkleSubTree.ts66.67%60%75%13, 14, 20, 21, 37, 38
   index.ts100%100%100%
   proofs.ts63.64%100%85.11%25, 27, 27, 27, 28, 31, 32, 32, 34, 36, 37
   sparseMerkleTree.ts77.50%100%91.60%105, 106, 116, 118, 126, 128, 129, 131, 139, 139, 143, 144, 147, 161, 162, 277, 280, 98, 99
   treeHasher.ts100%100%100%
   utils.ts100%100%100%
packages/sparsemerkle/src/types
   sparseCompactMerkleProof.ts100%100%100%
   sparseMerkleProof.ts100%100%100%
packages/transactions/src
   consts.ts100%100%100%
   index.ts100%100%100%
packages/transactions/src/coders
   byte-array.ts100%100%100%
   input.ts75%100%97.56%175, 185, 198, 208
   output.ts87.50%100%98.50%317, 343, 356, 382
   receipt.ts87.50%97.06%97.28%628, 630, 631, 633, 677, 677, 715, 716, 719, 732, 774
   storage-slot.ts100%100%100%
   transaction.ts75%100%98.56%305, 315, 328, 338
   utxo-id.ts100%100%100%
   witness.ts100%100%100%
packages/typechain-target-fuels/src/codegen
   types.ts66.04%66.67%61.19%102, 104, 116, 117, 120, 120, 120, 120, 148, 149, 152, 152, 152, 152, 153, 155, 156, 159, 161, 163, 24, 25, 25, 25, 27, 27, 28, 31, 39, 41, 41, 44, 44, 45, 47, 50, 52, 52, 53, 56, 64, 64, 95, 96
packages/typechain-target-fuels/src/parser
   abiParser.ts44.44%86.96%65%148, 200, 201, 209, 210, 218, 219, 227, 228, 252, 253, 253, 263, 264, 266, 269, 269, 270, 273, 273, 274, 277, 277, 278, 280, 280, 280, 280, 281, 284, 291, 292, 294, 297, 297, 297, 297, 297, 299, 299, 299, 302, 302, 303, 304, 304, 305, 305, 305, 306, 307, 307, 310
   parseSvmTypes.ts50%100%88%127, 128, 165, 176, 187, 192, 196, 196, 196, 196, 196, 200, 206, 208, 212, 216
packages/wallet-manager/src
   wallet-manager-spec.ts100%100%100%
   wallet-manager.ts100%100%100%
packages/wallet-manager/src/storages
   memory-storage.ts100%100%100%
packages/wallet-manager/src/vaults
   mnemonic-vault.ts85.71%100%93.33%21, 71, 74
   privatekey-vault.ts60%100%95%24, 57, 58
packages/wallet/src
   index.ts100%100%100%
   test-utils.ts66.67%100%100%8
   wallet-spec.ts100%100%100%
   wallet.ts75%95.83%94.79%138, 147, 148, 149, 175, 200, 246, 335, 62, 63
packages/wordlists/src
   index.ts100%100%100%
packages/wordlists/src/words
   english.ts100%100%100%

@LuizAsFight LuizAsFight changed the title refact: replace all bigints to use bn.js library instead refactor: replace all bigints to use bn.js library instead Aug 24, 2022
@github-actions
Copy link
Contributor

Total Coverage: 89.81%

Coverage Report
FileBranchesFuncsLinesUncovered Lines
packages/abi-coder/src
   abi-coder.ts90.32%100%96.05%118, 119, 36, 46, 56, 57
   index.ts100%53.85%100%
   interface.ts73.08%90.91%90.32%113, 114, 132, 144, 144, 144, 146, 146, 147, 150, 42, 47, 92
   json-abi.ts85.71%100%96.67%125, 126, 75, 76
   utilities.ts100%100%100%
packages/abi-coder/src/coders
   abstract-coder.ts100%100%87.50%48
   array.ts50%100%93.75%23, 24
   b256.ts66.67%100%94.44%30, 31
   boolean.ts60%100%81.25%16, 18, 19, 30, 31
   byte.ts0%100%92.86%25, 26
   enum.ts66.67%100%97.22%61, 62
   number.ts100%100%100%
   string.ts100%100%100%
   struct.ts100%100%100%
   tuple.ts100%100%100%
   u64.ts100%100%100%
packages/abi-coder/src/fragments
   fragment.ts100%100%100%
   function-fragment.ts100%100%100%
   param-type.ts83.33%100%97.37%105, 106, 71, 75
packages/address/src
   address.ts71.43%100%95.65%107, 25, 26
   index.ts100%100%100%
   utils.ts87.50%100%96.55%83, 84
packages/constants/src
   index.ts100%100%100%
packages/contract/src
   index.ts100%100%100%
   scripts.ts81.25%100%94.12%38, 39, 91, 92, 94, 95
   util.ts0%100%96%41, 42
packages/contract/src/__test__
   test-utils.ts0%100%100%13, 20
packages/contract/src/contracts
   contract-factory.ts57.14%80%78.38%33, 37, 38, 43, 46, 46, 46, 47, 48, 50, 51, 56, 60, 61
   contract.ts80%100%100%23
packages/contract/src/contracts/functions
   base-invocation-scope.ts94.12%100%100%143, 166
   invocation-results.ts66.67%100%100%15, 29
   invocation-scope.ts60%100%100%23, 40
   multicall-scope.ts100%100%100%
packages/contract/src/contracts/multicall/static-out
   multicall-bin.ts100%100%100%
packages/example-contract/src/example-contract-types
   index.ts100%100%100%
packages/example-contract/src/example-contract-types/factories
   ExampleContractAbi__factory.ts100%50%83.33%37
packages/fuels/src
   index.ts100%100%100%
packages/hasher/src
   hasher.ts87.50%100%97.50%40, 58
   index.ts100%100%100%
packages/hdwallet/src
   hdwallet-spec.ts100%100%100%
   hdwallet.ts80.39%100%95.79%117, 118, 180, 181, 219, 22, 22, 24, 26, 39, 42, 43, 86, 87
   index.ts100%100%100%
packages/interfaces/src
   index.ts100%100%100%
packages/keystore/src
   aes-ctr-node.ts100%100%100%
   aes-ctr-web.ts100%0%24%15, 16, 17, 18, 19, 24, 25, 27, 39, 40, 41, 42, 44, 49, 51, 52, 54, 55, 57
   aes-ctr.ts80%75%72.22%19, 19, 20, 23, 26, 38
   index.ts100%100%100%
   keystore.ts50%75%100%17, 27
   randomBytes.ts50%100%100%4
   universal-crypto.ts83.33%100%72.73%15, 18, 19, 29
packages/math/src
   bn.ts100%100%100%
   convert.ts71.43%100%88.89%35, 36, 38, 39
   index.ts100%100%100%
   math.ts100%100%100%
packages/merkle-shared/src
   common.ts100%100%100%
   cryptography.ts100%100%100%
   index.ts100%100%100%
packages/merkle/src
   binaryMerkleTree.ts71.43%100%97.01%110, 113, 72, 73
   index.ts100%100%100%
packages/merkle/src/types
   node.ts100%100%100%
packages/merklesum/src
   sumMerkleTree.ts83.33%100%97.06%129, 133, 134
packages/merklesum/src/types
   node.ts100%100%100%
   proof.ts100%100%100%
packages/mnemonic/src
   index.ts100%100%100%
   mnemonic-specs.ts100%100%100%
   mnemonic.ts80.95%100%96.08%141, 142, 157, 40, 41, 83
   utils.ts56.25%100%79.17%17, 20, 20, 20, 21, 22, 24, 24, 24, 24, 25, 29, 30, 31, 32, 33, 35, 36, 37, 58, 62, 63
packages/predicate/src
   predicate.ts100%100%100%
packages/predicate/src/test-predicate-address
   index.ts100%100%100%
packages/predicate/src/test-predicate-false
   index.ts100%100%100%
packages/predicate/src/test-predicate-struct
   index.ts100%100%100%
packages/predicate/src/test-predicate-true
   index.ts100%100%100%
packages/predicate/src/test-predicate-u32
   index.ts100%100%100%
packages/providers/src
   coin-quantity.ts66.67%100%100%17, 20
   coin.ts100%0%100%
   index.ts100%100%100%
   provider.ts47.37%73.53%71.43%106, 114, 204, 214, 215, 253, 254, 257, 258, 349, 406, 406, 406, 407, 408, 408, 408, 409, 411, 414, 416, 416, 417, 420, 425, 437, 437, 437, 438, 439, 439, 439, 440, 442, 445, 447, 447, 448, 451, 456, 458, 467, 468, 468, 469, 471, 480, 481, 481, 482, 484, 531, 572, 573, 574, 604, 605, 610
   util.ts27.27%42.86%39.39%16, 17, 17, 17, 17, 19, 20, 23, 26, 30, 31, 31, 32, 42, 45, 46, 46, 46, 46, 46, 48, 55, 61, 69, 74, 78, 80, 82
packages/providers/src/__generated__
   operations.ts100%64%81.44%1457, 1459, 1486, 1488, 1500, 1502, 1515, 1517, 1529, 1531, 1544, 1546, 1558, 1560, 1600, 1602, 1698, 1700
packages/providers/src/transaction-request
   index.ts100%100%100%
   input.ts77.78%100%90.91%36, 50, 70
   output.ts71.43%100%84.62%107, 58, 58, 76
   storage-slot.ts50%100%83.33%25, 26, 27
   transaction-request.ts65.22%70.37%77.30%123, 133, 145, 146, 147, 196, 197, 203, 204, 209, 210, 237, 239, 239, 240, 243, 270, 271, 294, 321, 361, 362, 374, 381, 382, 407, 408, 417, 463, 463, 464, 466, 480, 488, 489, 491, 497, 498, 506, 507, 513, 515, 542, 542, 547, 550, 79, 80, 84, 85, 86, 87, 92, 93, 94, 95
   witness.ts100%100%100%
packages/providers/src/transaction-response
   index.ts100%100%100%
   transaction-response.ts33.33%100%76.47%101, 102, 111, 111, 111, 114, 117, 118, 119, 139, 148, 149, 64, 72
packages/script/src
   constants.ts100%100%100%
   errors.ts0%0%30%13, 13, 13, 16, 16, 16, 20, 21, 22, 24, 24, 24, 27, 31, 32, 32, 32, 34, 34, 34, 37, 40, 40, 46, 47, 51, 52, 52, 53, 53
   index.ts100%100%100%
   script.ts28.57%66.67%76.47%114, 42, 43, 45, 46, 49, 50, 52, 53, 57, 87, 95, 96
   scripts.ts100%0%50%18, 19
   utils.ts0%0%37.50%11, 11, 12, 13, 14, 14, 18, 6, 6, 6
packages/signer/src
   index.ts100%100%100%
   signer.ts75%100%97.44%34, 34, 36
packages/sparsemerkle/src
   deepSparseMerkleSubTree.ts66.67%60%75%13, 14, 20, 21, 37, 38
   index.ts100%100%100%
   proofs.ts63.64%100%85.11%25, 27, 27, 27, 28, 31, 32, 32, 34, 36, 37
   sparseMerkleTree.ts77.50%100%91.60%105, 106, 116, 118, 126, 128, 129, 131, 139, 139, 143, 144, 147, 161, 162, 277, 280, 98, 99
   treeHasher.ts100%100%100%
   utils.ts100%100%100%
packages/sparsemerkle/src/types
   sparseCompactMerkleProof.ts100%100%100%
   sparseMerkleProof.ts100%100%100%
packages/transactions/src
   consts.ts100%100%100%
   index.ts100%100%100%
packages/transactions/src/coders
   byte-array.ts100%100%100%
   input.ts75%100%97.56%175, 185, 198, 208
   output.ts87.50%100%98.50%317, 343, 356, 382
   receipt.ts87.50%97.06%97.28%628, 630, 631, 633, 677, 677, 715, 716, 719, 732, 774
   storage-slot.ts100%100%100%
   transaction.ts75%100%98.56%305, 315, 328, 338
   utxo-id.ts100%100%100%
   witness.ts100%100%100%
packages/typechain-target-fuels/src/codegen
   types.ts66.04%66.67%61.19%102, 104, 116, 117, 120, 120, 120, 120, 148, 149, 152, 152, 152, 152, 153, 155, 156, 159, 161, 163, 24, 25, 25, 25, 27, 27, 28, 31, 39, 41, 41, 44, 44, 45, 47, 50, 52, 52, 53, 56, 64, 64, 95, 96
packages/typechain-target-fuels/src/parser
   abiParser.ts44.44%86.96%65%148, 200, 201, 209, 210, 218, 219, 227, 228, 252, 253, 253, 263, 264, 266, 269, 269, 270, 273, 273, 274, 277, 277, 278, 280, 280, 280, 280, 281, 284, 291, 292, 294, 297, 297, 297, 297, 297, 299, 299, 299, 302, 302, 303, 304, 304, 305, 305, 305, 306, 307, 307, 310
   parseSvmTypes.ts50%100%88%127, 128, 165, 176, 187, 192, 196, 196, 196, 196, 196, 200, 206, 208, 212, 216
packages/wallet-manager/src
   wallet-manager-spec.ts100%100%100%
   wallet-manager.ts100%100%100%
packages/wallet-manager/src/storages
   memory-storage.ts100%100%100%
packages/wallet-manager/src/vaults
   mnemonic-vault.ts85.71%100%93.33%21, 71, 74
   privatekey-vault.ts60%100%95%24, 57, 58
packages/wallet/src
   index.ts100%100%100%
   test-utils.ts66.67%100%100%8
   wallet-spec.ts100%100%100%
   wallet.ts75%95.83%94.79%138, 147, 148, 149, 175, 200, 246, 335, 62, 63
packages/wordlists/src
   index.ts100%100%100%
packages/wordlists/src/words
   english.ts100%100%100%

@github-actions
Copy link
Contributor

Total Coverage: 89.81%

Coverage Report
FileBranchesFuncsLinesUncovered Lines
packages/abi-coder/src
   abi-coder.ts90.32%100%96.05%118, 119, 36, 46, 56, 57
   index.ts100%53.85%100%
   interface.ts73.08%90.91%90.32%113, 114, 132, 144, 144, 144, 146, 146, 147, 150, 42, 47, 92
   json-abi.ts85.71%100%96.67%125, 126, 75, 76
   utilities.ts100%100%100%
packages/abi-coder/src/coders
   abstract-coder.ts100%100%87.50%48
   array.ts50%100%93.75%23, 24
   b256.ts66.67%100%94.44%30, 31
   boolean.ts60%100%81.25%16, 18, 19, 30, 31
   byte.ts0%100%92.86%25, 26
   enum.ts66.67%100%97.22%61, 62
   number.ts100%100%100%
   string.ts100%100%100%
   struct.ts100%100%100%
   tuple.ts100%100%100%
   u64.ts100%100%100%
packages/abi-coder/src/fragments
   fragment.ts100%100%100%
   function-fragment.ts100%100%100%
   param-type.ts83.33%100%97.37%105, 106, 71, 75
packages/address/src
   address.ts71.43%100%95.65%107, 25, 26
   index.ts100%100%100%
   utils.ts87.50%100%96.55%83, 84
packages/constants/src
   index.ts100%100%100%
packages/contract/src
   index.ts100%100%100%
   scripts.ts81.25%100%94.12%38, 39, 91, 92, 94, 95
   util.ts0%100%96%41, 42
packages/contract/src/__test__
   test-utils.ts0%100%100%13, 20
packages/contract/src/contracts
   contract-factory.ts57.14%80%78.38%33, 37, 38, 43, 46, 46, 46, 47, 48, 50, 51, 56, 60, 61
   contract.ts80%100%100%23
packages/contract/src/contracts/functions
   base-invocation-scope.ts94.12%100%100%143, 166
   invocation-results.ts66.67%100%100%15, 29
   invocation-scope.ts60%100%100%23, 40
   multicall-scope.ts100%100%100%
packages/contract/src/contracts/multicall/static-out
   multicall-bin.ts100%100%100%
packages/example-contract/src/example-contract-types
   index.ts100%100%100%
packages/example-contract/src/example-contract-types/factories
   ExampleContractAbi__factory.ts100%50%83.33%37
packages/fuels/src
   index.ts100%100%100%
packages/hasher/src
   hasher.ts87.50%100%97.50%40, 58
   index.ts100%100%100%
packages/hdwallet/src
   hdwallet-spec.ts100%100%100%
   hdwallet.ts80.39%100%95.79%117, 118, 180, 181, 219, 22, 22, 24, 26, 39, 42, 43, 86, 87
   index.ts100%100%100%
packages/interfaces/src
   index.ts100%100%100%
packages/keystore/src
   aes-ctr-node.ts100%100%100%
   aes-ctr-web.ts100%0%24%15, 16, 17, 18, 19, 24, 25, 27, 39, 40, 41, 42, 44, 49, 51, 52, 54, 55, 57
   aes-ctr.ts80%75%72.22%19, 19, 20, 23, 26, 38
   index.ts100%100%100%
   keystore.ts50%75%100%17, 27
   randomBytes.ts50%100%100%4
   universal-crypto.ts83.33%100%72.73%15, 18, 19, 29
packages/math/src
   bn.ts100%100%100%
   convert.ts71.43%100%88.89%35, 36, 38, 39
   index.ts100%100%100%
   math.ts100%100%100%
packages/merkle-shared/src
   common.ts100%100%100%
   cryptography.ts100%100%100%
   index.ts100%100%100%
packages/merkle/src
   binaryMerkleTree.ts71.43%100%97.01%110, 113, 72, 73
   index.ts100%100%100%
packages/merkle/src/types
   node.ts100%100%100%
packages/merklesum/src
   sumMerkleTree.ts83.33%100%97.06%129, 133, 134
packages/merklesum/src/types
   node.ts100%100%100%
   proof.ts100%100%100%
packages/mnemonic/src
   index.ts100%100%100%
   mnemonic-specs.ts100%100%100%
   mnemonic.ts80.95%100%96.08%141, 142, 157, 40, 41, 83
   utils.ts56.25%100%79.17%17, 20, 20, 20, 21, 22, 24, 24, 24, 24, 25, 29, 30, 31, 32, 33, 35, 36, 37, 58, 62, 63
packages/predicate/src
   predicate.ts100%100%100%
packages/predicate/src/test-predicate-address
   index.ts100%100%100%
packages/predicate/src/test-predicate-false
   index.ts100%100%100%
packages/predicate/src/test-predicate-struct
   index.ts100%100%100%
packages/predicate/src/test-predicate-true
   index.ts100%100%100%
packages/predicate/src/test-predicate-u32
   index.ts100%100%100%
packages/providers/src
   coin-quantity.ts66.67%100%100%17, 20
   coin.ts100%0%100%
   index.ts100%100%100%
   provider.ts47.37%73.53%71.43%106, 114, 204, 214, 215, 253, 254, 257, 258, 349, 406, 406, 406, 407, 408, 408, 408, 409, 411, 414, 416, 416, 417, 420, 425, 437, 437, 437, 438, 439, 439, 439, 440, 442, 445, 447, 447, 448, 451, 456, 458, 467, 468, 468, 469, 471, 480, 481, 481, 482, 484, 531, 572, 573, 574, 604, 605, 610
   util.ts27.27%42.86%39.39%16, 17, 17, 17, 17, 19, 20, 23, 26, 30, 31, 31, 32, 42, 45, 46, 46, 46, 46, 46, 48, 55, 61, 69, 74, 78, 80, 82
packages/providers/src/__generated__
   operations.ts100%64%81.44%1457, 1459, 1486, 1488, 1500, 1502, 1515, 1517, 1529, 1531, 1544, 1546, 1558, 1560, 1600, 1602, 1698, 1700
packages/providers/src/transaction-request
   index.ts100%100%100%
   input.ts77.78%100%90.91%36, 50, 70
   output.ts71.43%100%84.62%107, 58, 58, 76
   storage-slot.ts50%100%83.33%25, 26, 27
   transaction-request.ts65.22%70.37%77.30%123, 133, 145, 146, 147, 196, 197, 203, 204, 209, 210, 237, 239, 239, 240, 243, 270, 271, 294, 321, 361, 362, 374, 381, 382, 407, 408, 417, 463, 463, 464, 466, 480, 488, 489, 491, 497, 498, 506, 507, 513, 515, 542, 542, 547, 550, 79, 80, 84, 85, 86, 87, 92, 93, 94, 95
   witness.ts100%100%100%
packages/providers/src/transaction-response
   index.ts100%100%100%
   transaction-response.ts33.33%100%76.47%101, 102, 111, 111, 111, 114, 117, 118, 119, 139, 148, 149, 64, 72
packages/script/src
   constants.ts100%100%100%
   errors.ts0%0%30%13, 13, 13, 16, 16, 16, 20, 21, 22, 24, 24, 24, 27, 31, 32, 32, 32, 34, 34, 34, 37, 40, 40, 46, 47, 51, 52, 52, 53, 53
   index.ts100%100%100%
   script.ts28.57%66.67%76.47%114, 42, 43, 45, 46, 49, 50, 52, 53, 57, 87, 95, 96
   scripts.ts100%0%50%18, 19
   utils.ts0%0%37.50%11, 11, 12, 13, 14, 14, 18, 6, 6, 6
packages/signer/src
   index.ts100%100%100%
   signer.ts75%100%97.44%34, 34, 36
packages/sparsemerkle/src
   deepSparseMerkleSubTree.ts66.67%60%75%13, 14, 20, 21, 37, 38
   index.ts100%100%100%
   proofs.ts63.64%100%85.11%25, 27, 27, 27, 28, 31, 32, 32, 34, 36, 37
   sparseMerkleTree.ts77.50%100%91.60%105, 106, 116, 118, 126, 128, 129, 131, 139, 139, 143, 144, 147, 161, 162, 277, 280, 98, 99
   treeHasher.ts100%100%100%
   utils.ts100%100%100%
packages/sparsemerkle/src/types
   sparseCompactMerkleProof.ts100%100%100%
   sparseMerkleProof.ts100%100%100%
packages/transactions/src
   consts.ts100%100%100%
   index.ts100%100%100%
packages/transactions/src/coders
   byte-array.ts100%100%100%
   input.ts75%100%97.56%175, 185, 198, 208
   output.ts87.50%100%98.50%317, 343, 356, 382
   receipt.ts87.50%97.06%97.28%628, 630, 631, 633, 677, 677, 715, 716, 719, 732, 774
   storage-slot.ts100%100%100%
   transaction.ts75%100%98.56%305, 315, 328, 338
   utxo-id.ts100%100%100%
   witness.ts100%100%100%
packages/typechain-target-fuels/src/codegen
   types.ts66.04%66.67%61.19%102, 104, 116, 117, 120, 120, 120, 120, 148, 149, 152, 152, 152, 152, 153, 155, 156, 159, 161, 163, 24, 25, 25, 25, 27, 27, 28, 31, 39, 41, 41, 44, 44, 45, 47, 50, 52, 52, 53, 56, 64, 64, 95, 96
packages/typechain-target-fuels/src/parser
   abiParser.ts44.44%86.96%65%148, 200, 201, 209, 210, 218, 219, 227, 228, 252, 253, 253, 263, 264, 266, 269, 269, 270, 273, 273, 274, 277, 277, 278, 280, 280, 280, 280, 281, 284, 291, 292, 294, 297, 297, 297, 297, 297, 299, 299, 299, 302, 302, 303, 304, 304, 305, 305, 305, 306, 307, 307, 310
   parseSvmTypes.ts50%100%88%127, 128, 165, 176, 187, 192, 196, 196, 196, 196, 196, 200, 206, 208, 212, 216
packages/wallet-manager/src
   wallet-manager-spec.ts100%100%100%
   wallet-manager.ts100%100%100%
packages/wallet-manager/src/storages
   memory-storage.ts100%100%100%
packages/wallet-manager/src/vaults
   mnemonic-vault.ts85.71%100%93.33%21, 71, 74
   privatekey-vault.ts60%100%95%24, 57, 58
packages/wallet/src
   index.ts100%100%100%
   test-utils.ts66.67%100%100%8
   wallet-spec.ts100%100%100%
   wallet.ts75%95.83%94.79%138, 147, 148, 149, 175, 200, 246, 335, 62, 63
packages/wordlists/src
   index.ts100%100%100%
packages/wordlists/src/words
   english.ts100%100%100%

@github-actions
Copy link
Contributor

Total Coverage: 89.81%

Coverage Report
FileBranchesFuncsLinesUncovered Lines
packages/abi-coder/src
   abi-coder.ts90.32%100%96.05%118, 119, 36, 46, 56, 57
   index.ts100%53.85%100%
   interface.ts73.08%90.91%90.32%113, 114, 132, 144, 144, 144, 146, 146, 147, 150, 42, 47, 92
   json-abi.ts85.71%100%96.67%125, 126, 75, 76
   utilities.ts100%100%100%
packages/abi-coder/src/coders
   abstract-coder.ts100%100%87.50%48
   array.ts50%100%93.75%23, 24
   b256.ts66.67%100%94.44%30, 31
   boolean.ts60%100%81.25%16, 18, 19, 30, 31
   byte.ts0%100%92.86%25, 26
   enum.ts66.67%100%97.22%61, 62
   number.ts100%100%100%
   string.ts100%100%100%
   struct.ts100%100%100%
   tuple.ts100%100%100%
   u64.ts100%100%100%
packages/abi-coder/src/fragments
   fragment.ts100%100%100%
   function-fragment.ts100%100%100%
   param-type.ts83.33%100%97.37%105, 106, 71, 75
packages/address/src
   address.ts71.43%100%95.65%107, 25, 26
   index.ts100%100%100%
   utils.ts87.50%100%96.55%83, 84
packages/constants/src
   index.ts100%100%100%
packages/contract/src
   index.ts100%100%100%
   scripts.ts81.25%100%94.12%38, 39, 91, 92, 94, 95
   util.ts0%100%96%41, 42
packages/contract/src/__test__
   test-utils.ts0%100%100%13, 20
packages/contract/src/contracts
   contract-factory.ts57.14%80%78.38%33, 37, 38, 43, 46, 46, 46, 47, 48, 50, 51, 56, 60, 61
   contract.ts80%100%100%23
packages/contract/src/contracts/functions
   base-invocation-scope.ts94.12%100%100%143, 166
   invocation-results.ts66.67%100%100%15, 29
   invocation-scope.ts60%100%100%23, 40
   multicall-scope.ts100%100%100%
packages/contract/src/contracts/multicall/static-out
   multicall-bin.ts100%100%100%
packages/example-contract/src/example-contract-types
   index.ts100%100%100%
packages/example-contract/src/example-contract-types/factories
   ExampleContractAbi__factory.ts100%50%83.33%37
packages/fuels/src
   index.ts100%100%100%
packages/hasher/src
   hasher.ts87.50%100%97.50%40, 58
   index.ts100%100%100%
packages/hdwallet/src
   hdwallet-spec.ts100%100%100%
   hdwallet.ts80.39%100%95.79%117, 118, 180, 181, 219, 22, 22, 24, 26, 39, 42, 43, 86, 87
   index.ts100%100%100%
packages/interfaces/src
   index.ts100%100%100%
packages/keystore/src
   aes-ctr-node.ts100%100%100%
   aes-ctr-web.ts100%0%24%15, 16, 17, 18, 19, 24, 25, 27, 39, 40, 41, 42, 44, 49, 51, 52, 54, 55, 57
   aes-ctr.ts80%75%72.22%19, 19, 20, 23, 26, 38
   index.ts100%100%100%
   keystore.ts50%75%100%17, 27
   randomBytes.ts50%100%100%4
   universal-crypto.ts83.33%100%72.73%15, 18, 19, 29
packages/math/src
   bn.ts100%100%100%
   convert.ts71.43%100%88.89%21, 22, 24, 25
   index.ts100%100%100%
   math.ts100%100%100%
packages/merkle-shared/src
   common.ts100%100%100%
   cryptography.ts100%100%100%
   index.ts100%100%100%
packages/merkle/src
   binaryMerkleTree.ts71.43%100%97.01%110, 113, 72, 73
   index.ts100%100%100%
packages/merkle/src/types
   node.ts100%100%100%
packages/merklesum/src
   sumMerkleTree.ts83.33%100%97.06%129, 133, 134
packages/merklesum/src/types
   node.ts100%100%100%
   proof.ts100%100%100%
packages/mnemonic/src
   index.ts100%100%100%
   mnemonic-specs.ts100%100%100%
   mnemonic.ts80.95%100%96.08%141, 142, 157, 40, 41, 83
   utils.ts56.25%100%79.17%17, 20, 20, 20, 21, 22, 24, 24, 24, 24, 25, 29, 30, 31, 32, 33, 35, 36, 37, 58, 62, 63
packages/predicate/src
   predicate.ts100%100%100%
packages/predicate/src/test-predicate-address
   index.ts100%100%100%
packages/predicate/src/test-predicate-false
   index.ts100%100%100%
packages/predicate/src/test-predicate-struct
   index.ts100%100%100%
packages/predicate/src/test-predicate-true
   index.ts100%100%100%
packages/predicate/src/test-predicate-u32
   index.ts100%100%100%
packages/providers/src
   coin-quantity.ts66.67%100%100%17, 20
   coin.ts100%0%100%
   index.ts100%100%100%
   provider.ts47.37%73.53%71.43%106, 114, 204, 214, 215, 253, 254, 257, 258, 349, 406, 406, 406, 407, 408, 408, 408, 409, 411, 414, 416, 416, 417, 420, 425, 437, 437, 437, 438, 439, 439, 439, 440, 442, 445, 447, 447, 448, 451, 456, 458, 467, 468, 468, 469, 471, 480, 481, 481, 482, 484, 531, 572, 573, 574, 604, 605, 610
   util.ts27.27%42.86%39.39%16, 17, 17, 17, 17, 19, 20, 23, 26, 30, 31, 31, 32, 42, 45, 46, 46, 46, 46, 46, 48, 55, 61, 69, 74, 78, 80, 82
packages/providers/src/__generated__
   operations.ts100%64%81.44%1457, 1459, 1486, 1488, 1500, 1502, 1515, 1517, 1529, 1531, 1544, 1546, 1558, 1560, 1600, 1602, 1698, 1700
packages/providers/src/transaction-request
   index.ts100%100%100%
   input.ts77.78%100%90.91%36, 50, 70
   output.ts71.43%100%84.62%107, 58, 58, 76
   storage-slot.ts50%100%83.33%25, 26, 27
   transaction-request.ts65.22%70.37%77.30%123, 133, 145, 146, 147, 196, 197, 203, 204, 209, 210, 237, 239, 239, 240, 243, 270, 271, 294, 321, 359, 360, 372, 379, 380, 405, 406, 415, 461, 461, 462, 464, 478, 486, 487, 489, 495, 496, 504, 505, 511, 513, 540, 540, 545, 548, 79, 80, 84, 85, 86, 87, 92, 93, 94, 95
   witness.ts100%100%100%
packages/providers/src/transaction-response
   index.ts100%100%100%
   transaction-response.ts33.33%100%76.47%101, 102, 111, 111, 111, 114, 117, 118, 119, 139, 148, 149, 64, 72
packages/script/src
   constants.ts100%100%100%
   errors.ts0%0%30%13, 13, 13, 16, 16, 16, 20, 21, 22, 24, 24, 24, 27, 31, 32, 32, 32, 34, 34, 34, 37, 40, 40, 46, 47, 51, 52, 52, 53, 53
   index.ts100%100%100%
   script.ts28.57%66.67%76.47%114, 42, 43, 45, 46, 49, 50, 52, 53, 57, 87, 95, 96
   scripts.ts100%0%50%18, 19
   utils.ts0%0%37.50%11, 11, 12, 13, 14, 14, 18, 6, 6, 6
packages/signer/src
   index.ts100%100%100%
   signer.ts75%100%97.44%34, 34, 36
packages/sparsemerkle/src
   deepSparseMerkleSubTree.ts66.67%60%75%13, 14, 20, 21, 37, 38
   index.ts100%100%100%
   proofs.ts63.64%100%85.11%25, 27, 27, 27, 28, 31, 32, 32, 34, 36, 37
   sparseMerkleTree.ts77.50%100%91.60%105, 106, 116, 118, 126, 128, 129, 131, 139, 139, 143, 144, 147, 161, 162, 277, 280, 98, 99
   treeHasher.ts100%100%100%
   utils.ts100%100%100%
packages/sparsemerkle/src/types
   sparseCompactMerkleProof.ts100%100%100%
   sparseMerkleProof.ts100%100%100%
packages/transactions/src
   consts.ts100%100%100%
   index.ts100%100%100%
packages/transactions/src/coders
   byte-array.ts100%100%100%
   input.ts75%100%97.56%175, 185, 198, 208
   output.ts87.50%100%98.50%317, 343, 356, 382
   receipt.ts87.50%97.06%97.28%628, 630, 631, 633, 677, 677, 715, 716, 719, 732, 774
   storage-slot.ts100%100%100%
   transaction.ts75%100%98.56%305, 315, 328, 338
   utxo-id.ts100%100%100%
   witness.ts100%100%100%
packages/typechain-target-fuels/src/codegen
   types.ts66.04%66.67%61.19%102, 104, 116, 117, 120, 120, 120, 120, 148, 149, 152, 152, 152, 152, 153, 155, 156, 159, 161, 163, 24, 25, 25, 25, 27, 27, 28, 31, 39, 41, 41, 44, 44, 45, 47, 50, 52, 52, 53, 56, 64, 64, 95, 96
packages/typechain-target-fuels/src/parser
   abiParser.ts44.44%86.96%65%148, 200, 201, 209, 210, 218, 219, 227, 228, 252, 253, 253, 263, 264, 266, 269, 269, 270, 273, 273, 274, 277, 277, 278, 280, 280, 280, 280, 281, 284, 291, 292, 294, 297, 297, 297, 297, 297, 299, 299, 299, 302, 302, 303, 304, 304, 305, 305, 305, 306, 307, 307, 310
   parseSvmTypes.ts50%100%88%127, 128, 165, 176, 187, 192, 196, 196, 196, 196, 196, 200, 206, 208, 212, 216
packages/wallet-manager/src
   wallet-manager-spec.ts100%100%100%
   wallet-manager.ts100%100%100%
packages/wallet-manager/src/storages
   memory-storage.ts100%100%100%
packages/wallet-manager/src/vaults
   mnemonic-vault.ts85.71%100%93.33%21, 71, 74
   privatekey-vault.ts60%100%95%24, 57, 58
packages/wallet/src
   index.ts100%100%100%
   test-utils.ts66.67%100%100%8
   wallet-spec.ts100%100%100%
   wallet.ts75%95.83%94.79%138, 147, 148, 149, 175, 200, 246, 335, 62, 63
packages/wordlists/src
   index.ts100%100%100%
packages/wordlists/src/words
   english.ts100%100%100%

@github-actions
Copy link
Contributor

Total Coverage: 89.81%

Coverage Report
FileBranchesFuncsLinesUncovered Lines
packages/abi-coder/src
   abi-coder.ts90.32%100%96.05%118, 119, 36, 46, 56, 57
   index.ts100%53.85%100%
   interface.ts73.08%90.91%90.32%113, 114, 132, 144, 144, 144, 146, 146, 147, 150, 42, 47, 92
   json-abi.ts85.71%100%96.67%125, 126, 75, 76
   utilities.ts100%100%100%
packages/abi-coder/src/coders
   abstract-coder.ts100%100%87.50%48
   array.ts50%100%93.75%23, 24
   b256.ts66.67%100%94.44%30, 31
   boolean.ts60%100%81.25%16, 18, 19, 30, 31
   byte.ts0%100%92.86%25, 26
   enum.ts66.67%100%97.22%61, 62
   number.ts100%100%100%
   string.ts100%100%100%
   struct.ts100%100%100%
   tuple.ts100%100%100%
   u64.ts100%100%100%
packages/abi-coder/src/fragments
   fragment.ts100%100%100%
   function-fragment.ts100%100%100%
   param-type.ts83.33%100%97.37%105, 106, 71, 75
packages/address/src
   address.ts71.43%100%95.65%107, 25, 26
   index.ts100%100%100%
   utils.ts87.50%100%96.55%83, 84
packages/constants/src
   index.ts100%100%100%
packages/contract/src
   index.ts100%100%100%
   scripts.ts81.25%100%94.12%38, 39, 91, 92, 94, 95
   util.ts0%100%96%41, 42
packages/contract/src/__test__
   test-utils.ts0%100%100%13, 20
packages/contract/src/contracts
   contract-factory.ts57.14%80%78.38%33, 37, 38, 43, 46, 46, 46, 47, 48, 50, 51, 56, 60, 61
   contract.ts80%100%100%23
packages/contract/src/contracts/functions
   base-invocation-scope.ts94.12%100%100%143, 166
   invocation-results.ts66.67%100%100%15, 29
   invocation-scope.ts60%100%100%23, 40
   multicall-scope.ts100%100%100%
packages/contract/src/contracts/multicall/static-out
   multicall-bin.ts100%100%100%
packages/example-contract/src/example-contract-types
   index.ts100%100%100%
packages/example-contract/src/example-contract-types/factories
   ExampleContractAbi__factory.ts100%50%83.33%37
packages/fuels/src
   index.ts100%100%100%
packages/hasher/src
   hasher.ts87.50%100%97.50%40, 58
   index.ts100%100%100%
packages/hdwallet/src
   hdwallet-spec.ts100%100%100%
   hdwallet.ts80.39%100%95.79%117, 118, 180, 181, 219, 22, 22, 24, 26, 39, 42, 43, 86, 87
   index.ts100%100%100%
packages/interfaces/src
   index.ts100%100%100%
packages/keystore/src
   aes-ctr-node.ts100%100%100%
   aes-ctr-web.ts100%0%24%15, 16, 17, 18, 19, 24, 25, 27, 39, 40, 41, 42, 44, 49, 51, 52, 54, 55, 57
   aes-ctr.ts80%75%72.22%19, 19, 20, 23, 26, 38
   index.ts100%100%100%
   keystore.ts50%75%100%17, 27
   randomBytes.ts50%100%100%4
   universal-crypto.ts83.33%100%72.73%15, 18, 19, 29
packages/math/src
   bn.ts100%100%100%
   convert.ts71.43%100%88.89%21, 22, 24, 25
   index.ts100%100%100%
   math.ts100%100%100%
packages/merkle-shared/src
   common.ts100%100%100%
   cryptography.ts100%100%100%
   index.ts100%100%100%
packages/merkle/src
   binaryMerkleTree.ts71.43%100%97.01%110, 113, 72, 73
   index.ts100%100%100%
packages/merkle/src/types
   node.ts100%100%100%
packages/merklesum/src
   sumMerkleTree.ts83.33%100%97.06%129, 133, 134
packages/merklesum/src/types
   node.ts100%100%100%
   proof.ts100%100%100%
packages/mnemonic/src
   index.ts100%100%100%
   mnemonic-specs.ts100%100%100%
   mnemonic.ts80.95%100%96.08%141, 142, 157, 40, 41, 83
   utils.ts56.25%100%79.17%17, 20, 20, 20, 21, 22, 24, 24, 24, 24, 25, 29, 30, 31, 32, 33, 35, 36, 37, 58, 62, 63
packages/predicate/src
   predicate.ts100%100%100%
packages/predicate/src/test-predicate-address
   index.ts100%100%100%
packages/predicate/src/test-predicate-false
   index.ts100%100%100%
packages/predicate/src/test-predicate-struct
   index.ts100%100%100%
packages/predicate/src/test-predicate-true
   index.ts100%100%100%
packages/predicate/src/test-predicate-u32
   index.ts100%100%100%
packages/providers/src
   coin-quantity.ts66.67%100%100%17, 20
   coin.ts100%0%100%
   index.ts100%100%100%
   provider.ts47.37%73.53%71.43%106, 114, 204, 214, 215, 253, 254, 257, 258, 349, 406, 406, 406, 407, 408, 408, 408, 409, 411, 414, 416, 416, 417, 420, 425, 437, 437, 437, 438, 439, 439, 439, 440, 442, 445, 447, 447, 448, 451, 456, 458, 467, 468, 468, 469, 471, 480, 481, 481, 482, 484, 531, 572, 573, 574, 604, 605, 610
   util.ts27.27%42.86%39.39%16, 17, 17, 17, 17, 19, 20, 23, 26, 30, 31, 31, 32, 42, 45, 46, 46, 46, 46, 46, 48, 55, 61, 69, 74, 78, 80, 82
packages/providers/src/__generated__
   operations.ts100%64%81.44%1457, 1459, 1486, 1488, 1500, 1502, 1515, 1517, 1529, 1531, 1544, 1546, 1558, 1560, 1600, 1602, 1698, 1700
packages/providers/src/transaction-request
   index.ts100%100%100%
   input.ts77.78%100%90.91%36, 50, 70
   output.ts71.43%100%84.62%107, 58, 58, 76
   storage-slot.ts50%100%83.33%25, 26, 27
   transaction-request.ts65.22%70.37%77.30%123, 133, 145, 146, 147, 196, 197, 203, 204, 209, 210, 237, 239, 239, 240, 243, 270, 271, 294, 321, 359, 360, 372, 379, 380, 405, 406, 415, 461, 461, 462, 464, 478, 486, 487, 489, 495, 496, 504, 505, 511, 513, 540, 540, 545, 548, 79, 80, 84, 85, 86, 87, 92, 93, 94, 95
   witness.ts100%100%100%
packages/providers/src/transaction-response
   index.ts100%100%100%
   transaction-response.ts33.33%100%76.47%101, 102, 111, 111, 111, 114, 117, 118, 119, 139, 148, 149, 64, 72
packages/script/src
   constants.ts100%100%100%
   errors.ts0%0%30%13, 13, 13, 16, 16, 16, 20, 21, 22, 24, 24, 24, 27, 31, 32, 32, 32, 34, 34, 34, 37, 40, 40, 46, 47, 51, 52, 52, 53, 53
   index.ts100%100%100%
   script.ts28.57%66.67%76.47%114, 42, 43, 45, 46, 49, 50, 52, 53, 57, 87, 95, 96
   scripts.ts100%0%50%18, 19
   utils.ts0%0%37.50%11, 11, 12, 13, 14, 14, 18, 6, 6, 6
packages/signer/src
   index.ts100%100%100%
   signer.ts75%100%97.44%34, 34, 36
packages/sparsemerkle/src
   deepSparseMerkleSubTree.ts66.67%60%75%13, 14, 20, 21, 37, 38
   index.ts100%100%100%
   proofs.ts63.64%100%85.11%25, 27, 27, 27, 28, 31, 32, 32, 34, 36, 37
   sparseMerkleTree.ts77.50%100%91.60%105, 106, 116, 118, 126, 128, 129, 131, 139, 139, 143, 144, 147, 161, 162, 277, 280, 98, 99
   treeHasher.ts100%100%100%
   utils.ts100%100%100%
packages/sparsemerkle/src/types
   sparseCompactMerkleProof.ts100%100%100%
   sparseMerkleProof.ts100%100%100%
packages/transactions/src
   consts.ts100%100%100%
   index.ts100%100%100%
packages/transactions/src/coders
   byte-array.ts100%100%100%
   input.ts75%100%97.56%175, 185, 198, 208
   output.ts87.50%100%98.50%317, 343, 356, 382
   receipt.ts87.50%97.06%97.28%628, 630, 631, 633, 677, 677, 715, 716, 719, 732, 774
   storage-slot.ts100%100%100%
   transaction.ts75%100%98.56%305, 315, 328, 338
   utxo-id.ts100%100%100%
   witness.ts100%100%100%
packages/typechain-target-fuels/src/codegen
   types.ts66.04%66.67%61.19%102, 104, 116, 117, 120, 120, 120, 120, 148, 149, 152, 152, 152, 152, 153, 155, 156, 159, 161, 163, 24, 25, 25, 25, 27, 27, 28, 31, 39, 41, 41, 44, 44, 45, 47, 50, 52, 52, 53, 56, 64, 64, 95, 96
packages/typechain-target-fuels/src/parser
   abiParser.ts44.44%86.96%65%148, 200, 201, 209, 210, 218, 219, 227, 228, 252, 253, 253, 263, 264, 266, 269, 269, 270, 273, 273, 274, 277, 277, 278, 280, 280, 280, 280, 281, 284, 291, 292, 294, 297, 297, 297, 297, 297, 299, 299, 299, 302, 302, 303, 304, 304, 305, 305, 305, 306, 307, 307, 310
   parseSvmTypes.ts50%100%88%127, 128, 165, 176, 187, 192, 196, 196, 196, 196, 196, 200, 206, 208, 212, 216
packages/wallet-manager/src
   wallet-manager-spec.ts100%100%100%
   wallet-manager.ts100%100%100%
packages/wallet-manager/src/storages
   memory-storage.ts100%100%100%
packages/wallet-manager/src/vaults
   mnemonic-vault.ts85.71%100%93.33%21, 71, 74
   privatekey-vault.ts60%100%95%24, 57, 58
packages/wallet/src
   index.ts100%100%100%
   test-utils.ts66.67%100%100%8
   wallet-spec.ts100%100%100%
   wallet.ts75%95.83%94.79%138, 147, 148, 149, 175, 200, 246, 335, 62, 63
packages/wordlists/src
   index.ts100%100%100%
packages/wordlists/src/words
   english.ts100%100%100%

@github-actions
Copy link
Contributor

Total Coverage: 89.84%

Coverage Report
FileBranchesFuncsLinesUncovered Lines
packages/abi-coder/src
   abi-coder.ts90.32%100%96.05%118, 119, 36, 46, 56, 57
   index.ts100%53.85%100%
   interface.ts73.08%90.91%90.32%113, 114, 132, 144, 144, 144, 146, 146, 147, 150, 42, 47, 92
   json-abi.ts85.71%100%96.67%125, 126, 75, 76
   utilities.ts100%100%100%
packages/abi-coder/src/coders
   abstract-coder.ts100%100%87.50%48
   array.ts50%100%93.75%23, 24
   b256.ts66.67%100%94.44%30, 31
   boolean.ts60%100%81.25%16, 18, 19, 30, 31
   byte.ts100%100%100%
   enum.ts66.67%100%97.22%61, 62
   number.ts100%100%100%
   string.ts100%100%100%
   struct.ts100%100%100%
   tuple.ts100%100%100%
   u64.ts100%100%100%
packages/abi-coder/src/fragments
   fragment.ts100%100%100%
   function-fragment.ts100%100%100%
   param-type.ts83.33%100%97.37%105, 106, 71, 75
packages/address/src
   address.ts71.43%100%95.65%107, 25, 26
   index.ts100%100%100%
   utils.ts87.50%100%96.55%83, 84
packages/constants/src
   index.ts100%100%100%
packages/contract/src
   index.ts100%100%100%
   scripts.ts81.25%100%94.12%38, 39, 91, 92, 94, 95
   util.ts0%100%96%41, 42
packages/contract/src/__test__
   test-utils.ts0%100%100%13, 20
packages/contract/src/contracts
   contract-factory.ts57.14%80%78.38%33, 37, 38, 43, 46, 46, 46, 47, 48, 50, 51, 56, 60, 61
   contract.ts80%100%100%23
packages/contract/src/contracts/functions
   base-invocation-scope.ts94.12%100%100%143, 166
   invocation-results.ts66.67%100%100%15, 29
   invocation-scope.ts60%100%100%23, 40
   multicall-scope.ts100%100%100%
packages/contract/src/contracts/multicall/static-out
   multicall-bin.ts100%100%100%
packages/example-contract/src/example-contract-types
   index.ts100%100%100%
packages/example-contract/src/example-contract-types/factories
   ExampleContractAbi__factory.ts100%50%83.33%37
packages/fuels/src
   index.ts100%100%100%
packages/hasher/src
   hasher.ts87.50%100%97.50%40, 58
   index.ts100%100%100%
packages/hdwallet/src
   hdwallet-spec.ts100%100%100%
   hdwallet.ts80.39%100%95.79%117, 118, 180, 181, 219, 22, 22, 24, 26, 39, 42, 43, 86, 87
   index.ts100%100%100%
packages/interfaces/src
   index.ts100%100%100%
packages/keystore/src
   aes-ctr-node.ts100%100%100%
   aes-ctr-web.ts100%0%24%15, 16, 17, 18, 19, 24, 25, 27, 39, 40, 41, 42, 44, 49, 51, 52, 54, 55, 57
   aes-ctr.ts80%75%72.22%19, 19, 20, 23, 26, 38
   index.ts100%100%100%
   keystore.ts50%75%100%17, 27
   randomBytes.ts50%100%100%4
   universal-crypto.ts83.33%100%72.73%15, 18, 19, 29
packages/math/src
   bn.ts100%100%100%
   convert.ts77.78%100%89.47%21, 22, 24, 25
   index.ts100%100%100%
   math.ts100%100%100%
packages/merkle-shared/src
   common.ts100%100%100%
   cryptography.ts100%100%100%
   index.ts100%100%100%
packages/merkle/src
   binaryMerkleTree.ts71.43%100%97.01%110, 113, 72, 73
   index.ts100%100%100%
packages/merkle/src/types
   node.ts100%100%100%
packages/merklesum/src
   sumMerkleTree.ts83.33%100%97.06%129, 133, 134
packages/merklesum/src/types
   node.ts100%100%100%
   proof.ts100%100%100%
packages/mnemonic/src
   index.ts100%100%100%
   mnemonic-specs.ts100%100%100%
   mnemonic.ts80.95%100%96.08%141, 142, 157, 40, 41, 83
   utils.ts56.25%100%79.17%17, 20, 20, 20, 21, 22, 24, 24, 24, 24, 25, 29, 30, 31, 32, 33, 35, 36, 37, 58, 62, 63
packages/predicate/src
   predicate.ts100%100%100%
packages/predicate/src/test-predicate-address
   index.ts100%100%100%
packages/predicate/src/test-predicate-false
   index.ts100%100%100%
packages/predicate/src/test-predicate-struct
   index.ts100%100%100%
packages/predicate/src/test-predicate-true
   index.ts100%100%100%
packages/predicate/src/test-predicate-u32
   index.ts100%100%100%
packages/providers/src
   coin-quantity.ts66.67%100%100%17, 20
   coin.ts100%0%100%
   index.ts100%100%100%
   provider.ts47.37%73.53%71.43%106, 114, 204, 214, 215, 253, 254, 257, 258, 349, 406, 406, 406, 407, 408, 408, 408, 409, 411, 414, 416, 416, 417, 420, 425, 437, 437, 437, 438, 439, 439, 439, 440, 442, 445, 447, 447, 448, 451, 456, 458, 467, 468, 468, 469, 471, 480, 481, 481, 482, 484, 531, 572, 573, 574, 604, 605, 610
   util.ts27.27%42.86%39.39%16, 17, 17, 17, 17, 19, 20, 23, 26, 30, 31, 31, 32, 42, 45, 46, 46, 46, 46, 46, 48, 55, 61, 69, 74, 78, 80, 82
packages/providers/src/__generated__
   operations.ts100%64%81.44%1457, 1459, 1486, 1488, 1500, 1502, 1515, 1517, 1529, 1531, 1544, 1546, 1558, 1560, 1600, 1602, 1698, 1700
packages/providers/src/transaction-request
   index.ts100%100%100%
   input.ts77.78%100%90.91%36, 50, 70
   output.ts71.43%100%84.62%107, 58, 58, 76
   storage-slot.ts50%100%83.33%25, 26, 27
   transaction-request.ts65.22%70.37%77.30%123, 133, 145, 146, 147, 196, 197, 203, 204, 209, 210, 237, 239, 239, 240, 243, 270, 271, 294, 321, 359, 360, 372, 379, 380, 405, 406, 415, 461, 461, 462, 464, 478, 486, 487, 489, 495, 496, 504, 505, 511, 513, 540, 540, 545, 548, 79, 80, 84, 85, 86, 87, 92, 93, 94, 95
   witness.ts100%100%100%
packages/providers/src/transaction-response
   index.ts100%100%100%
   transaction-response.ts33.33%100%76.47%101, 102, 111, 111, 111, 114, 117, 118, 119, 139, 148, 149, 64, 72
packages/script/src
   constants.ts100%100%100%
   errors.ts0%0%30%13, 13, 13, 16, 16, 16, 20, 21, 22, 24, 24, 24, 27, 31, 32, 32, 32, 34, 34, 34, 37, 40, 40, 46, 47, 51, 52, 52, 53, 53
   index.ts100%100%100%
   script.ts28.57%66.67%76.47%114, 42, 43, 45, 46, 49, 50, 52, 53, 57, 87, 95, 96
   scripts.ts100%0%50%18, 19
   utils.ts0%0%37.50%11, 11, 12, 13, 14, 14, 18, 6, 6, 6
packages/signer/src
   index.ts100%100%100%
   signer.ts75%100%97.44%34, 34, 36
packages/sparsemerkle/src
   deepSparseMerkleSubTree.ts66.67%60%75%13, 14, 20, 21, 37, 38
   index.ts100%100%100%
   proofs.ts63.64%100%85.11%25, 27, 27, 27, 28, 31, 32, 32, 34, 36, 37
   sparseMerkleTree.ts77.50%100%91.60%105, 106, 116, 118, 126, 128, 129, 131, 139, 139, 143, 144, 147, 161, 162, 277, 280, 98, 99
   treeHasher.ts100%100%100%
   utils.ts100%100%100%
packages/sparsemerkle/src/types
   sparseCompactMerkleProof.ts100%100%100%
   sparseMerkleProof.ts100%100%100%
packages/transactions/src
   consts.ts100%100%100%
   index.ts100%100%100%
packages/transactions/src/coders
   byte-array.ts100%100%100%
   input.ts75%100%97.56%175, 185, 198, 208
   output.ts87.50%100%98.50%317, 343, 356, 382
   receipt.ts87.50%97.06%97.28%628, 630, 631, 633, 677, 677, 715, 716, 719, 732, 774
   storage-slot.ts100%100%100%
   transaction.ts75%100%98.56%305, 315, 328, 338
   utxo-id.ts100%100%100%
   witness.ts100%100%100%
packages/typechain-target-fuels/src/codegen
   types.ts66.04%66.67%61.19%102, 104, 116, 117, 120, 120, 120, 120, 148, 149, 152, 152, 152, 152, 153, 155, 156, 159, 161, 163, 24, 25, 25, 25, 27, 27, 28, 31, 39, 41, 41, 44, 44, 45, 47, 50, 52, 52, 53, 56, 64, 64, 95, 96
packages/typechain-target-fuels/src/parser
   abiParser.ts44.44%86.96%65%148, 200, 201, 209, 210, 218, 219, 227, 228, 252, 253, 253, 263, 264, 266, 269, 269, 270, 273, 273, 274, 277, 277, 278, 280, 280, 280, 280, 281, 284, 291, 292, 294, 297, 297, 297, 297, 297, 299, 299, 299, 302, 302, 303, 304, 304, 305, 305, 305, 306, 307, 307, 310
   parseSvmTypes.ts50%100%88%127, 128, 165, 176, 187, 192, 196, 196, 196, 196, 196, 200, 206, 208, 212, 216
packages/wallet-manager/src
   wallet-manager-spec.ts100%100%100%
   wallet-manager.ts100%100%100%
packages/wallet-manager/src/storages
   memory-storage.ts100%100%100%
packages/wallet-manager/src/vaults
   mnemonic-vault.ts85.71%100%93.33%21, 71, 74
   privatekey-vault.ts60%100%95%24, 57, 58
packages/wallet/src
   index.ts100%100%100%
   test-utils.ts66.67%100%100%8
   wallet-spec.ts100%100%100%
   wallet.ts75%95.83%94.79%138, 147, 148, 149, 175, 200, 246, 335, 62, 63
packages/wordlists/src
   index.ts100%100%100%
packages/wordlists/src/words
   english.ts100%100%100%

@github-actions
Copy link
Contributor

Total Coverage: 89.84%

Coverage Report
FileBranchesFuncsLinesUncovered Lines
packages/abi-coder/src
   abi-coder.ts90.32%100%96.05%118, 119, 36, 46, 56, 57
   index.ts100%53.85%100%
   interface.ts73.08%90.91%90.32%113, 114, 132, 144, 144, 144, 146, 146, 147, 150, 42, 47, 92
   json-abi.ts85.71%100%96.67%125, 126, 75, 76
   utilities.ts100%100%100%
packages/abi-coder/src/coders
   abstract-coder.ts100%100%87.50%48
   array.ts50%100%93.75%23, 24
   b256.ts66.67%100%94.44%30, 31
   boolean.ts60%100%81.25%16, 18, 19, 30, 31
   byte.ts0%100%92.86%25, 26
   enum.ts66.67%100%97.22%61, 62
   number.ts100%100%100%
   string.ts100%100%100%
   struct.ts100%100%100%
   tuple.ts100%100%100%
   u64.ts100%100%100%
packages/abi-coder/src/fragments
   fragment.ts100%100%100%
   function-fragment.ts100%100%100%
   param-type.ts83.33%100%97.37%105, 106, 71, 75
packages/address/src
   address.ts71.43%100%95.65%107, 25, 26
   index.ts100%100%100%
   utils.ts87.50%100%96.55%83, 84
packages/constants/src
   index.ts100%100%100%
packages/contract/src
   index.ts100%100%100%
   scripts.ts81.25%100%94.12%38, 39, 91, 92, 94, 95
   util.ts0%100%96%41, 42
packages/contract/src/__test__
   test-utils.ts0%100%100%13, 20
packages/contract/src/contracts
   contract-factory.ts57.14%80%78.38%33, 37, 38, 43, 46, 46, 46, 47, 48, 50, 51, 56, 60, 61
   contract.ts80%100%100%23
packages/contract/src/contracts/functions
   base-invocation-scope.ts94.12%100%100%143, 166
   invocation-results.ts66.67%100%100%15, 29
   invocation-scope.ts60%100%100%23, 40
   multicall-scope.ts100%100%100%
packages/contract/src/contracts/multicall/static-out
   multicall-bin.ts100%100%100%
packages/example-contract/src/example-contract-types
   index.ts100%100%100%
packages/example-contract/src/example-contract-types/factories
   ExampleContractAbi__factory.ts100%50%83.33%37
packages/fuels/src
   index.ts100%100%100%
packages/hasher/src
   hasher.ts87.50%100%97.50%40, 58
   index.ts100%100%100%
packages/hdwallet/src
   hdwallet-spec.ts100%100%100%
   hdwallet.ts80.39%100%95.79%117, 118, 180, 181, 219, 22, 22, 24, 26, 39, 42, 43, 86, 87
   index.ts100%100%100%
packages/interfaces/src
   index.ts100%100%100%
packages/keystore/src
   aes-ctr-node.ts100%100%100%
   aes-ctr-web.ts100%0%24%15, 16, 17, 18, 19, 24, 25, 27, 39, 40, 41, 42, 44, 49, 51, 52, 54, 55, 57
   aes-ctr.ts80%75%72.22%19, 19, 20, 23, 26, 38
   index.ts100%100%100%
   keystore.ts50%75%100%17, 27
   randomBytes.ts50%100%100%4
   universal-crypto.ts83.33%100%72.73%15, 18, 19, 29
packages/math/src
   bn.ts100%100%100%
   convert.ts85.71%100%94.44%21, 22
   index.ts100%100%100%
   math.ts100%100%100%
packages/merkle-shared/src
   common.ts100%100%100%
   cryptography.ts100%100%100%
   index.ts100%100%100%
packages/merkle/src
   binaryMerkleTree.ts71.43%100%97.01%110, 113, 72, 73
   index.ts100%100%100%
packages/merkle/src/types
   node.ts100%100%100%
packages/merklesum/src
   sumMerkleTree.ts83.33%100%97.06%129, 133, 134
packages/merklesum/src/types
   node.ts100%100%100%
   proof.ts100%100%100%
packages/mnemonic/src
   index.ts100%100%100%
   mnemonic-specs.ts100%100%100%
   mnemonic.ts80.95%100%96.08%141, 142, 157, 40, 41, 83
   utils.ts56.25%100%79.17%17, 20, 20, 20, 21, 22, 24, 24, 24, 24, 25, 29, 30, 31, 32, 33, 35, 36, 37, 58, 62, 63
packages/predicate/src
   predicate.ts100%100%100%
packages/predicate/src/test-predicate-address
   index.ts100%100%100%
packages/predicate/src/test-predicate-false
   index.ts100%100%100%
packages/predicate/src/test-predicate-struct
   index.ts100%100%100%
packages/predicate/src/test-predicate-true
   index.ts100%100%100%
packages/predicate/src/test-predicate-u32
   index.ts100%100%100%
packages/providers/src
   coin-quantity.ts66.67%100%100%17, 20
   coin.ts100%0%100%
   index.ts100%100%100%
   provider.ts47.37%73.53%71.43%106, 114, 204, 214, 215, 253, 254, 257, 258, 349, 406, 406, 406, 407, 408, 408, 408, 409, 411, 414, 416, 416, 417, 420, 425, 437, 437, 437, 438, 439, 439, 439, 440, 442, 445, 447, 447, 448, 451, 456, 458, 467, 468, 468, 469, 471, 480, 481, 481, 482, 484, 531, 572, 573, 574, 604, 605, 610
   util.ts27.27%42.86%39.39%16, 17, 17, 17, 17, 19, 20, 23, 26, 30, 31, 31, 32, 42, 45, 46, 46, 46, 46, 46, 48, 55, 61, 69, 74, 78, 80, 82
packages/providers/src/__generated__
   operations.ts100%64%81.44%1457, 1459, 1486, 1488, 1500, 1502, 1515, 1517, 1529, 1531, 1544, 1546, 1558, 1560, 1600, 1602, 1698, 1700
packages/providers/src/transaction-request
   index.ts100%100%100%
   input.ts77.78%100%90.91%36, 50, 70
   output.ts71.43%100%84.62%107, 58, 58, 76
   storage-slot.ts50%100%83.33%25, 26, 27
   transaction-request.ts65.22%70.37%77.30%123, 133, 145, 146, 147, 196, 197, 203, 204, 209, 210, 237, 239, 239, 240, 243, 270, 271, 294, 321, 359, 360, 372, 379, 380, 405, 406, 415, 461, 461, 462, 464, 478, 486, 487, 489, 495, 496, 504, 505, 511, 513, 540, 540, 545, 548, 79, 80, 84, 85, 86, 87, 92, 93, 94, 95
   witness.ts100%100%100%
packages/providers/src/transaction-response
   index.ts100%100%100%
   transaction-response.ts33.33%100%76.47%101, 102, 111, 111, 111, 114, 117, 118, 119, 139, 148, 149, 64, 72
packages/script/src
   constants.ts100%100%100%
   errors.ts0%0%30%13, 13, 13, 16, 16, 16, 20, 21, 22, 24, 24, 24, 27, 31, 32, 32, 32, 34, 34, 34, 37, 40, 40, 46, 47, 51, 52, 52, 53, 53
   index.ts100%100%100%
   script.ts28.57%66.67%76.47%114, 42, 43, 45, 46, 49, 50, 52, 53, 57, 87, 95, 96
   scripts.ts100%0%50%18, 19
   utils.ts0%0%37.50%11, 11, 12, 13, 14, 14, 18, 6, 6, 6
packages/signer/src
   index.ts100%100%100%
   signer.ts75%100%97.44%34, 34, 36
packages/sparsemerkle/src
   deepSparseMerkleSubTree.ts66.67%60%75%13, 14, 20, 21, 37, 38
   index.ts100%100%100%
   proofs.ts63.64%100%85.11%25, 27, 27, 27, 28, 31, 32, 32, 34, 36, 37
   sparseMerkleTree.ts77.50%100%91.60%105, 106, 116, 118, 126, 128, 129, 131, 139, 139, 143, 144, 147, 161, 162, 277, 280, 98, 99
   treeHasher.ts100%100%100%
   utils.ts100%100%100%
packages/sparsemerkle/src/types
   sparseCompactMerkleProof.ts100%100%100%
   sparseMerkleProof.ts100%100%100%
packages/transactions/src
   consts.ts100%100%100%
   index.ts100%100%100%
packages/transactions/src/coders
   byte-array.ts100%100%100%
   input.ts75%100%97.56%175, 185, 198, 208
   output.ts87.50%100%98.50%317, 343, 356, 382
   receipt.ts87.50%97.06%97.28%628, 630, 631, 633, 677, 677, 715, 716, 719, 732, 774
   storage-slot.ts100%100%100%
   transaction.ts75%100%98.56%305, 315, 328, 338
   utxo-id.ts100%100%100%
   witness.ts100%100%100%
packages/typechain-target-fuels/src/codegen
   types.ts66.04%66.67%61.19%102, 104, 116, 117, 120, 120, 120, 120, 148, 149, 152, 152, 152, 152, 153, 155, 156, 159, 161, 163, 24, 25, 25, 25, 27, 27, 28, 31, 39, 41, 41, 44, 44, 45, 47, 50, 52, 52, 53, 56, 64, 64, 95, 96
packages/typechain-target-fuels/src/parser
   abiParser.ts44.44%86.96%65%148, 200, 201, 209, 210, 218, 219, 227, 228, 252, 253, 253, 263, 264, 266, 269, 269, 270, 273, 273, 274, 277, 277, 278, 280, 280, 280, 280, 281, 284, 291, 292, 294, 297, 297, 297, 297, 297, 299, 299, 299, 302, 302, 303, 304, 304, 305, 305, 305, 306, 307, 307, 310
   parseSvmTypes.ts50%100%88%127, 128, 165, 176, 187, 192, 196, 196, 196, 196, 196, 200, 206, 208, 212, 216
packages/wallet-manager/src
   wallet-manager-spec.ts100%100%100%
   wallet-manager.ts100%100%100%
packages/wallet-manager/src/storages
   memory-storage.ts100%100%100%
packages/wallet-manager/src/vaults
   mnemonic-vault.ts85.71%100%93.33%21, 71, 74
   privatekey-vault.ts60%100%95%24, 57, 58
packages/wallet/src
   index.ts100%100%100%
   test-utils.ts66.67%100%100%8
   wallet-spec.ts100%100%100%
   wallet.ts75%95.83%94.79%138, 147, 148, 149, 175, 200, 246, 335, 62, 63
packages/wordlists/src
   index.ts100%100%100%
packages/wordlists/src/words
   english.ts100%100%100%

@LuizAsFight LuizAsFight marked this pull request as ready for review August 26, 2022 23:43
@LuizAsFight LuizAsFight requested a review from a team August 26, 2022 23:43
@github-actions
Copy link
Contributor

Total Coverage: 89.84%

Coverage Report
FileBranchesFuncsLinesUncovered Lines
packages/abi-coder/src
   abi-coder.ts90.32%100%96.05%118, 119, 36, 46, 56, 57
   index.ts100%53.85%100%
   interface.ts73.08%90.91%90.32%113, 114, 132, 144, 144, 144, 146, 146, 147, 150, 42, 47, 92
   json-abi.ts85.71%100%96.67%125, 126, 75, 76
   utilities.ts100%100%100%
packages/abi-coder/src/coders
   abstract-coder.ts100%100%87.50%48
   array.ts50%100%93.75%23, 24
   b256.ts66.67%100%94.44%30, 31
   boolean.ts60%100%81.25%16, 18, 19, 30, 31
   byte.ts0%100%92.86%25, 26
   enum.ts66.67%100%97.22%61, 62
   number.ts100%100%100%
   string.ts100%100%100%
   struct.ts100%100%100%
   tuple.ts100%100%100%
   u64.ts100%100%100%
packages/abi-coder/src/fragments
   fragment.ts100%100%100%
   function-fragment.ts100%100%100%
   param-type.ts83.33%100%97.37%105, 106, 71, 75
packages/address/src
   address.ts71.43%100%95.65%107, 25, 26
   index.ts100%100%100%
   utils.ts87.50%100%96.55%83, 84
packages/constants/src
   index.ts100%100%100%
packages/contract/src
   index.ts100%100%100%
   scripts.ts81.25%100%94.12%38, 39, 91, 92, 94, 95
   util.ts0%100%96%41, 42
packages/contract/src/__test__
   test-utils.ts0%100%100%13, 20
packages/contract/src/contracts
   contract-factory.ts57.14%80%78.38%33, 37, 38, 43, 46, 46, 46, 47, 48, 50, 51, 56, 60, 61
   contract.ts80%100%100%23
packages/contract/src/contracts/functions
   base-invocation-scope.ts94.12%100%100%143, 166
   invocation-results.ts66.67%100%100%15, 29
   invocation-scope.ts60%100%100%23, 40
   multicall-scope.ts100%100%100%
packages/contract/src/contracts/multicall/static-out
   multicall-bin.ts100%100%100%
packages/example-contract/src/example-contract-types
   index.ts100%100%100%
packages/example-contract/src/example-contract-types/factories
   ExampleContractAbi__factory.ts100%50%83.33%37
packages/fuels/src
   index.ts100%100%100%
packages/hasher/src
   hasher.ts87.50%100%97.50%40, 58
   index.ts100%100%100%
packages/hdwallet/src
   hdwallet-spec.ts100%100%100%
   hdwallet.ts80.39%100%95.79%117, 118, 180, 181, 219, 22, 22, 24, 26, 39, 42, 43, 86, 87
   index.ts100%100%100%
packages/interfaces/src
   index.ts100%100%100%
packages/keystore/src
   aes-ctr-node.ts100%100%100%
   aes-ctr-web.ts100%0%24%15, 16, 17, 18, 19, 24, 25, 27, 39, 40, 41, 42, 44, 49, 51, 52, 54, 55, 57
   aes-ctr.ts80%75%72.22%19, 19, 20, 23, 26, 38
   index.ts100%100%100%
   keystore.ts50%75%100%17, 27
   randomBytes.ts50%100%100%4
   universal-crypto.ts83.33%100%72.73%15, 18, 19, 29
packages/math/src
   bn.ts100%100%100%
   convert.ts85.71%100%94.44%21, 22
   index.ts100%100%100%
   math.ts100%100%100%
packages/merkle-shared/src
   common.ts100%100%100%
   cryptography.ts100%100%100%
   index.ts100%100%100%
packages/merkle/src
   binaryMerkleTree.ts71.43%100%97.01%110, 113, 72, 73
   index.ts100%100%100%
packages/merkle/src/types
   node.ts100%100%100%
packages/merklesum/src
   sumMerkleTree.ts83.33%100%97.06%129, 133, 134
packages/merklesum/src/types
   node.ts100%100%100%
   proof.ts100%100%100%
packages/mnemonic/src
   index.ts100%100%100%
   mnemonic-specs.ts100%100%100%
   mnemonic.ts80.95%100%96.08%141, 142, 157, 40, 41, 83
   utils.ts56.25%100%79.17%17, 20, 20, 20, 21, 22, 24, 24, 24, 24, 25, 29, 30, 31, 32, 33, 35, 36, 37, 58, 62, 63
packages/predicate/src
   predicate.ts100%100%100%
packages/predicate/src/test-predicate-address
   index.ts100%100%100%
packages/predicate/src/test-predicate-false
   index.ts100%100%100%
packages/predicate/src/test-predicate-struct
   index.ts100%100%100%
packages/predicate/src/test-predicate-true
   index.ts100%100%100%
packages/predicate/src/test-predicate-u32
   index.ts100%100%100%
packages/providers/src
   coin-quantity.ts66.67%100%100%17, 20
   coin.ts100%0%100%
   index.ts100%100%100%
   provider.ts47.37%73.53%71.43%106, 114, 204, 214, 215, 253, 254, 257, 258, 349, 406, 406, 406, 407, 408, 408, 408, 409, 411, 414, 416, 416, 417, 420, 425, 437, 437, 437, 438, 439, 439, 439, 440, 442, 445, 447, 447, 448, 451, 456, 458, 467, 468, 468, 469, 471, 480, 481, 481, 482, 484, 531, 572, 573, 574, 604, 605, 610
   util.ts27.27%42.86%39.39%16, 17, 17, 17, 17, 19, 20, 23, 26, 30, 31, 31, 32, 42, 45, 46, 46, 46, 46, 46, 48, 55, 61, 69, 74, 78, 80, 82
packages/providers/src/__generated__
   operations.ts100%64%81.44%1457, 1459, 1486, 1488, 1500, 1502, 1515, 1517, 1529, 1531, 1544, 1546, 1558, 1560, 1600, 1602, 1698, 1700
packages/providers/src/transaction-request
   index.ts100%100%100%
   input.ts77.78%100%90.91%36, 50, 70
   output.ts71.43%100%84.62%107, 58, 58, 76
   storage-slot.ts50%100%83.33%25, 26, 27
   transaction-request.ts65.22%70.37%77.30%123, 133, 145, 146, 147, 196, 197, 203, 204, 209, 210, 237, 239, 239, 240, 243, 270, 271, 294, 321, 359, 360, 372, 379, 380, 405, 406, 415, 461, 461, 462, 464, 478, 486, 487, 489, 495, 496, 504, 505, 511, 513, 540, 540, 545, 548, 79, 80, 84, 85, 86, 87, 92, 93, 94, 95
   witness.ts100%100%100%
packages/providers/src/transaction-response
   index.ts100%100%100%
   transaction-response.ts33.33%100%76.47%101, 102, 111, 111, 111, 114, 117, 118, 119, 139, 148, 149, 64, 72
packages/script/src
   constants.ts100%100%100%
   errors.ts0%0%30%13, 13, 13, 16, 16, 16, 20, 21, 22, 24, 24, 24, 27, 31, 32, 32, 32, 34, 34, 34, 37, 40, 40, 46, 47, 51, 52, 52, 53, 53
   index.ts100%100%100%
   script.ts28.57%66.67%76.47%114, 42, 43, 45, 46, 49, 50, 52, 53, 57, 87, 95, 96
   scripts.ts100%0%50%18, 19
   utils.ts0%0%37.50%11, 11, 12, 13, 14, 14, 18, 6, 6, 6
packages/signer/src
   index.ts100%100%100%
   signer.ts75%100%97.44%34, 34, 36
packages/sparsemerkle/src
   deepSparseMerkleSubTree.ts66.67%60%75%13, 14, 20, 21, 37, 38
   index.ts100%100%100%
   proofs.ts63.64%100%85.11%25, 27, 27, 27, 28, 31, 32, 32, 34, 36, 37
   sparseMerkleTree.ts77.50%100%91.60%105, 106, 116, 118, 126, 128, 129, 131, 139, 139, 143, 144, 147, 161, 162, 277, 280, 98, 99
   treeHasher.ts100%100%100%
   utils.ts100%100%100%
packages/sparsemerkle/src/types
   sparseCompactMerkleProof.ts100%100%100%
   sparseMerkleProof.ts100%100%100%
packages/transactions/src
   consts.ts100%100%100%
   index.ts100%100%100%
packages/transactions/src/coders
   byte-array.ts100%100%100%
   input.ts75%100%97.56%175, 185, 198, 208
   output.ts87.50%100%98.50%317, 343, 356, 382
   receipt.ts87.50%97.06%97.28%628, 630, 631, 633, 677, 677, 715, 716, 719, 732, 774
   storage-slot.ts100%100%100%
   transaction.ts75%100%98.56%305, 315, 328, 338
   utxo-id.ts100%100%100%
   witness.ts100%100%100%
packages/typechain-target-fuels/src/codegen
   types.ts66.04%66.67%61.19%102, 104, 116, 117, 120, 120, 120, 120, 148, 149, 152, 152, 152, 152, 153, 155, 156, 159, 161, 163, 24, 25, 25, 25, 27, 27, 28, 31, 39, 41, 41, 44, 44, 45, 47, 50, 52, 52, 53, 56, 64, 64, 95, 96
packages/typechain-target-fuels/src/parser
   abiParser.ts44.44%86.96%65%148, 200, 201, 209, 210, 218, 219, 227, 228, 252, 253, 253, 263, 264, 266, 269, 269, 270, 273, 273, 274, 277, 277, 278, 280, 280, 280, 280, 281, 284, 291, 292, 294, 297, 297, 297, 297, 297, 299, 299, 299, 302, 302, 303, 304, 304, 305, 305, 305, 306, 307, 307, 310
   parseSvmTypes.ts50%100%88%127, 128, 165, 176, 187, 192, 196, 196, 196, 196, 196, 200, 206, 208, 212, 216
packages/wallet-manager/src
   wallet-manager-spec.ts100%100%100%
   wallet-manager.ts100%100%100%
packages/wallet-manager/src/storages
   memory-storage.ts100%100%100%
packages/wallet-manager/src/vaults
   mnemonic-vault.ts85.71%100%93.33%21, 71, 74
   privatekey-vault.ts60%100%95%24, 57, 58
packages/wallet/src
   index.ts100%100%100%
   test-utils.ts66.67%100%100%8
   wallet-spec.ts100%100%100%
   wallet.ts75%95.83%94.79%138, 147, 148, 149, 175, 200, 246, 335, 62, 63
packages/wordlists/src
   index.ts100%100%100%
packages/wordlists/src/words
   english.ts100%100%100%

Copy link
Member

@luizstacio luizstacio left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Some points;

  • I think we should always prioritize type inputs as BigNumberish.
  • We should always return bn objects as values
  • Maybe we should consider export bn as BigNumber as is clear and also more familiar to ether users.

docs/index.md Outdated Show resolved Hide resolved
packages/abi-coder/src/coders/byte.ts Outdated Show resolved Hide resolved
packages/contract/README.md Outdated Show resolved Hide resolved
const { value } = await contractInstance.functions.echo_u64(INPUT).call();
expect(value).toBe(INPUT);
expect(value).toBe(toHex(INPUT));
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do you use toHex to make this value more comparable than a bn.js wrapper?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it's because both INPUT and value are gonna be BN instances (objects).

The object instances can be different, but same value. To compare the value for testing purpose we convert to Hex first

we can also do value.eq(INPUT)

QuinnLee
QuinnLee previously approved these changes Sep 2, 2022
camsjams
camsjams previously approved these changes Sep 2, 2022
@LuizAsFight LuizAsFight dismissed stale reviews from camsjams and QuinnLee via 3bcd5fd September 2, 2022 02:34
camsjams
camsjams previously approved these changes Sep 2, 2022
@github-actions
Copy link
Contributor

github-actions bot commented Sep 2, 2022

Total Coverage: 89.86%

Coverage Report
FileBranchesFuncsLinesUncovered Lines
packages/abi-coder/src
   abi-coder.ts91.18%100%96.20%131, 132, 38, 48, 58, 59
   constants.ts100%100%100%
   index.ts100%53.85%100%
   interface.ts73.08%90.91%90.32%113, 114, 132, 144, 144, 144, 146, 146, 147, 150, 42, 47, 92
   json-abi.ts85.71%100%96.67%125, 126, 75, 76
   utilities.ts100%100%100%
packages/abi-coder/src/coders
   abstract-coder.ts100%100%87.50%48
   array.ts50%100%93.75%23, 24
   b256.ts66.67%100%94.44%30, 31
   boolean.ts60%100%81.25%16, 18, 19, 30, 31
   byte.ts0%100%92.86%25, 26
   enum.ts66.67%100%97.22%61, 62
   number.ts100%100%100%
   option.ts100%100%100%
   string.ts100%100%100%
   struct.ts100%100%100%
   tuple.ts100%100%100%
   u64.ts100%100%100%
packages/abi-coder/src/fragments
   fragment.ts100%100%100%
   function-fragment.ts100%100%100%
   param-type.ts83.33%100%97.37%105, 106, 71, 75
packages/address/src
   address.ts71.43%100%95.65%107, 25, 26
   index.ts100%100%100%
   utils.ts87.50%100%96.55%83, 84
packages/constants/src
   index.ts100%100%100%
packages/contract/src
   index.ts100%100%100%
   scripts.ts81.25%100%94.12%38, 39, 91, 92, 94, 95
   util.ts0%100%96%41, 42
packages/contract/src/__test__
   test-utils.ts100%100%100%
packages/contract/src/contracts
   contract-factory.ts57.14%80%78.38%33, 37, 38, 43, 46, 46, 46, 47, 48, 50, 51, 56, 60, 61
   contract.ts80%100%100%23
packages/contract/src/contracts/functions
   base-invocation-scope.ts92.86%100%100%140, 162
   invocation-results.ts66.67%100%100%16, 30
   invocation-scope.ts60%100%100%23, 40
   multicall-scope.ts100%100%100%
packages/contract/src/contracts/multicall/static-out
   multicall-bin.ts100%100%100%
packages/example-contract/src/example-contract-types
   index.ts100%100%100%
packages/example-contract/src/example-contract-types/factories
   ExampleContractAbi__factory.ts100%50%83.33%37
packages/fuels/src
   index.ts100%100%100%
packages/hasher/src
   hasher.ts87.50%100%97.50%40, 58
   index.ts100%100%100%
packages/hdwallet/src
   hdwallet-spec.ts100%100%100%
   hdwallet.ts80.39%100%95.79%117, 118, 180, 181, 219, 22, 22, 24, 26, 39, 42, 43, 86, 87
   index.ts100%100%100%
packages/interfaces/src
   index.ts100%100%100%
packages/keystore/src
   aes-ctr-node.ts100%100%100%
   aes-ctr-web.ts100%0%24%15, 16, 17, 18, 19, 24, 25, 27, 39, 40, 41, 42, 44, 49, 51, 52, 54, 55, 57
   aes-ctr.ts80%75%72.22%19, 19, 20, 23, 26, 38
   index.ts100%100%100%
   keystore.ts50%75%100%17, 27
   randomBytes.ts50%100%100%4
   universal-crypto.ts83.33%100%72.73%15, 18, 19, 29
packages/math/src
   bn.ts94.44%86.21%89.29%121, 125, 133, 193, 195, 68, 69
   convert.ts100%100%100%
   index.ts100%100%100%
   math.ts100%100%100%
packages/merkle-shared/src
   common.ts100%100%100%
   cryptography.ts100%100%100%
   index.ts100%100%100%
packages/merkle/src
   binaryMerkleTree.ts71.43%100%97.01%110, 113, 72, 73
   index.ts100%100%100%
packages/merkle/src/types
   node.ts100%100%100%
packages/merklesum/src
   sumMerkleTree.ts83.33%100%97.06%133, 137, 138
packages/merklesum/src/types
   node.ts100%100%100%
   proof.ts100%100%100%
packages/mnemonic/src
   index.ts100%100%100%
   mnemonic-specs.ts100%100%100%
   mnemonic.ts80.95%100%96.08%141, 142, 157, 40, 41, 83
   utils.ts56.25%100%79.17%17, 20, 20, 20, 21, 22, 24, 24, 24, 24, 25, 29, 30, 31, 32, 33, 35, 36, 37, 58, 62, 63
packages/predicate/src
   predicate.ts100%100%100%
packages/predicate/src/test-predicate-address
   index.ts100%100%100%
packages/predicate/src/test-predicate-false
   index.ts100%100%100%
packages/predicate/src/test-predicate-struct
   index.ts100%100%100%
packages/predicate/src/test-predicate-true
   index.ts100%100%100%
packages/predicate/src/test-predicate-u32
   index.ts100%100%100%
packages/providers/src
   coin-quantity.ts66.67%100%100%17, 20
   coin.ts100%0%100%
   index.ts100%100%100%
   provider.ts47.22%74.29%71.09%102, 110, 199, 209, 210, 245, 246, 330, 390, 390, 390, 391, 392, 392, 392, 393, 395, 398, 400, 400, 401, 404, 409, 421, 421, 421, 422, 423, 423, 423, 424, 426, 429, 431, 431, 432, 435, 440, 442, 451, 452, 452, 453, 455, 464, 465, 465, 466, 468, 515, 556, 557, 558, 588, 589, 594
   util.ts27.27%42.86%39.39%17, 18, 18, 18, 18, 20, 21, 24, 27, 31, 32, 32, 33, 43, 46, 47, 47, 47, 47, 47, 49, 56, 62, 70, 75, 79, 81, 83
packages/providers/src/__generated__
   operations.ts100%64%81.63%1534, 1536, 1563, 1565, 1577, 1579, 1592, 1594, 1606, 1608, 1621, 1623, 1635, 1637, 1677, 1679, 1775, 1777
packages/providers/src/transaction-request
   index.ts100%100%100%
   input.ts77.78%100%90.91%51, 69, 93
   output.ts71.43%100%84.62%107, 58, 58, 76
   storage-slot.ts50%100%83.33%25, 26, 27
   transaction-request.ts63.49%69.23%75.56%120, 129, 140, 141, 142, 190, 191, 197, 198, 203, 204, 231, 233, 233, 234, 237, 265, 266, 289, 316, 320, 321, 349, 350, 362, 369, 370, 395, 396, 405, 450, 450, 451, 453, 465, 472, 473, 474, 480, 487, 493, 495, 522, 522, 527, 530, 78, 79, 83, 84, 85, 86, 91, 92, 93, 94
   witness.ts100%100%100%
packages/providers/src/transaction-response
   index.ts100%100%100%
   transaction-response.ts33.33%100%76.47%102, 103, 112, 112, 112, 115, 118, 119, 120, 140, 149, 150, 65, 73
packages/script/src
   constants.ts100%100%100%
   errors.ts0%0%30%13, 13, 13, 16, 16, 16, 20, 21, 22, 24, 24, 24, 27, 31, 32, 32, 32, 34, 34, 34, 37, 40, 40, 46, 47, 51, 52, 52, 53, 53
   index.ts100%100%100%
   script.ts28.57%66.67%76.47%115, 43, 44, 46, 47, 50, 51, 53, 54, 58, 88, 96, 97
   scripts.ts100%0%50%18, 19
   utils.ts0%0%37.50%11, 11, 12, 13, 14, 14, 18, 6, 6, 6
packages/signer/src
   index.ts100%100%100%
   signer.ts75%100%97.44%34, 34, 36
packages/sparsemerkle/src
   deepSparseMerkleSubTree.ts66.67%60%75%13, 14, 20, 21, 37, 38
   index.ts100%100%100%
   proofs.ts63.64%100%85.11%25, 27, 27, 27, 28, 31, 32, 32, 34, 36, 37
   sparseMerkleTree.ts77.50%100%91.60%105, 106, 116, 118, 126, 128, 129, 131, 139, 139, 143, 144, 147, 161, 162, 277, 280, 98, 99
   treeHasher.ts100%100%100%
   utils.ts100%100%100%
packages/sparsemerkle/src/types
   sparseCompactMerkleProof.ts100%100%100%
   sparseMerkleProof.ts100%100%100%
packages/transactions/src
   consts.ts100%100%100%
   index.ts100%100%100%
packages/transactions/src/coders
   byte-array.ts100%100%100%
   input.ts75%100%97.75%206, 216, 229, 239
   output.ts87.50%100%98.50%318, 344, 357, 383
   receipt.ts87.50%97.06%97.28%629, 631, 632, 634, 678, 678, 716, 717, 720, 733, 775
   storage-slot.ts100%100%100%
   transaction.ts75%100%98.43%306, 316, 329, 339
   tx-pointer.ts100%100%100%
   utxo-id.ts100%100%100%
   witness.ts100%100%100%
packages/typechain-target-fuels/src/codegen
   types.ts65.45%66.67%61.19%102, 104, 116, 117, 120, 120, 120, 120, 148, 149, 152, 152, 152, 152, 153, 155, 156, 159, 161, 163, 184, 24, 25, 25, 25, 27, 27, 28, 31, 39, 41, 41, 44, 44, 45, 47, 50, 52, 52, 53, 56, 64, 64, 95, 96
packages/typechain-target-fuels/src/parser
   abiParser.ts44.44%86.96%65%148, 200, 201, 209, 210, 218, 219, 227, 228, 252, 253, 253, 263, 264, 266, 269, 269, 270, 273, 273, 274, 277, 277, 278, 280, 280, 280, 280, 281, 284, 291, 292, 294, 297, 297, 297, 297, 297, 299, 299, 299, 302, 302, 303, 304, 304, 305, 305, 305, 306, 307, 307, 310
   parseSvmTypes.ts50%100%88%127, 128, 165, 176, 187, 192, 196, 196, 196, 196, 196, 200, 206, 208, 212, 216
packages/wallet-manager/src
   wallet-manager-spec.ts100%100%100%
   wallet-manager.ts100%100%100%
packages/wallet-manager/src/storages
   memory-storage.ts100%100%100%
packages/wallet-manager/src/vaults
   mnemonic-vault.ts87.50%100%94.12%22, 79, 82
   privatekey-vault.ts60%100%95%24, 57, 58
packages/wallet/src
   index.ts100%100%100%
   test-utils.ts66.67%100%100%8
   wallet-spec.ts100%100%100%
   wallet.ts75%95.83%94.79%144, 153, 154, 155, 181, 206, 252, 341, 62, 63
packages/wordlists/src
   index.ts100%100%100%
packages/wordlists/src/words
   english.ts100%100%100%

@luizstacio
Copy link
Member

luizstacio commented Sep 2, 2022

This PR is looking good, I think we should just hold to release on version 0.15 of the SDK.

@github-actions
Copy link
Contributor

github-actions bot commented Sep 2, 2022

Total Coverage: 89.81%

Coverage Report
FileBranchesFuncsLinesUncovered Lines
packages/abi-coder/src
   abi-coder.ts91.18%100%96.20%131, 132, 38, 48, 58, 59
   constants.ts100%100%100%
   index.ts100%53.85%100%
   interface.ts73.08%90.91%90.32%113, 114, 132, 144, 144, 144, 146, 146, 147, 150, 42, 47, 92
   json-abi.ts85.71%100%96.67%125, 126, 75, 76
   utilities.ts100%100%100%
packages/abi-coder/src/coders
   abstract-coder.ts100%100%87.50%48
   array.ts50%100%93.75%23, 24
   b256.ts66.67%100%94.44%30, 31
   boolean.ts60%100%81.25%16, 18, 19, 30, 31
   byte.ts0%100%92.86%25, 26
   enum.ts66.67%100%97.22%61, 62
   number.ts100%100%100%
   option.ts100%100%100%
   string.ts100%100%100%
   struct.ts100%100%100%
   tuple.ts100%100%100%
   u64.ts100%100%100%
packages/abi-coder/src/fragments
   fragment.ts100%100%100%
   function-fragment.ts100%100%100%
   param-type.ts83.33%100%97.37%105, 106, 71, 75
packages/address/src
   address.ts71.43%100%95.65%107, 25, 26
   index.ts100%100%100%
   utils.ts87.50%100%96.55%83, 84
packages/constants/src
   index.ts100%100%100%
packages/contract/src
   index.ts100%100%100%
   scripts.ts81.25%100%94.12%38, 39, 91, 92, 94, 95
   util.ts0%100%96%41, 42
packages/contract/src/__test__
   test-utils.ts100%100%100%
packages/contract/src/contracts
   contract-factory.ts57.14%80%78.38%33, 37, 38, 43, 46, 46, 46, 47, 48, 50, 51, 56, 60, 61
   contract.ts80%100%100%23
packages/contract/src/contracts/functions
   base-invocation-scope.ts92.86%100%100%140, 162
   invocation-results.ts66.67%100%100%16, 30
   invocation-scope.ts60%100%100%23, 40
   multicall-scope.ts100%100%100%
packages/contract/src/contracts/multicall/static-out
   multicall-bin.ts100%100%100%
packages/example-contract/src/example-contract-types
   index.ts100%100%100%
packages/example-contract/src/example-contract-types/factories
   ExampleContractAbi__factory.ts100%50%83.33%33
packages/fuels/src
   index.ts100%100%100%
packages/hasher/src
   hasher.ts87.50%100%97.50%40, 58
   index.ts100%100%100%
packages/hdwallet/src
   hdwallet-spec.ts100%100%100%
   hdwallet.ts80.39%100%95.79%117, 118, 180, 181, 219, 22, 22, 24, 26, 39, 42, 43, 86, 87
   index.ts100%100%100%
packages/interfaces/src
   index.ts100%100%100%
packages/keystore/src
   aes-ctr-node.ts100%100%100%
   aes-ctr-web.ts100%0%24%15, 16, 17, 18, 19, 24, 25, 27, 39, 40, 41, 42, 44, 49, 51, 52, 54, 55, 57
   aes-ctr.ts80%75%72.22%19, 19, 20, 23, 26, 38
   index.ts100%100%100%
   keystore.ts50%75%100%17, 27
   randomBytes.ts50%100%100%4
   universal-crypto.ts83.33%100%72.73%15, 18, 19, 29
packages/math/src
   bn.ts94.44%86.21%89.29%121, 125, 133, 193, 195, 68, 69
   convert.ts100%100%100%
   index.ts100%100%100%
   math.ts100%100%100%
packages/merkle-shared/src
   common.ts100%100%100%
   cryptography.ts100%100%100%
   index.ts100%100%100%
packages/merkle/src
   binaryMerkleTree.ts71.43%100%97.01%110, 113, 72, 73
   index.ts100%100%100%
packages/merkle/src/types
   node.ts100%100%100%
packages/merklesum/src
   sumMerkleTree.ts83.33%100%97.06%133, 137, 138
packages/merklesum/src/types
   node.ts100%100%100%
   proof.ts100%100%100%
packages/mnemonic/src
   index.ts100%100%100%
   mnemonic-specs.ts100%100%100%
   mnemonic.ts80.95%100%96.08%141, 142, 157, 40, 41, 83
   utils.ts56.25%100%79.17%17, 20, 20, 20, 21, 22, 24, 24, 24, 24, 25, 29, 30, 31, 32, 33, 35, 36, 37, 58, 62, 63
packages/predicate/src
   predicate.ts100%100%100%
packages/predicate/src/test-predicate-address
   index.ts100%100%100%
packages/predicate/src/test-predicate-false
   index.ts100%100%100%
packages/predicate/src/test-predicate-struct
   index.ts100%100%100%
packages/predicate/src/test-predicate-true
   index.ts100%100%100%
packages/predicate/src/test-predicate-u32
   index.ts100%100%100%
packages/providers/src
   coin-quantity.ts66.67%100%100%17, 20
   coin.ts100%0%100%
   index.ts100%100%100%
   provider.ts47.22%74.29%71.09%102, 110, 199, 209, 210, 245, 246, 330, 390, 390, 390, 391, 392, 392, 392, 393, 395, 398, 400, 400, 401, 404, 409, 421, 421, 421, 422, 423, 423, 423, 424, 426, 429, 431, 431, 432, 435, 440, 442, 451, 452, 452, 453, 455, 464, 465, 465, 466, 468, 515, 556, 557, 558, 588, 589, 594
   util.ts27.27%42.86%39.39%17, 18, 18, 18, 18, 20, 21, 24, 27, 31, 32, 32, 33, 43, 46, 47, 47, 47, 47, 47, 49, 56, 62, 70, 75, 79, 81, 83
packages/providers/src/__generated__
   operations.ts100%64%81.63%1534, 1536, 1563, 1565, 1577, 1579, 1592, 1594, 1606, 1608, 1621, 1623, 1635, 1637, 1677, 1679, 1775, 1777
packages/providers/src/transaction-request
   index.ts100%100%100%
   input.ts77.78%100%90.91%51, 69, 93
   output.ts71.43%100%84.62%107, 58, 58, 76
   storage-slot.ts50%100%83.33%25, 26, 27
   transaction-request.ts63.49%69.23%75.56%120, 129, 140, 141, 142, 190, 191, 197, 198, 203, 204, 231, 233, 233, 234, 237, 265, 266, 289, 316, 320, 321, 349, 350, 362, 369, 370, 395, 396, 405, 450, 450, 451, 453, 465, 472, 473, 474, 480, 487, 493, 495, 522, 522, 527, 530, 78, 79, 83, 84, 85, 86, 91, 92, 93, 94
   witness.ts100%100%100%
packages/providers/src/transaction-response
   index.ts100%100%100%
   transaction-response.ts33.33%100%76.47%102, 103, 112, 112, 112, 115, 118, 119, 120, 140, 149, 150, 65, 73
packages/script/src
   constants.ts100%100%100%
   errors.ts0%0%30%13, 13, 13, 16, 16, 16, 20, 21, 22, 24, 24, 24, 27, 31, 32, 32, 32, 34, 34, 34, 37, 40, 40, 46, 47, 51, 52, 52, 53, 53
   index.ts100%100%100%
   script.ts28.57%66.67%76.47%115, 43, 44, 46, 47, 50, 51, 53, 54, 58, 88, 96, 97
   scripts.ts100%0%50%18, 19
   utils.ts0%0%37.50%11, 11, 12, 13, 14, 14, 18, 6, 6, 6
packages/signer/src
   index.ts100%100%100%
   signer.ts75%100%97.44%34, 34, 36
packages/sparsemerkle/src
   deepSparseMerkleSubTree.ts66.67%60%75%13, 14, 20, 21, 37, 38
   index.ts100%100%100%
   proofs.ts63.64%100%85.11%25, 27, 27, 27, 28, 31, 32, 32, 34, 36, 37
   sparseMerkleTree.ts77.50%100%91.60%105, 106, 116, 118, 126, 128, 129, 131, 139, 139, 143, 144, 147, 161, 162, 277, 280, 98, 99
   treeHasher.ts100%100%100%
   utils.ts100%100%100%
packages/sparsemerkle/src/types
   sparseCompactMerkleProof.ts100%100%100%
   sparseMerkleProof.ts100%100%100%
packages/transactions/src
   consts.ts100%100%100%
   index.ts100%100%100%
packages/transactions/src/coders
   byte-array.ts100%100%100%
   input.ts75%100%97.75%206, 216, 229, 239
   output.ts87.50%100%98.50%318, 344, 357, 383
   receipt.ts87.50%97.06%97.28%629, 631, 632, 634, 678, 678, 716, 717, 720, 733, 775
   storage-slot.ts100%100%100%
   transaction.ts75%100%98.43%306, 316, 329, 339
   tx-pointer.ts100%100%100%
   utxo-id.ts100%100%100%
   witness.ts100%100%100%
packages/typechain-target-fuels/src/codegen
   types.ts65.45%66.67%61.19%102, 104, 116, 117, 120, 120, 120, 120, 148, 149, 152, 152, 152, 152, 153, 155, 156, 159, 161, 163, 184, 24, 25, 25, 25, 27, 27, 28, 31, 39, 41, 41, 44, 44, 45, 47, 50, 52, 52, 53, 56, 64, 64, 95, 96
packages/typechain-target-fuels/src/parser
   abiParser.ts43.48%86.96%63.86%149, 201, 202, 210, 211, 219, 220, 228, 229, 253, 254, 254, 264, 265, 267, 270, 270, 271, 274, 274, 275, 278, 278, 279, 282, 282, 282, 282, 283, 286, 286, 287, 290, 297, 298, 300, 303, 303, 303, 303, 303, 305, 305, 305, 308, 308, 309, 310, 310, 311, 311, 311, 312, 313, 313, 316
   parseSvmTypes.ts50%100%88%127, 128, 165, 176, 187, 192, 196, 196, 196, 196, 196, 200, 206, 208, 212, 216
packages/wallet-manager/src
   wallet-manager-spec.ts100%100%100%
   wallet-manager.ts100%100%100%
packages/wallet-manager/src/storages
   memory-storage.ts100%100%100%
packages/wallet-manager/src/vaults
   mnemonic-vault.ts87.50%100%94.12%22, 79, 82
   privatekey-vault.ts60%100%95%24, 57, 58
packages/wallet/src
   index.ts100%100%100%
   test-utils.ts66.67%100%100%8
   wallet-spec.ts100%100%100%
   wallet.ts75%95.83%94.79%144, 153, 154, 155, 181, 206, 252, 341, 62, 63
packages/wordlists/src
   index.ts100%100%100%
packages/wordlists/src/words
   english.ts100%100%100%

@LuizAsFight LuizAsFight enabled auto-merge (squash) September 2, 2022 17:02
@github-actions
Copy link
Contributor

github-actions bot commented Sep 3, 2022

Coverage report

St.
Category Percentage Covered / Total
🟢 Statements 89.95% 3214/3573
🟡 Branches 70.3% 594/845
🟢 Functions 87.5% 644/736
🟢 Lines 89.81% 3084/3434
Show new covered files 🐣
St.
File Statements Branches Functions Lines
🟢 math/src/bn.ts 89.66% 94.44% 86.21% 89.29%
🟢
... / u64.ts
100% 100% 100% 100%
Show files with reduced coverage 🔻
St.
File Statements Branches Functions Lines
🟡
... / provider.ts
72.59% 47.22% 74.29% 71.09%
🟢
... / boolean.ts
81.25% (-1.1% 🔻)
60% 100%
81.25% (-1.1% 🔻)
🟢
... / byte.ts
92.86% (-1.26% 🔻)
0% (-50% 🔻)
100%
92.86% (-1.26% 🔻)
🟢
... / hdwallet.ts
94.85% 80.39% 100% 95.79%
🟡
... / script.ts
76.47% 28.57% 66.67% 76.47%

Test suite run success

486 tests passing in 44 suites.

Report generated by 🧪jest coverage report action from 39cf885

QuinnLee
QuinnLee previously approved these changes Sep 6, 2022
Copy link
Contributor

@QuinnLee QuinnLee left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

}
// END ANCHOR: HELPERS

// ANCHOR: OVERRIDES to accept better inputs
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍🏼

camsjams
camsjams previously approved these changes Sep 6, 2022
Copy link
Contributor

@camsjams camsjams left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

:shipit: LGTM

@luizstacio luizstacio dismissed stale reviews from camsjams and QuinnLee via 9da3dd6 September 6, 2022 16:41
@LuizAsFight LuizAsFight merged commit 7ad3d79 into master Sep 6, 2022
@LuizAsFight LuizAsFight deleted the lf-280/feat/purge-bigints branch September 6, 2022 16:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Improve BigInts UX
4 participants