@ledgerhq/coin-ton 0.15.0-nightly.6 → 0.15.0-nightly.8

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 (131) hide show
  1. package/.turbo/turbo-build.log +1 -1
  2. package/CHANGELOG.md +18 -0
  3. package/package.json +6 -6
  4. package/lib/__tests__/fixtures/api.fixtures.d.ts +0 -4
  5. package/lib/__tests__/fixtures/api.fixtures.d.ts.map +0 -1
  6. package/lib/__tests__/fixtures/api.fixtures.js +0 -37
  7. package/lib/__tests__/fixtures/api.fixtures.js.map +0 -1
  8. package/lib/__tests__/fixtures/common.fixtures.d.ts +0 -32
  9. package/lib/__tests__/fixtures/common.fixtures.d.ts.map +0 -1
  10. package/lib/__tests__/fixtures/common.fixtures.js +0 -176
  11. package/lib/__tests__/fixtures/common.fixtures.js.map +0 -1
  12. package/lib/__tests__/integration/bridge.integration.test.d.ts +0 -14
  13. package/lib/__tests__/integration/bridge.integration.test.d.ts.map +0 -1
  14. package/lib/__tests__/integration/bridge.integration.test.js +0 -213
  15. package/lib/__tests__/integration/bridge.integration.test.js.map +0 -1
  16. package/lib/__tests__/unit/api.unit.test.d.ts +0 -2
  17. package/lib/__tests__/unit/api.unit.test.d.ts.map +0 -1
  18. package/lib/__tests__/unit/api.unit.test.js +0 -77
  19. package/lib/__tests__/unit/api.unit.test.js.map +0 -1
  20. package/lib/__tests__/unit/broadcast.unit.test.d.ts +0 -2
  21. package/lib/__tests__/unit/broadcast.unit.test.d.ts.map +0 -1
  22. package/lib/__tests__/unit/broadcast.unit.test.js +0 -37
  23. package/lib/__tests__/unit/broadcast.unit.test.js.map +0 -1
  24. package/lib/__tests__/unit/createTransaction.unit.test.d.ts +0 -2
  25. package/lib/__tests__/unit/createTransaction.unit.test.d.ts.map +0 -1
  26. package/lib/__tests__/unit/createTransaction.unit.test.js +0 -25
  27. package/lib/__tests__/unit/createTransaction.unit.test.js.map +0 -1
  28. package/lib/__tests__/unit/deviceTransactionConfig.unit.test.d.ts +0 -2
  29. package/lib/__tests__/unit/deviceTransactionConfig.unit.test.d.ts.map +0 -1
  30. package/lib/__tests__/unit/deviceTransactionConfig.unit.test.js +0 -111
  31. package/lib/__tests__/unit/deviceTransactionConfig.unit.test.js.map +0 -1
  32. package/lib/__tests__/unit/estimateMaxSpendable.unit.test.d.ts +0 -2
  33. package/lib/__tests__/unit/estimateMaxSpendable.unit.test.d.ts.map +0 -1
  34. package/lib/__tests__/unit/estimateMaxSpendable.unit.test.js +0 -30
  35. package/lib/__tests__/unit/estimateMaxSpendable.unit.test.js.map +0 -1
  36. package/lib/__tests__/unit/getTransactionStatus.unit.test.d.ts +0 -2
  37. package/lib/__tests__/unit/getTransactionStatus.unit.test.d.ts.map +0 -1
  38. package/lib/__tests__/unit/getTransactionStatus.unit.test.js +0 -120
  39. package/lib/__tests__/unit/getTransactionStatus.unit.test.js.map +0 -1
  40. package/lib/__tests__/unit/hw-getAddress.unit.test.d.ts +0 -2
  41. package/lib/__tests__/unit/hw-getAddress.unit.test.d.ts.map +0 -1
  42. package/lib/__tests__/unit/hw-getAddress.unit.test.js +0 -54
  43. package/lib/__tests__/unit/hw-getAddress.unit.test.js.map +0 -1
  44. package/lib/__tests__/unit/logic.unit.test.d.ts +0 -2
  45. package/lib/__tests__/unit/logic.unit.test.d.ts.map +0 -1
  46. package/lib/__tests__/unit/logic.unit.test.js +0 -18
  47. package/lib/__tests__/unit/logic.unit.test.js.map +0 -1
  48. package/lib/__tests__/unit/prepareTransaction.unit.test.d.ts +0 -2
  49. package/lib/__tests__/unit/prepareTransaction.unit.test.d.ts.map +0 -1
  50. package/lib/__tests__/unit/prepareTransaction.unit.test.js +0 -109
  51. package/lib/__tests__/unit/prepareTransaction.unit.test.js.map +0 -1
  52. package/lib/__tests__/unit/signOperation.unit.test.d.ts +0 -2
  53. package/lib/__tests__/unit/signOperation.unit.test.d.ts.map +0 -1
  54. package/lib/__tests__/unit/signOperation.unit.test.js +0 -72
  55. package/lib/__tests__/unit/signOperation.unit.test.js.map +0 -1
  56. package/lib/__tests__/unit/txn.unit.test.d.ts +0 -2
  57. package/lib/__tests__/unit/txn.unit.test.d.ts.map +0 -1
  58. package/lib/__tests__/unit/txn.unit.test.js +0 -298
  59. package/lib/__tests__/unit/txn.unit.test.js.map +0 -1
  60. package/lib/__tests__/unit/utils.unit.test.d.ts +0 -2
  61. package/lib/__tests__/unit/utils.unit.test.d.ts.map +0 -1
  62. package/lib/__tests__/unit/utils.unit.test.js +0 -211
  63. package/lib/__tests__/unit/utils.unit.test.js.map +0 -1
  64. package/lib/transaction.unit.test.d.ts +0 -2
  65. package/lib/transaction.unit.test.d.ts.map +0 -1
  66. package/lib/transaction.unit.test.js +0 -663
  67. package/lib/transaction.unit.test.js.map +0 -1
  68. package/lib-es/__tests__/fixtures/api.fixtures.d.ts +0 -4
  69. package/lib-es/__tests__/fixtures/api.fixtures.d.ts.map +0 -1
  70. package/lib-es/__tests__/fixtures/api.fixtures.js +0 -34
  71. package/lib-es/__tests__/fixtures/api.fixtures.js.map +0 -1
  72. package/lib-es/__tests__/fixtures/common.fixtures.d.ts +0 -32
  73. package/lib-es/__tests__/fixtures/common.fixtures.d.ts.map +0 -1
  74. package/lib-es/__tests__/fixtures/common.fixtures.js +0 -170
  75. package/lib-es/__tests__/fixtures/common.fixtures.js.map +0 -1
  76. package/lib-es/__tests__/integration/bridge.integration.test.d.ts +0 -14
  77. package/lib-es/__tests__/integration/bridge.integration.test.d.ts.map +0 -1
  78. package/lib-es/__tests__/integration/bridge.integration.test.js +0 -207
  79. package/lib-es/__tests__/integration/bridge.integration.test.js.map +0 -1
  80. package/lib-es/__tests__/unit/api.unit.test.d.ts +0 -2
  81. package/lib-es/__tests__/unit/api.unit.test.d.ts.map +0 -1
  82. package/lib-es/__tests__/unit/api.unit.test.js +0 -52
  83. package/lib-es/__tests__/unit/api.unit.test.js.map +0 -1
  84. package/lib-es/__tests__/unit/broadcast.unit.test.d.ts +0 -2
  85. package/lib-es/__tests__/unit/broadcast.unit.test.d.ts.map +0 -1
  86. package/lib-es/__tests__/unit/broadcast.unit.test.js +0 -32
  87. package/lib-es/__tests__/unit/broadcast.unit.test.js.map +0 -1
  88. package/lib-es/__tests__/unit/createTransaction.unit.test.d.ts +0 -2
  89. package/lib-es/__tests__/unit/createTransaction.unit.test.d.ts.map +0 -1
  90. package/lib-es/__tests__/unit/createTransaction.unit.test.js +0 -20
  91. package/lib-es/__tests__/unit/createTransaction.unit.test.js.map +0 -1
  92. package/lib-es/__tests__/unit/deviceTransactionConfig.unit.test.d.ts +0 -2
  93. package/lib-es/__tests__/unit/deviceTransactionConfig.unit.test.d.ts.map +0 -1
  94. package/lib-es/__tests__/unit/deviceTransactionConfig.unit.test.js +0 -106
  95. package/lib-es/__tests__/unit/deviceTransactionConfig.unit.test.js.map +0 -1
  96. package/lib-es/__tests__/unit/estimateMaxSpendable.unit.test.d.ts +0 -2
  97. package/lib-es/__tests__/unit/estimateMaxSpendable.unit.test.d.ts.map +0 -1
  98. package/lib-es/__tests__/unit/estimateMaxSpendable.unit.test.js +0 -25
  99. package/lib-es/__tests__/unit/estimateMaxSpendable.unit.test.js.map +0 -1
  100. package/lib-es/__tests__/unit/getTransactionStatus.unit.test.d.ts +0 -2
  101. package/lib-es/__tests__/unit/getTransactionStatus.unit.test.d.ts.map +0 -1
  102. package/lib-es/__tests__/unit/getTransactionStatus.unit.test.js +0 -115
  103. package/lib-es/__tests__/unit/getTransactionStatus.unit.test.js.map +0 -1
  104. package/lib-es/__tests__/unit/hw-getAddress.unit.test.d.ts +0 -2
  105. package/lib-es/__tests__/unit/hw-getAddress.unit.test.d.ts.map +0 -1
  106. package/lib-es/__tests__/unit/hw-getAddress.unit.test.js +0 -49
  107. package/lib-es/__tests__/unit/hw-getAddress.unit.test.js.map +0 -1
  108. package/lib-es/__tests__/unit/logic.unit.test.d.ts +0 -2
  109. package/lib-es/__tests__/unit/logic.unit.test.d.ts.map +0 -1
  110. package/lib-es/__tests__/unit/logic.unit.test.js +0 -16
  111. package/lib-es/__tests__/unit/logic.unit.test.js.map +0 -1
  112. package/lib-es/__tests__/unit/prepareTransaction.unit.test.d.ts +0 -2
  113. package/lib-es/__tests__/unit/prepareTransaction.unit.test.d.ts.map +0 -1
  114. package/lib-es/__tests__/unit/prepareTransaction.unit.test.js +0 -81
  115. package/lib-es/__tests__/unit/prepareTransaction.unit.test.js.map +0 -1
  116. package/lib-es/__tests__/unit/signOperation.unit.test.d.ts +0 -2
  117. package/lib-es/__tests__/unit/signOperation.unit.test.d.ts.map +0 -1
  118. package/lib-es/__tests__/unit/signOperation.unit.test.js +0 -67
  119. package/lib-es/__tests__/unit/signOperation.unit.test.js.map +0 -1
  120. package/lib-es/__tests__/unit/txn.unit.test.d.ts +0 -2
  121. package/lib-es/__tests__/unit/txn.unit.test.d.ts.map +0 -1
  122. package/lib-es/__tests__/unit/txn.unit.test.js +0 -293
  123. package/lib-es/__tests__/unit/txn.unit.test.js.map +0 -1
  124. package/lib-es/__tests__/unit/utils.unit.test.d.ts +0 -2
  125. package/lib-es/__tests__/unit/utils.unit.test.d.ts.map +0 -1
  126. package/lib-es/__tests__/unit/utils.unit.test.js +0 -186
  127. package/lib-es/__tests__/unit/utils.unit.test.js.map +0 -1
  128. package/lib-es/transaction.unit.test.d.ts +0 -2
  129. package/lib-es/transaction.unit.test.d.ts.map +0 -1
  130. package/lib-es/transaction.unit.test.js +0 -658
  131. package/lib-es/transaction.unit.test.js.map +0 -1
@@ -1,4 +1,4 @@
1
1
 
2
- > @ledgerhq/coin-ton@0.15.0-nightly.5 build /home/runner/work/ledger-live/ledger-live/libs/coin-modules/coin-ton
2
+ > @ledgerhq/coin-ton@0.15.0-nightly.7 build /home/runner/work/ledger-live/ledger-live/libs/coin-modules/coin-ton
3
3
  > tsc && tsc -m esnext --moduleResolution bundler --outDir lib-es
4
4
 
package/CHANGELOG.md CHANGED
@@ -1,5 +1,23 @@
1
1
  # @ledgerhq/coin-ton
2
2
 
3
+ ## 0.15.0-nightly.8
4
+
5
+ ### Patch Changes
6
+
7
+ - Updated dependencies [[`c96d73f`](https://github.com/LedgerHQ/ledger-live/commit/c96d73fed0a75a9c208f78d51c34b742703a7dda)]:
8
+ - @ledgerhq/coin-framework@6.7.0-nightly.8
9
+
10
+ ## 0.15.0-nightly.7
11
+
12
+ ### Patch Changes
13
+
14
+ - Updated dependencies [[`b4ceaff`](https://github.com/LedgerHQ/ledger-live/commit/b4ceaff2ecf68d8a14e09801c76ab0b014c45286), [`f392f69`](https://github.com/LedgerHQ/ledger-live/commit/f392f6912f445cc2f7cf4dfcfd030fa3da76f736), [`cbc0648`](https://github.com/LedgerHQ/ledger-live/commit/cbc064885d8e0459e40d327a2e5389204b3ec705)]:
15
+ - @ledgerhq/cryptoassets@13.31.0-nightly.7
16
+ - @ledgerhq/types-live@6.87.0-nightly.5
17
+ - @ledgerhq/live-env@2.19.0-nightly.2
18
+ - @ledgerhq/coin-framework@6.7.0-nightly.7
19
+ - @ledgerhq/live-network@2.0.20-nightly.3
20
+
3
21
  ## 0.15.0-nightly.6
4
22
 
5
23
  ### Minor Changes
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ledgerhq/coin-ton",
3
- "version": "0.15.0-nightly.6",
3
+ "version": "0.15.0-nightly.8",
4
4
  "description": "Ton Coin integration",
5
5
  "keywords": [
6
6
  "Ledger",
@@ -54,15 +54,15 @@
54
54
  "lodash": "^4.17.21",
55
55
  "msw": "^2.0.11",
56
56
  "rxjs": "^7.8.1",
57
- "@ledgerhq/coin-framework": "^6.7.0-nightly.6",
58
- "@ledgerhq/cryptoassets": "^13.31.0-nightly.6",
57
+ "@ledgerhq/coin-framework": "^6.7.0-nightly.8",
58
+ "@ledgerhq/cryptoassets": "^13.31.0-nightly.7",
59
59
  "@ledgerhq/devices": "8.6.2-nightly.0",
60
60
  "@ledgerhq/errors": "^6.27.0-nightly.0",
61
- "@ledgerhq/live-env": "^2.19.0-nightly.1",
62
- "@ledgerhq/live-network": "^2.0.20-nightly.2",
61
+ "@ledgerhq/live-env": "^2.19.0-nightly.2",
62
+ "@ledgerhq/live-network": "^2.0.20-nightly.3",
63
63
  "@ledgerhq/logs": "^6.13.0",
64
64
  "@ledgerhq/types-cryptoassets": "^7.29.0-nightly.0",
65
- "@ledgerhq/types-live": "^6.87.0-nightly.4"
65
+ "@ledgerhq/types-live": "^6.87.0-nightly.5"
66
66
  },
67
67
  "devDependencies": {
68
68
  "@types/imurmurhash": "^0.1.4",
@@ -1,4 +0,0 @@
1
- export declare const API_TON_ENDPOINT = "https://ton.coin.ledger.com/api/v3";
2
- declare const mockServer: import("msw/node").SetupServerApi;
3
- export default mockServer;
4
- //# sourceMappingURL=api.fixtures.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"api.fixtures.d.ts","sourceRoot":"","sources":["../../../src/__tests__/fixtures/api.fixtures.ts"],"names":[],"mappings":"AAaA,eAAO,MAAM,gBAAgB,uCAAuC,CAAC;AA8BrE,QAAA,MAAM,UAAU,mCAA2B,CAAC;AAE5C,eAAe,UAAU,CAAC"}
@@ -1,37 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.API_TON_ENDPOINT = void 0;
4
- const msw_1 = require("msw");
5
- const node_1 = require("msw/node");
6
- const common_fixtures_1 = require("./common.fixtures");
7
- // Define the mock base URL for the TON API
8
- exports.API_TON_ENDPOINT = "https://ton.coin.ledger.com/api/v3";
9
- // Create request handlers for the mock server
10
- const handlers = [
11
- // Handle GET request for masterchainInfo endpoint
12
- msw_1.http.get(`${exports.API_TON_ENDPOINT}/masterchainInfo`, () => {
13
- return msw_1.HttpResponse.json(common_fixtures_1.lastBlockNumber);
14
- }),
15
- // Handle GET request for transactions endpoint
16
- msw_1.http.get(`${exports.API_TON_ENDPOINT}/transactions`, () => {
17
- return msw_1.HttpResponse.json(common_fixtures_1.tonTransactionResponse);
18
- }),
19
- // Handle GET request for account endpoint
20
- msw_1.http.get(`${exports.API_TON_ENDPOINT}/account`, () => {
21
- return msw_1.HttpResponse.json(common_fixtures_1.tonAccount);
22
- }),
23
- // Handle GET request for wallet endpoint
24
- msw_1.http.get(`${exports.API_TON_ENDPOINT}/wallet`, () => {
25
- return msw_1.HttpResponse.json(common_fixtures_1.tonWallet);
26
- }),
27
- // Handle GET request for jetton transfers endpoint
28
- msw_1.http.get(`${exports.API_TON_ENDPOINT}/jetton/transfers`, () => msw_1.HttpResponse.json(common_fixtures_1.jettonTransferResponse)),
29
- // Handle GET request for jetton wallets endpoint
30
- msw_1.http.get(`${exports.API_TON_ENDPOINT}/jetton/wallets`, () => msw_1.HttpResponse.json(common_fixtures_1.jettonWallets)),
31
- // Handle POST request for estimate fee endpoint
32
- msw_1.http.post(`${exports.API_TON_ENDPOINT}/estimateFee`, () => msw_1.HttpResponse.json(common_fixtures_1.tonEstimateFee)),
33
- ];
34
- // Set up the mock server with the defined handlers
35
- const mockServer = (0, node_1.setupServer)(...handlers);
36
- exports.default = mockServer;
37
- //# sourceMappingURL=api.fixtures.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"api.fixtures.js","sourceRoot":"","sources":["../../../src/__tests__/fixtures/api.fixtures.ts"],"names":[],"mappings":";;;AAAA,6BAAyC;AACzC,mCAAuC;AACvC,uDAQ2B;AAE3B,2CAA2C;AAC9B,QAAA,gBAAgB,GAAG,oCAAoC,CAAC;AAErE,8CAA8C;AAC9C,MAAM,QAAQ,GAAG;IACf,kDAAkD;IAClD,UAAI,CAAC,GAAG,CAAC,GAAG,wBAAgB,kBAAkB,EAAE,GAAG,EAAE;QACnD,OAAO,kBAAY,CAAC,IAAI,CAAC,iCAAe,CAAC,CAAC;IAC5C,CAAC,CAAC;IACF,+CAA+C;IAC/C,UAAI,CAAC,GAAG,CAAC,GAAG,wBAAgB,eAAe,EAAE,GAAG,EAAE;QAChD,OAAO,kBAAY,CAAC,IAAI,CAAC,wCAAsB,CAAC,CAAC;IACnD,CAAC,CAAC;IACF,0CAA0C;IAC1C,UAAI,CAAC,GAAG,CAAC,GAAG,wBAAgB,UAAU,EAAE,GAAG,EAAE;QAC3C,OAAO,kBAAY,CAAC,IAAI,CAAC,4BAAU,CAAC,CAAC;IACvC,CAAC,CAAC;IACF,yCAAyC;IACzC,UAAI,CAAC,GAAG,CAAC,GAAG,wBAAgB,SAAS,EAAE,GAAG,EAAE;QAC1C,OAAO,kBAAY,CAAC,IAAI,CAAC,2BAAS,CAAC,CAAC;IACtC,CAAC,CAAC;IACF,mDAAmD;IACnD,UAAI,CAAC,GAAG,CAAC,GAAG,wBAAgB,mBAAmB,EAAE,GAAG,EAAE,CAAC,kBAAY,CAAC,IAAI,CAAC,wCAAsB,CAAC,CAAC;IACjG,iDAAiD;IACjD,UAAI,CAAC,GAAG,CAAC,GAAG,wBAAgB,iBAAiB,EAAE,GAAG,EAAE,CAAC,kBAAY,CAAC,IAAI,CAAC,+BAAa,CAAC,CAAC;IAEtF,gDAAgD;IAChD,UAAI,CAAC,IAAI,CAAC,GAAG,wBAAgB,cAAc,EAAE,GAAG,EAAE,CAAC,kBAAY,CAAC,IAAI,CAAC,gCAAc,CAAC,CAAC;CACtF,CAAC;AAEF,mDAAmD;AACnD,MAAM,UAAU,GAAG,IAAA,kBAAW,EAAC,GAAG,QAAQ,CAAC,CAAC;AAE5C,kBAAe,UAAU,CAAC"}
@@ -1,32 +0,0 @@
1
- import BigNumber from "bignumber.js";
2
- import { TonAccountInfo, TonResponseEstimateFee, TonResponseJettonTransfer, TonResponseJettonWallets, TonResponseWalletInfo, TonTransactionsList } from "../../bridge/bridgeHelpers/api.types";
3
- import type { TonAccount, TonSubAccount, Transaction } from "../../types";
4
- export declare const mockAddress = "UQDzd8aeBOU-jqYw_ZSuZjceI5p-F4b7HMprAsUJAtRPbMol";
5
- export declare const mockAccountId = "js:2:ton:b19891a06654f21c64147550b3321bef63acd25b5dd61b688b022c42fac4831d:ton";
6
- export declare const tokenAccount: TonSubAccount;
7
- export declare const account: TonAccount;
8
- export declare const transaction: Transaction;
9
- export declare const jettonTransaction: Transaction;
10
- export declare const fees: {
11
- in_fwd_fee: number;
12
- storage_fee: number;
13
- gas_fee: number;
14
- fwd_fee: number;
15
- };
16
- export declare const totalFees: BigNumber;
17
- export declare const lastBlockNumber: {
18
- last: {
19
- seqno: number;
20
- };
21
- first: {
22
- seqno: number;
23
- };
24
- };
25
- export declare const tonAccount: TonAccountInfo;
26
- export declare const tonWallet: TonResponseWalletInfo;
27
- export declare const jettonWallets: TonResponseJettonWallets;
28
- export declare const tonEstimateFee: TonResponseEstimateFee;
29
- export declare const jettonTransferResponse: TonResponseJettonTransfer;
30
- export declare const tonTransactionResponse: TonTransactionsList;
31
- export declare const accountInfo: TonAccountInfo;
32
- //# sourceMappingURL=common.fixtures.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"common.fixtures.d.ts","sourceRoot":"","sources":["../../../src/__tests__/fixtures/common.fixtures.ts"],"names":[],"mappings":"AACA,OAAO,SAAS,MAAM,cAAc,CAAC;AACrC,OAAO,EACL,cAAc,EACd,sBAAsB,EACtB,yBAAyB,EACzB,wBAAwB,EACxB,qBAAqB,EACrB,mBAAmB,EACpB,MAAM,sCAAsC,CAAC;AAC9C,OAAO,KAAK,EAAE,UAAU,EAAE,aAAa,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC;AAE1E,eAAO,MAAM,WAAW,qDAAqD,CAAC;AAC9E,eAAO,MAAM,aAAa,kFACuD,CAAC;AAElF,eAAO,MAAM,YAAY,eAeP,CAAC;AAEnB,eAAO,MAAM,OAAO,YAWL,CAAC;AAEhB,eAAO,MAAM,WAAW,EAAE,WAOzB,CAAC;AAEF,eAAO,MAAM,iBAAiB,EAAE,WAG/B,CAAC;AAEF,eAAO,MAAM,IAAI;;;;;CAKhB,CAAC;AAEF,eAAO,MAAM,SAAS,WAErB,CAAC;AAEF,eAAO,MAAM,eAAe;;;;;;;CAO3B,CAAC;AAEF,eAAO,MAAM,UAAU,EAAE,cAMxB,CAAC;AAEF,eAAO,MAAM,SAAS,EAAE,qBAQvB,CAAC;AAEF,eAAO,MAAM,aAAa,EAAE,wBAY3B,CAAC;AAEF,eAAO,MAAM,cAAc,EAAE,sBAG5B,CAAC;AAEF,eAAO,MAAM,sBAAsB,EAAE,yBAkBpC,CAAC;AAEF,eAAO,MAAM,sBAAsB,EAAE,mBAkDpC,CAAC;AAEF,eAAO,MAAM,WAAW,EAAE,cAMzB,CAAC"}
@@ -1,176 +0,0 @@
1
- "use strict";
2
- var __importDefault = (this && this.__importDefault) || function (mod) {
3
- return (mod && mod.__esModule) ? mod : { "default": mod };
4
- };
5
- Object.defineProperty(exports, "__esModule", { value: true });
6
- exports.accountInfo = exports.tonTransactionResponse = exports.jettonTransferResponse = exports.tonEstimateFee = exports.jettonWallets = exports.tonWallet = exports.tonAccount = exports.lastBlockNumber = exports.totalFees = exports.fees = exports.jettonTransaction = exports.transaction = exports.account = exports.tokenAccount = exports.mockAccountId = exports.mockAddress = void 0;
7
- const currencies_1 = require("@ledgerhq/cryptoassets/currencies");
8
- const bignumber_js_1 = __importDefault(require("bignumber.js"));
9
- exports.mockAddress = "UQDzd8aeBOU-jqYw_ZSuZjceI5p-F4b7HMprAsUJAtRPbMol";
10
- exports.mockAccountId = "js:2:ton:b19891a06654f21c64147550b3321bef63acd25b5dd61b688b022c42fac4831d:ton";
11
- exports.tokenAccount = {
12
- id: "subAccountId",
13
- type: "TokenAccount",
14
- spendableBalance: new bignumber_js_1.default("5000000"),
15
- token: {
16
- contractAddress: "contractAddress",
17
- units: [
18
- {
19
- code: "NOT",
20
- magnitude: 9,
21
- name: "Notcoin",
22
- },
23
- ],
24
- },
25
- jettonWallet: "0:A2CC9B938389950125001F6B8AF280CACA23BE045714AD69387DD546588D667E",
26
- };
27
- exports.account = {
28
- id: exports.mockAccountId,
29
- freshAddress: exports.mockAddress,
30
- freshAddressPath: "44'/607'/0'/0'/0'/0'",
31
- xpub: "",
32
- type: "Account",
33
- currency: (0, currencies_1.getCryptoCurrencyById)("ton"),
34
- spendableBalance: new bignumber_js_1.default("1000000000"),
35
- balance: new bignumber_js_1.default("1000000000"),
36
- seedIdentifier: "seedIdentifier",
37
- subAccounts: [exports.tokenAccount],
38
- };
39
- exports.transaction = {
40
- recipient: "UQCOvQLYvTcbi5tL9MaDNzuVl3-J3vATimNm9yO5XPafLfV4",
41
- amount: new bignumber_js_1.default("1000000"),
42
- useAllAmount: false,
43
- comment: { isEncrypted: false, text: "" },
44
- family: "ton",
45
- fees: new bignumber_js_1.default(1000),
46
- };
47
- exports.jettonTransaction = {
48
- ...exports.transaction,
49
- subAccountId: "subAccountId",
50
- };
51
- exports.fees = {
52
- in_fwd_fee: 10000,
53
- storage_fee: 10000,
54
- gas_fee: 10000,
55
- fwd_fee: 10000,
56
- };
57
- exports.totalFees = (0, bignumber_js_1.default)(exports.fees.fwd_fee + exports.fees.gas_fee + exports.fees.in_fwd_fee + exports.fees.storage_fee);
58
- exports.lastBlockNumber = {
59
- last: {
60
- seqno: 38574413,
61
- },
62
- first: {
63
- seqno: 3,
64
- },
65
- };
66
- exports.tonAccount = {
67
- balance: "1000000000",
68
- last_transaction_lt: "47055058000008",
69
- last_transaction_hash: "psVQqt6rf/Lo6xyLzxx0to0jUIx8I2/4znOVf2KhAI0=",
70
- status: "active",
71
- seqno: 3,
72
- };
73
- exports.tonWallet = {
74
- balance: "7726736262",
75
- wallet_type: "wallet v4 r2",
76
- seqno: 22,
77
- wallet_id: 698983191,
78
- last_transaction_lt: "47055058000008",
79
- last_transaction_hash: "psVQqt6rf/Lo6xyLzxx0to0jUIx8I2/4znOVf2KhAI0=",
80
- status: "active",
81
- };
82
- exports.jettonWallets = {
83
- jetton_wallets: [
84
- {
85
- address: "0:495AB6C978E3C0AE7FCF863A2D4504E37CE8D2D04A5E59048301BA29EC372F79",
86
- balance: "1200000000000",
87
- owner: "0:D02D314791CB10EF3F964CC7421E4F46348C262444946F7A64C2374700E3ED19",
88
- jetton: "0:3C52A0A732A83F022E517E5C2715E0EE458A4B9772580E903FF491526C3E9137",
89
- last_transaction_lt: "30345242000008",
90
- code_hash: "3axDia4eCUnTVixqU0/BUA4i8id5BtVw1pt/yayZd6k=",
91
- data_hash: "P8j0kENM5s4zE2w5IpD8NrrSneGQ7d0mzs5yTBNPlqo=",
92
- },
93
- ],
94
- };
95
- exports.tonEstimateFee = {
96
- source_fees: exports.fees,
97
- destination_fees: [],
98
- };
99
- exports.jettonTransferResponse = {
100
- jetton_transfers: [
101
- {
102
- query_id: "1",
103
- source: "UQDnqcVSV4S9m2Y9gLAQrDerQktKSx2I1uhs6r5o_H8VT4x7",
104
- destination: exports.mockAddress,
105
- amount: "",
106
- source_wallet: "",
107
- jetton_master: "0:2F956143C461769579BAEF2E32CC2D7BC18283F40D20BB03E432CD603AC33FFC",
108
- transaction_hash: "",
109
- transaction_lt: "",
110
- transaction_now: 0,
111
- response_destination: "",
112
- custom_payload: null,
113
- forward_ton_amount: "",
114
- forward_payload: null,
115
- },
116
- ],
117
- };
118
- exports.tonTransactionResponse = {
119
- transactions: [
120
- {
121
- account: exports.mockAddress,
122
- hash: "hash",
123
- lt: "lt",
124
- now: 1718241443,
125
- orig_status: "active",
126
- end_status: "active",
127
- total_fees: "0",
128
- prev_trans_hash: "",
129
- prev_trans_lt: "",
130
- description: {
131
- aborted: true,
132
- destroyed: false,
133
- compute_ph: {
134
- success: false,
135
- exit_code: -14,
136
- },
137
- credit_first: true,
138
- },
139
- block_ref: null,
140
- in_msg: {
141
- source: "0:959EAA8BD0E3A2662D814278D51A6F997946207D48478008BEBE7F45F3EF781F",
142
- destination: exports.mockAddress,
143
- value: "13509565",
144
- hash: "inMsgHash",
145
- fwd_fee: "266669",
146
- ihr_fee: "0",
147
- created_lt: "47055058000007",
148
- created_at: "1718241443",
149
- opcode: "0xd53276db",
150
- ihr_disabled: true,
151
- bounce: false,
152
- bounced: false,
153
- import_fee: null,
154
- message_content: {
155
- hash: "Qa0w2xg42wA9taurO/aCVOqGTzjOeP3EpzD2Sl7tTss=",
156
- body: "te6cckEBAQEADgAAGNUydtsAAAAAAAAAAfRC8y4=",
157
- decoded: null,
158
- },
159
- init_state: null,
160
- },
161
- out_msgs: [],
162
- account_state_before: null,
163
- account_state_after: null,
164
- mc_block_seqno: 3,
165
- },
166
- ],
167
- address_book: {},
168
- };
169
- exports.accountInfo = {
170
- balance: "7726736262",
171
- last_transaction_lt: "47055058000008",
172
- last_transaction_hash: "lastTransactionHash",
173
- status: "active",
174
- seqno: 22,
175
- };
176
- //# sourceMappingURL=common.fixtures.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"common.fixtures.js","sourceRoot":"","sources":["../../../src/__tests__/fixtures/common.fixtures.ts"],"names":[],"mappings":";;;;;;AAAA,kEAA0E;AAC1E,gEAAqC;AAWxB,QAAA,WAAW,GAAG,kDAAkD,CAAC;AACjE,QAAA,aAAa,GACxB,+EAA+E,CAAC;AAErE,QAAA,YAAY,GAAG;IAC1B,EAAE,EAAE,cAAc;IAClB,IAAI,EAAE,cAAc;IACpB,gBAAgB,EAAE,IAAI,sBAAS,CAAC,SAAS,CAAC;IAC1C,KAAK,EAAE;QACL,eAAe,EAAE,iBAAiB;QAClC,KAAK,EAAE;YACL;gBACE,IAAI,EAAE,KAAK;gBACX,SAAS,EAAE,CAAC;gBACZ,IAAI,EAAE,SAAS;aAChB;SACF;KACF;IACD,YAAY,EAAE,oEAAoE;CAClE,CAAC;AAEN,QAAA,OAAO,GAAG;IACrB,EAAE,EAAE,qBAAa;IACjB,YAAY,EAAE,mBAAW;IACzB,gBAAgB,EAAE,sBAAsB;IACxC,IAAI,EAAE,EAAE;IACR,IAAI,EAAE,SAAS;IACf,QAAQ,EAAE,IAAA,kCAAqB,EAAC,KAAK,CAAC;IACtC,gBAAgB,EAAE,IAAI,sBAAS,CAAC,YAAY,CAAC;IAC7C,OAAO,EAAE,IAAI,sBAAS,CAAC,YAAY,CAAC;IACpC,cAAc,EAAE,gBAAgB;IAChC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5E,WAAW,EAAE,mBAAW;gBACxB,KAAK,EAAE,UAAU;gBACjB,IAAI,EAAE,WAAW;gBACjB,OAAO,EAAE,QAAQ;gBACjB,OAAO,EAAE,GAAG;gBACZ,UAAU,EAAE,gBAAgB;gBAC5B,UAAU,EAAE,YAAY;gBACxB,MAAM,EAAE,YAAY;gBACpB,YAAY,EAAE,IAAI;gBAClB,MAAM,EAAE,KAAK;gBACb,OAAO,EAAE,KAAK;gBACd,UAAU,EAAE,IAAI;gBAChB,eAAe,EAAE;oBACf,IAAI,EAAE,8CAA8C;oBACpD,IAAI,EAAE,0CAA0C;oBAChD,OAAO,EAAE,IAAI;iBACd;gBACD,UAAU,EAAE,IAAI;aACjB;YACD,QAAQ,EAAE,EAAE;YACZ,oBAAoB,EAAE,IAAI;YAC1B,mBAAmB,EAAE,IAAI;YACzB,cAAc,EAAE,CAAC;SAClB;KACF;IACD,YAAY,EAAE,EAAE;CACjB,CAAC;AAEW,QAAA,WAAW,GAAmB;IACzC,OAAO,EAAE,YAAY;IACrB,mBAAmB,EAAE,gBAAgB;IACrC,qBAAqB,EAAE,qBAAqB;IAC5C,MAAM,EAAE,QAAQ;IAChB,KAAK,EAAE,EAAE;CACV,CAAC"}
@@ -1,14 +0,0 @@
1
- import { DatasetTest } from "@ledgerhq/types-live";
2
- import { Transaction } from "../../types";
3
- export declare const dataset: DatasetTest<Transaction>;
4
- /**
5
- * NOTE: if tests are added to this file,
6
- * like done in libs/coin-polkadot/src/bridge.integration.test.ts for example,
7
- * this file fill need to be imported in ledger-live-common
8
- * libs/ledger-live-common/src/families/ton/bridge.integration.test.ts
9
- * like done for polkadot.
10
- * cf.
11
- * - libs/coin-polkadot/src/bridge.integration.test.ts
12
- * - libs/ledger-live-common/src/families/polkadot/bridge.integration.test.ts
13
- */
14
- //# sourceMappingURL=bridge.integration.test.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"bridge.integration.test.d.ts","sourceRoot":"","sources":["../../../src/__tests__/integration/bridge.integration.test.ts"],"names":[],"mappings":"AACA,OAAO,EAAkB,WAAW,EAAE,MAAM,sBAAsB,CAAC;AAInE,OAAO,EAAc,WAAW,EAAE,MAAM,aAAa,CAAC;AA+LtD,eAAO,MAAM,OAAO,EAAE,WAAW,CAAC,WAAW,CAK5C,CAAC;AAEF;;;;;;;;;GASG"}
@@ -1,213 +0,0 @@
1
- "use strict";
2
- var __importDefault = (this && this.__importDefault) || function (mod) {
3
- return (mod && mod.__esModule) ? mod : { "default": mod };
4
- };
5
- Object.defineProperty(exports, "__esModule", { value: true });
6
- exports.dataset = void 0;
7
- const errors_1 = require("@ledgerhq/errors");
8
- const bignumber_js_1 = __importDefault(require("bignumber.js"));
9
- const errors_2 = require("../../errors");
10
- const transaction_1 = require("../../transaction");
11
- const utils_1 = require("../../utils");
12
- const PUBKEY = "86196cb40cd25e9e696bc808e3f2c074ce0b39f2a2a9d482a68eafef86e4a060";
13
- const ADDRESS = "UQCOvQLYvTcbi5tL9MaDNzuVl3-J3vATimNm9yO5XPafLfV4";
14
- const ADDRESS_2 = "UQAui6M4jOYOezUGfmeONA22Ars9yjd34YIGdAR1Pcpp4sgR";
15
- const PATH = "44'/607'/0'/0'/0'/0'";
16
- const SUBACCOUNT = "js:2:ton:86196cb40cd25e9e696bc808e3f2c074ce0b39f2a2a9d482a68eafef86e4a060:ton+ton%2Fjetton%2Feqavlwfdxgf2lxm67y4yzc17wykd9a0guwpkms1gosm~!underscore!~~!underscore!~not";
17
- const ton = {
18
- IgnorePrepareTransactionFields: ["fees"],
19
- scanAccounts: [
20
- {
21
- name: "ton seed 1",
22
- apdus: `
23
- => e005000019068000002c8000025f80000000800000008000000080000000
24
- <= 86196cb40cd25e9e696bc808e3f2c074ce0b39f2a2a9d482a68eafef86e4a0609000
25
- => e005000019068000002c8000025f80000000800000008000000180000000
26
- <= b5177c2b32f9d72fa8c673cc3d61acec6a9f68eb5e4945445fdbb48a45eb48879000
27
- `,
28
- test: (expect, accounts) => {
29
- for (const account of accounts) {
30
- expect(account.derivationMode).toEqual("ton");
31
- }
32
- },
33
- },
34
- ],
35
- accounts: [
36
- {
37
- FIXME_tests: [
38
- "balance is sum of ops",
39
- "transaction Subaccount Send max", // TypeError: Cannot read properties of undefined (reading 'toString') in ts.amount
40
- ],
41
- raw: {
42
- id: `js:2:ton:${PUBKEY}:ton`,
43
- currencyId: "ton",
44
- seedIdentifier: PUBKEY,
45
- name: "TON 1",
46
- derivationMode: "ton",
47
- index: 0,
48
- freshAddress: ADDRESS,
49
- freshAddressPath: PATH,
50
- xpub: PUBKEY,
51
- blockHeight: 0,
52
- operations: [],
53
- pendingOperations: [],
54
- lastSyncDate: "",
55
- balance: "5000000000",
56
- subAccounts: [],
57
- },
58
- transactions: [
59
- {
60
- name: "Not a valid address",
61
- transaction: (0, transaction_1.fromTransactionRaw)({
62
- family: "ton",
63
- recipient: "novalidaddress",
64
- fees: "10000000",
65
- amount: "1000",
66
- comment: { isEncrypted: false, text: "" },
67
- }),
68
- expectedStatus: {
69
- errors: {
70
- recipient: new errors_1.InvalidAddress(),
71
- },
72
- warnings: {},
73
- },
74
- },
75
- {
76
- name: "Not enough balance",
77
- transaction: (0, transaction_1.fromTransactionRaw)({
78
- family: "ton",
79
- recipient: ADDRESS_2,
80
- fees: "10000000",
81
- amount: (300 * 1e9).toString(),
82
- comment: { isEncrypted: false, text: "" },
83
- }),
84
- expectedStatus: {
85
- errors: {
86
- amount: new errors_1.NotEnoughBalance(),
87
- },
88
- warnings: {},
89
- },
90
- },
91
- {
92
- name: "Invalid transferID/Memo",
93
- transaction: (0, transaction_1.fromTransactionRaw)({
94
- family: "ton",
95
- recipient: ADDRESS_2,
96
- fees: "1",
97
- amount: (1 * 1e2).toString(),
98
- comment: { isEncrypted: false, text: "😀" },
99
- }),
100
- expectedStatus: {
101
- errors: {
102
- transaction: new errors_2.TonCommentInvalid(),
103
- },
104
- warnings: {},
105
- },
106
- },
107
- {
108
- name: "New account and sufficient amount",
109
- transaction: (0, transaction_1.fromTransactionRaw)({
110
- family: "ton",
111
- recipient: ADDRESS_2,
112
- fees: "10000000",
113
- amount: "10000000",
114
- comment: { isEncrypted: false, text: "Valid" },
115
- }),
116
- expectedStatus: {
117
- amount: new bignumber_js_1.default("10000000"),
118
- errors: {},
119
- warnings: {},
120
- },
121
- },
122
- // sub account tests
123
- {
124
- name: "Subaccount Not a valid address",
125
- transaction: (0, transaction_1.fromTransactionRaw)({
126
- family: "ton",
127
- recipient: "novalidaddress",
128
- fees: "10000000",
129
- amount: "1000",
130
- comment: { isEncrypted: false, text: "" },
131
- subAccountId: SUBACCOUNT,
132
- }),
133
- expectedStatus: {
134
- errors: {
135
- recipient: new errors_1.InvalidAddress(),
136
- },
137
- warnings: {},
138
- },
139
- },
140
- {
141
- name: "Subaccount Not enough balance",
142
- transaction: (0, transaction_1.fromTransactionRaw)({
143
- family: "ton",
144
- recipient: ADDRESS_2,
145
- fees: "10000000",
146
- amount: (300 * 1e9).toString(),
147
- comment: { isEncrypted: false, text: "" },
148
- subAccountId: SUBACCOUNT,
149
- }),
150
- expectedStatus: {
151
- errors: {
152
- amount: new errors_1.NotEnoughBalance(),
153
- },
154
- warnings: {},
155
- },
156
- },
157
- {
158
- name: "Subaccount New account and sufficient amount",
159
- transaction: (0, transaction_1.fromTransactionRaw)({
160
- family: "ton",
161
- recipient: ADDRESS,
162
- fees: "10000000",
163
- amount: "10000000",
164
- comment: { isEncrypted: false, text: "Valid" },
165
- subAccountId: SUBACCOUNT,
166
- }),
167
- expectedStatus: {
168
- amount: new bignumber_js_1.default("10000000"),
169
- errors: {},
170
- warnings: {},
171
- },
172
- },
173
- {
174
- name: "Subaccount Send max",
175
- transaction: (0, transaction_1.fromTransactionRaw)({
176
- family: "ton",
177
- recipient: ADDRESS,
178
- fees: "10000000",
179
- amount: "10000000",
180
- comment: { isEncrypted: false, text: "Valid" },
181
- useAllAmount: true,
182
- subAccountId: SUBACCOUNT,
183
- }),
184
- expectedStatus: (account, tx) => {
185
- const subAccount = (0, utils_1.findSubAccountById)(account, tx.subAccountId ?? "");
186
- return {
187
- amount: subAccount?.spendableBalance,
188
- errors: {},
189
- warnings: {},
190
- };
191
- },
192
- },
193
- ],
194
- },
195
- ],
196
- };
197
- exports.dataset = {
198
- implementations: ["js"],
199
- currencies: {
200
- ton,
201
- },
202
- };
203
- /**
204
- * NOTE: if tests are added to this file,
205
- * like done in libs/coin-polkadot/src/bridge.integration.test.ts for example,
206
- * this file fill need to be imported in ledger-live-common
207
- * libs/ledger-live-common/src/families/ton/bridge.integration.test.ts
208
- * like done for polkadot.
209
- * cf.
210
- * - libs/coin-polkadot/src/bridge.integration.test.ts
211
- * - libs/ledger-live-common/src/families/polkadot/bridge.integration.test.ts
212
- */
213
- //# sourceMappingURL=bridge.integration.test.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"bridge.integration.test.js","sourceRoot":"","sources":["../../../src/__tests__/integration/bridge.integration.test.ts"],"names":[],"mappings":";;;;;;AAAA,6CAAoE;AAEpE,gEAAqC;AACrC,yCAAiD;AACjD,mDAAuD;AAEvD,uCAAiD;AAEjD,MAAM,MAAM,GAAG,kEAAkE,CAAC;AAClF,MAAM,OAAO,GAAG,kDAAkD,CAAC;AACnE,MAAM,SAAS,GAAG,kDAAkD,CAAC;AACrE,MAAM,IAAI,GAAG,sBAAsB,CAAC;AACpC,MAAM,UAAU,GACd,yKAAyK,CAAC;AAE5K,MAAM,GAAG,GAAgC;IACvC,8BAA8B,EAAE,CAAC,MAAM,CAAC;IACxC,YAAY,EAAE;QACZ;YACE,IAAI,EAAE,YAAY;YAClB,KAAK,EAAE;;;;;OAKN;YACD,IAAI,EAAE,CAAC,MAAM,EAAE,QAAQ,EAAE,EAAE;gBACzB,KAAK,MAAM,OAAO,IAAI,QAAQ,EAAE,CAAC;oBAC/B,MAAM,CAAC,OAAO,CAAC,cAAc,CAAC,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC;gBAChD,CAAC;YACH,CAAC;SACF;KACF;IACD,QAAQ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I;wBAClB,YAAY,EAAE,UAAU;qBACzB,CAAC;oBACF,cAAc,EAAE,CAAC,OAAO,EAAE,EAAE,EAAE,EAAE;wBAC9B,MAAM,UAAU,GAAG,IAAA,0BAAkB,EAAC,OAAqB,EAAE,EAAE,CAAC,YAAY,IAAI,EAAE,CAAC,CAAC;wBACpF,OAAO;4BACL,MAAM,EAAE,UAAU,EAAE,gBAAgB;4BACpC,MAAM,EAAE,EAAE;4BACV,QAAQ,EAAE,EAAE;yBACb,CAAC;oBACJ,CAAC;iBACF;aACF;SACF;KACF;CACF,CAAC;AAEW,QAAA,OAAO,GAA6B;IAC/C,eAAe,EAAE,CAAC,IAAI,CAAC;IACvB,UAAU,EAAE;QACV,GAAG;KACJ;CACF,CAAC;AAEF;;;;;;;;;GASG"}
@@ -1,2 +0,0 @@
1
- export {};
2
- //# sourceMappingURL=api.unit.test.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"api.unit.test.d.ts","sourceRoot":"","sources":["../../../src/__tests__/unit/api.unit.test.ts"],"names":[],"mappings":""}