@firmachain/firma-js 0.2.64 → 0.3.1

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 (206) hide show
  1. package/README.md +1 -1
  2. package/dist/sdk/FirmaAuthzService.d.ts +8 -8
  3. package/dist/sdk/FirmaAuthzService.js +12 -6
  4. package/dist/sdk/FirmaBankService.d.ts +4 -4
  5. package/dist/sdk/FirmaContractService.d.ts +4 -4
  6. package/dist/sdk/FirmaCosmWasmCw20.d.ts +14 -14
  7. package/dist/sdk/FirmaCosmWasmCw721.d.ts +14 -14
  8. package/dist/sdk/FirmaCosmWasmCwBridge.d.ts +9 -9
  9. package/dist/sdk/FirmaCosmWasmCwMarketplace.d.ts +8 -8
  10. package/dist/sdk/FirmaCosmWasmService.d.ts +8 -8
  11. package/dist/sdk/FirmaCosmWasmService.js +2 -3
  12. package/dist/sdk/FirmaDistributionService.d.ts +6 -6
  13. package/dist/sdk/FirmaFeeGrantService.d.ts +4 -4
  14. package/dist/sdk/FirmaGovService.d.ts +27 -16
  15. package/dist/sdk/FirmaGovService.js +305 -195
  16. package/dist/sdk/FirmaIbcService.d.ts +3 -4
  17. package/dist/sdk/FirmaIbcService.js +5 -2
  18. package/dist/sdk/FirmaNftService.d.ts +5 -5
  19. package/dist/sdk/FirmaStakingService.d.ts +6 -6
  20. package/dist/sdk/FirmaTokenService.d.ts +5 -5
  21. package/dist/sdk/FirmaUtil.d.ts +1 -1
  22. package/dist/sdk/FirmaUtil.js +12 -14
  23. package/dist/sdk/firmachain/amino/addresses.js +1 -1
  24. package/dist/sdk/firmachain/amino/aminomsgs.d.ts +10 -0
  25. package/dist/sdk/firmachain/amino/aminomsgs.js +5 -1
  26. package/dist/sdk/firmachain/amino/aminotypes.js +27 -10
  27. package/dist/sdk/firmachain/amino/coins.d.ts +14 -2
  28. package/dist/sdk/firmachain/amino/coins.js +26 -5
  29. package/dist/sdk/firmachain/amino/encoding.d.ts +10 -1
  30. package/dist/sdk/firmachain/amino/encoding.js +21 -3
  31. package/dist/sdk/firmachain/amino/signdoc.d.ts +21 -3
  32. package/dist/sdk/firmachain/amino/signdoc.js +37 -11
  33. package/dist/sdk/firmachain/amino/signer.d.ts +2 -1
  34. package/dist/sdk/firmachain/authz/AuthzTxTypes.d.ts +7 -6
  35. package/dist/sdk/firmachain/authz/AuthzTxTypes.js +7 -6
  36. package/dist/sdk/firmachain/bank/BankQueryClient.js +1 -1
  37. package/dist/sdk/firmachain/common/CommonTxClient.js +11 -9
  38. package/dist/sdk/firmachain/common/ITxClient.d.ts +6 -6
  39. package/dist/sdk/firmachain/common/ITxClient.js +82 -24
  40. package/dist/sdk/firmachain/common/LedgerSigningStargateClient.d.ts +4 -9
  41. package/dist/sdk/firmachain/common/LedgerSigningStargateClient.js +37 -32
  42. package/dist/sdk/firmachain/common/LedgerWallet.js +4 -8
  43. package/dist/sdk/firmachain/common/TxCommon.d.ts +1 -2
  44. package/dist/sdk/firmachain/common/accounts.d.ts +7 -3
  45. package/dist/sdk/firmachain/common/accounts.js +28 -33
  46. package/dist/sdk/firmachain/common/aminotypes.d.ts +19 -0
  47. package/dist/sdk/firmachain/common/aminotypes.js +74 -0
  48. package/dist/sdk/firmachain/common/events.d.ts +32 -0
  49. package/dist/sdk/firmachain/common/events.js +18 -0
  50. package/dist/sdk/firmachain/common/fee.d.ts +26 -0
  51. package/dist/sdk/firmachain/common/fee.js +83 -0
  52. package/dist/sdk/firmachain/common/index.d.ts +1 -0
  53. package/dist/sdk/firmachain/common/index.js +3 -0
  54. package/dist/sdk/firmachain/common/modules/auth/queries.d.ts +15 -0
  55. package/dist/sdk/firmachain/common/modules/auth/queries.js +64 -0
  56. package/dist/sdk/firmachain/common/modules/authz/aminomessages.d.ts +2 -0
  57. package/dist/sdk/firmachain/common/modules/authz/aminomessages.js +15 -0
  58. package/dist/sdk/firmachain/common/modules/authz/messages.d.ts +2 -0
  59. package/dist/sdk/firmachain/common/modules/authz/messages.js +9 -0
  60. package/dist/sdk/firmachain/common/modules/authz/queries.d.ts +10 -0
  61. package/dist/sdk/firmachain/common/modules/authz/queries.js +88 -0
  62. package/dist/sdk/firmachain/common/modules/bank/aminomessages.d.ts +35 -0
  63. package/dist/sdk/firmachain/common/modules/bank/aminomessages.js +85 -0
  64. package/dist/sdk/firmachain/common/modules/bank/messages.d.ts +8 -0
  65. package/dist/sdk/firmachain/common/modules/bank/messages.js +12 -0
  66. package/dist/sdk/firmachain/common/modules/bank/queries.d.ts +15 -0
  67. package/dist/sdk/firmachain/common/modules/bank/queries.js +128 -0
  68. package/dist/sdk/firmachain/common/modules/crisis/aminomessages.d.ts +14 -0
  69. package/dist/sdk/firmachain/common/modules/crisis/aminomessages.js +11 -0
  70. package/dist/sdk/firmachain/common/modules/distribution/aminomessages.d.ts +44 -0
  71. package/dist/sdk/firmachain/common/modules/distribution/aminomessages.js +113 -0
  72. package/dist/sdk/firmachain/common/modules/distribution/messages.d.ts +8 -0
  73. package/dist/sdk/firmachain/common/modules/distribution/messages.js +15 -0
  74. package/dist/sdk/firmachain/common/modules/distribution/queries.d.ts +16 -0
  75. package/dist/sdk/firmachain/common/modules/distribution/queries.js +171 -0
  76. package/dist/sdk/firmachain/common/modules/evidence/aminomessages.d.ts +18 -0
  77. package/dist/sdk/firmachain/common/modules/evidence/aminomessages.js +11 -0
  78. package/dist/sdk/firmachain/common/modules/feegrant/aminomessages.d.ts +2 -0
  79. package/dist/sdk/firmachain/common/modules/feegrant/aminomessages.js +14 -0
  80. package/dist/sdk/firmachain/common/modules/feegrant/messages.d.ts +2 -0
  81. package/dist/sdk/firmachain/common/modules/feegrant/messages.js +8 -0
  82. package/dist/sdk/firmachain/common/modules/feegrant/queries.d.ts +9 -0
  83. package/dist/sdk/firmachain/common/modules/feegrant/queries.js +81 -0
  84. package/dist/sdk/firmachain/common/modules/gov/aminomessages.d.ts +79 -0
  85. package/dist/sdk/firmachain/common/modules/gov/aminomessages.js +152 -0
  86. package/dist/sdk/firmachain/common/modules/gov/messages.d.ts +29 -0
  87. package/dist/sdk/firmachain/common/modules/gov/messages.js +38 -0
  88. package/dist/sdk/firmachain/common/modules/gov/queries.d.ts +19 -0
  89. package/dist/sdk/firmachain/common/modules/gov/queries.js +160 -0
  90. package/dist/sdk/firmachain/common/modules/group/aminomessages.d.ts +2 -0
  91. package/dist/sdk/firmachain/common/modules/group/aminomessages.js +8 -0
  92. package/dist/sdk/firmachain/common/modules/group/messages.d.ts +2 -0
  93. package/dist/sdk/firmachain/common/modules/group/messages.js +28 -0
  94. package/dist/sdk/firmachain/common/modules/ibc/aminomessages.d.ts +38 -0
  95. package/dist/sdk/firmachain/common/modules/ibc/aminomessages.js +55 -0
  96. package/dist/sdk/firmachain/common/modules/ibc/messages.d.ts +8 -0
  97. package/dist/sdk/firmachain/common/modules/ibc/messages.js +32 -0
  98. package/dist/sdk/firmachain/common/modules/ibc/queries.d.ts +58 -0
  99. package/dist/sdk/firmachain/common/modules/ibc/queries.js +576 -0
  100. package/dist/sdk/firmachain/common/modules/index.d.ts +32 -0
  101. package/dist/sdk/firmachain/common/modules/index.js +101 -0
  102. package/dist/sdk/firmachain/common/modules/mint/queries.d.ts +21 -0
  103. package/dist/sdk/firmachain/common/modules/mint/queries.js +95 -0
  104. package/dist/sdk/firmachain/common/modules/slashing/aminomessages.d.ts +12 -0
  105. package/dist/sdk/firmachain/common/modules/slashing/aminomessages.js +11 -0
  106. package/dist/sdk/firmachain/common/modules/slashing/queries.d.ts +10 -0
  107. package/dist/sdk/firmachain/common/modules/slashing/queries.js +88 -0
  108. package/dist/sdk/firmachain/common/modules/staking/aminomessages.d.ts +112 -0
  109. package/dist/sdk/firmachain/common/modules/staking/aminomessages.js +234 -0
  110. package/dist/sdk/firmachain/common/modules/staking/messages.d.ts +33 -0
  111. package/dist/sdk/firmachain/common/modules/staking/messages.js +37 -0
  112. package/dist/sdk/firmachain/common/modules/staking/queries.d.ts +23 -0
  113. package/dist/sdk/firmachain/common/modules/staking/queries.js +242 -0
  114. package/dist/sdk/firmachain/common/modules/tx/queries.d.ts +11 -0
  115. package/dist/sdk/firmachain/common/modules/tx/queries.js +103 -0
  116. package/dist/sdk/firmachain/common/modules/vesting/aminomessages.d.ts +16 -0
  117. package/dist/sdk/firmachain/common/modules/vesting/aminomessages.js +56 -0
  118. package/dist/sdk/firmachain/common/modules/vesting/messages.d.ts +2 -0
  119. package/dist/sdk/firmachain/common/modules/vesting/messages.js +7 -0
  120. package/dist/sdk/firmachain/common/queryclient/index.d.ts +2 -0
  121. package/dist/sdk/firmachain/common/queryclient/index.js +10 -0
  122. package/dist/sdk/firmachain/common/queryclient/queryclient.d.ts +75 -0
  123. package/dist/sdk/firmachain/common/queryclient/queryclient.js +157 -0
  124. package/dist/sdk/firmachain/common/queryclient/utils.d.ts +33 -0
  125. package/dist/sdk/firmachain/common/queryclient/utils.js +101 -0
  126. package/dist/sdk/firmachain/common/search.d.ts +10 -0
  127. package/dist/sdk/firmachain/common/search.js +7 -0
  128. package/dist/sdk/firmachain/common/signing.d.ts +8 -3
  129. package/dist/sdk/firmachain/common/signing.js +24 -12
  130. package/dist/sdk/firmachain/common/signingstargateclient.d.ts +107 -30
  131. package/dist/sdk/firmachain/common/signingstargateclient.js +445 -128
  132. package/dist/sdk/firmachain/common/stargateclient.d.ts +184 -20
  133. package/dist/sdk/firmachain/common/stargateclient.js +351 -35
  134. package/dist/sdk/firmachain/contract/ContractTxClient.d.ts +2 -2
  135. package/dist/sdk/firmachain/contract/ContractTxClient.js +4 -4
  136. package/dist/sdk/firmachain/contract/ContractTxTypes.d.ts +1 -1
  137. package/dist/sdk/firmachain/contract/ContractTxTypes.js +3 -3
  138. package/dist/sdk/firmachain/cosmwasm/CosmWasmQueryClient.js +1 -1
  139. package/dist/sdk/firmachain/feegrant/FeeGrantTxTypes.d.ts +5 -5
  140. package/dist/sdk/firmachain/feegrant/FeeGrantTxTypes.js +10 -8
  141. package/dist/sdk/firmachain/google/protobuf/any.d.ts +3 -2
  142. package/dist/sdk/firmachain/google/protobuf/any.js +2 -1
  143. package/dist/sdk/firmachain/google/protobuf/duration.d.ts +3 -2
  144. package/dist/sdk/firmachain/google/protobuf/duration.js +2 -1
  145. package/dist/sdk/firmachain/google/protobuf/timestamp.d.ts +3 -2
  146. package/dist/sdk/firmachain/google/protobuf/timestamp.js +2 -1
  147. package/dist/sdk/firmachain/gov/GovQueryClient.d.ts +13 -1
  148. package/dist/sdk/firmachain/gov/GovQueryClient.js +9 -2
  149. package/dist/sdk/firmachain/gov/GovTxClient.d.ts +12 -0
  150. package/dist/sdk/firmachain/gov/GovTxClient.js +11 -1
  151. package/dist/sdk/firmachain/nft/NftTxClient.d.ts +3 -3
  152. package/dist/sdk/firmachain/nft/NftTxClient.js +6 -6
  153. package/dist/sdk/firmachain/nft/NftTxTypes.d.ts +1 -1
  154. package/dist/sdk/firmachain/nft/NftTxTypes.js +4 -4
  155. package/dist/sdk/firmachain/staking/StakingQueryClient.d.ts +1 -0
  156. package/dist/sdk/firmachain/staking/StakingQueryClient.js +0 -1
  157. package/dist/sdk/firmachain/token/TokenTxClient.d.ts +4 -4
  158. package/dist/sdk/firmachain/token/TokenTxClient.js +8 -8
  159. package/dist/sdk/firmachain/token/TokenTxTypes.d.ts +1 -1
  160. package/dist/sdk/firmachain/token/TokenTxTypes.js +5 -5
  161. package/dist/test/00.wallet.test.js +15 -9
  162. package/dist/test/01.contract_tx.test.js +53 -45
  163. package/dist/test/02.contract_query.test.js +54 -31
  164. package/dist/test/03.contract_scenario.test.js +170 -326
  165. package/dist/test/04.bank_tx.test.js +58 -59
  166. package/dist/test/05.bank_query.test.js +51 -56
  167. package/dist/test/06.feegrant_tx.test.js +74 -89
  168. package/dist/test/07.feegrant_query.test.js +69 -27
  169. package/dist/test/08.gas_estimate.test.js +422 -392
  170. package/dist/test/09.ipfs.test.js +3 -3
  171. package/dist/test/10.nft_tx.test.js +108 -76
  172. package/dist/test/11.nft_query.test.js +41 -46
  173. package/dist/test/12.staking_tx.test.js +81 -98
  174. package/dist/test/13.staking_query.test.js +66 -12
  175. package/dist/test/14.distribution_tx.test.js +69 -78
  176. package/dist/test/15.distribution_query.test.js +81 -57
  177. package/dist/test/16.gov_tx.test.js +247 -107
  178. package/dist/test/17.gov_query.test.js +48 -9
  179. package/dist/test/18.util.test.js +6 -1
  180. package/dist/test/19.chain.test.js +50 -4
  181. package/dist/test/20.slashing_query.test.js +31 -1
  182. package/dist/test/21.token_tx.test.js +48 -56
  183. package/dist/test/22.token_query.test.js +24 -20
  184. package/dist/test/23.authz_tx.test.js +119 -240
  185. package/dist/test/24.authz_query.test.js +116 -56
  186. package/dist/test/25.cosmwasm_tx.test.js +95 -57
  187. package/dist/test/26.cosmwasm_query.test.js +66 -26
  188. package/dist/test/27.arbitary_sign.test.js +59 -67
  189. package/dist/test/28.ibc_tx.test.js +29 -17
  190. package/dist/test/29.mint_query.test.js +2 -0
  191. package/dist/test/30.cw20_tx.test.js +161 -226
  192. package/dist/test/31.cw20_query.test.js +183 -37
  193. package/dist/test/32.cw721_tx.test.js +147 -149
  194. package/dist/test/33.cw721_query.test.js +188 -36
  195. package/dist/test/34.cw_bridge_tx.test.js +266 -155
  196. package/dist/test/35.cw_bridge_tx_low.test.js +221 -81
  197. package/dist/test/36.cw_bridge_query.test.js +157 -21
  198. package/dist/test/37.cw_marketplace_tx.test.js +22 -22
  199. package/dist/test/38.cw_marketplace_query.test.js +9 -9
  200. package/dist/test/config_test.d.ts +10 -4
  201. package/dist/test/config_test.js +16 -9
  202. package/dist/test/config_test.sample.d.ts +11 -0
  203. package/dist/test/config_test.sample.js +14 -0
  204. package/package.json +9 -7
  205. package/dist/sdk/firmachain/common/signingaminostargateclient.d.ts +0 -50
  206. package/dist/sdk/firmachain/common/signingaminostargateclient.js +0 -267
@@ -35,9 +35,26 @@ var __generator = (this && this.__generator) || function (thisArg, body) {
35
35
  if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
36
36
  }
37
37
  };
38
+ var __values = (this && this.__values) || function(o) {
39
+ var s = typeof Symbol === "function" && Symbol.iterator, m = s && o[s], i = 0;
40
+ if (m) return m.call(o);
41
+ if (o && typeof o.length === "number") return {
42
+ next: function () {
43
+ if (o && i >= o.length) o = void 0;
44
+ return { value: o && o[i++], done: !o };
45
+ }
46
+ };
47
+ throw new TypeError(s ? "Object is not iterable." : "Symbol.iterator is not defined.");
48
+ };
49
+ var __importDefault = (this && this.__importDefault) || function (mod) {
50
+ return (mod && mod.__esModule) ? mod : { "default": mod };
51
+ };
38
52
  Object.defineProperty(exports, "__esModule", { value: true });
39
- var FirmaConfig_1 = require("../sdk/FirmaConfig");
53
+ var fs_1 = __importDefault(require("fs"));
54
+ var chai_1 = require("chai");
55
+ var FirmaCosmWasmService_1 = require("../sdk/FirmaCosmWasmService");
40
56
  var FirmaSDK_1 = require("../sdk/FirmaSDK");
57
+ var FirmaUtil_1 = require("../sdk/FirmaUtil");
41
58
  var config_test_1 = require("./config_test");
42
59
  describe('[36. Bridge query Test]', function () {
43
60
  var firma;
@@ -50,7 +67,7 @@ describe('[36. Bridge query Test]', function () {
50
67
  return __generator(this, function (_a) {
51
68
  switch (_a.label) {
52
69
  case 0:
53
- firma = new FirmaSDK_1.FirmaSDK(FirmaConfig_1.FirmaConfig.TestNetConfig);
70
+ firma = new FirmaSDK_1.FirmaSDK(config_test_1.TestChainConfig);
54
71
  return [4 /*yield*/, firma.Wallet.fromMnemonic(config_test_1.aliceMnemonic)];
55
72
  case 1:
56
73
  aliceWallet = _a.sent();
@@ -68,44 +85,156 @@ describe('[36. Bridge query Test]', function () {
68
85
  });
69
86
  });
70
87
  });
71
- var bridgeContractAddress = "firma1pug0zu6f93nmvjl559s0uymr92jhmn5t76p7knh9zg4sqlpygqyqg6edtf";
72
- it.skip('cw bridge get_config', function () { return __awaiter(void 0, void 0, void 0, function () {
88
+ var extractValue = function (events, eventType, attrKey) {
89
+ var e_1, _a, e_2, _b;
90
+ try {
91
+ for (var events_1 = __values(events), events_1_1 = events_1.next(); !events_1_1.done; events_1_1 = events_1.next()) {
92
+ var event_1 = events_1_1.value;
93
+ if (event_1.type === eventType) {
94
+ try {
95
+ for (var _c = (e_2 = void 0, __values(event_1.attributes)), _d = _c.next(); !_d.done; _d = _c.next()) {
96
+ var attr = _d.value;
97
+ if (attr.key === attrKey) {
98
+ return attr.value;
99
+ }
100
+ }
101
+ }
102
+ catch (e_2_1) { e_2 = { error: e_2_1 }; }
103
+ finally {
104
+ try {
105
+ if (_d && !_d.done && (_b = _c.return)) _b.call(_c);
106
+ }
107
+ finally { if (e_2) throw e_2.error; }
108
+ }
109
+ }
110
+ }
111
+ }
112
+ catch (e_1_1) { e_1 = { error: e_1_1 }; }
113
+ finally {
114
+ try {
115
+ if (events_1_1 && !events_1_1.done && (_a = events_1.return)) _a.call(events_1);
116
+ }
117
+ finally { if (e_1) throw e_1.error; }
118
+ }
119
+ return "";
120
+ };
121
+ var cw721ContractAddress = "";
122
+ var bridgeContractAddress = "";
123
+ it('[low] Cw721 contract setup', function () { return __awaiter(void 0, void 0, void 0, function () {
124
+ var wasmFile, array, storeGas, storeFee, everyBodyAccessConfig, storeCodeResult, codeId, admin, label, instantiateGas, instantiateFee, noFunds, testData, instantiateResult;
125
+ return __generator(this, function (_a) {
126
+ switch (_a.label) {
127
+ case 0:
128
+ wasmFile = fs_1.default.readFileSync("./test/sample/cw721_base.wasm");
129
+ array = new Uint8Array(wasmFile.buffer);
130
+ storeGas = 3000000;
131
+ storeFee = FirmaUtil_1.FirmaUtil.getUFCTFromFCT(0.3);
132
+ everyBodyAccessConfig = {
133
+ permission: FirmaCosmWasmService_1.AccessType.ACCESS_TYPE_EVERYBODY,
134
+ address: "",
135
+ addresses: []
136
+ };
137
+ return [4 /*yield*/, firma.CosmWasm.storeCode(aliceWallet, array, everyBodyAccessConfig, { gas: storeGas, fee: storeFee })];
138
+ case 1:
139
+ storeCodeResult = _a.sent();
140
+ codeId = extractValue(storeCodeResult.events, "store_code", "code_id");
141
+ chai_1.expect(storeCodeResult.code).to.be.equal(0);
142
+ return [4 /*yield*/, aliceWallet.getAddress()];
143
+ case 2:
144
+ admin = _a.sent();
145
+ label = "test1";
146
+ instantiateGas = 3000000;
147
+ instantiateFee = FirmaUtil_1.FirmaUtil.getUFCTFromFCT(0.3);
148
+ noFunds = [];
149
+ testData = JSON.stringify({
150
+ minter: aliceAddress,
151
+ name: "My Awesome NFT Collection",
152
+ symbol: "MAWESOME"
153
+ });
154
+ return [4 /*yield*/, firma.CosmWasm.instantiateContract(aliceWallet, admin, codeId, label, testData, noFunds, { gas: instantiateGas, fee: instantiateFee })];
155
+ case 3:
156
+ instantiateResult = _a.sent();
157
+ cw721ContractAddress = extractValue(instantiateResult.events, "instantiate", "_contract_address");
158
+ chai_1.expect(instantiateResult.code).to.be.equal(0);
159
+ return [2 /*return*/];
160
+ }
161
+ });
162
+ }); });
163
+ it('[low] Cw bridge contract setup', function () { return __awaiter(void 0, void 0, void 0, function () {
164
+ var wasmFile, array, storeCodeGas, storeCodeFee, everyBodyAccessConfig, storeCodeResult, codeId, admin, label, instantiateGas, instantiateFee, noFunds, testData, instantiateResult;
165
+ return __generator(this, function (_a) {
166
+ switch (_a.label) {
167
+ case 0:
168
+ wasmFile = fs_1.default.readFileSync("./test/sample/bridge_contract.wasm");
169
+ array = new Uint8Array(wasmFile.buffer);
170
+ storeCodeGas = 3000000;
171
+ storeCodeFee = FirmaUtil_1.FirmaUtil.getUFCTFromFCT(0.3);
172
+ everyBodyAccessConfig = {
173
+ permission: FirmaCosmWasmService_1.AccessType.ACCESS_TYPE_EVERYBODY,
174
+ address: "",
175
+ addresses: []
176
+ };
177
+ return [4 /*yield*/, firma.CosmWasm.storeCode(aliceWallet, array, everyBodyAccessConfig, { gas: storeCodeGas, fee: storeCodeFee })];
178
+ case 1:
179
+ storeCodeResult = _a.sent();
180
+ codeId = extractValue(storeCodeResult.events, "store_code", "code_id");
181
+ chai_1.expect(storeCodeResult.code).to.be.equal(0);
182
+ admin = aliceAddress;
183
+ label = "CwBridge";
184
+ instantiateGas = 3000000;
185
+ instantiateFee = FirmaUtil_1.FirmaUtil.getUFCTFromFCT(0.3);
186
+ noFunds = [];
187
+ testData = JSON.stringify({
188
+ owner: admin,
189
+ cw721_address: cw721ContractAddress
190
+ });
191
+ return [4 /*yield*/, firma.CosmWasm.instantiateContract(aliceWallet, admin, codeId, label, testData, noFunds, { gas: instantiateGas, fee: instantiateFee })];
192
+ case 2:
193
+ instantiateResult = _a.sent();
194
+ bridgeContractAddress = extractValue(instantiateResult.events, "instantiate", "_contract_address");
195
+ chai_1.expect(instantiateResult.code).to.be.equal(0);
196
+ return [2 /*return*/];
197
+ }
198
+ });
199
+ }); });
200
+ it('cw bridge get_config', function () { return __awaiter(void 0, void 0, void 0, function () {
73
201
  var result;
74
202
  return __generator(this, function (_a) {
75
203
  switch (_a.label) {
76
204
  case 0: return [4 /*yield*/, firma.CwBridge.getConfig(bridgeContractAddress)];
77
205
  case 1:
78
206
  result = _a.sent();
79
- console.log(result);
207
+ chai_1.expect(result).to.have.property('owner');
208
+ chai_1.expect(result).to.have.property('cw721_address');
80
209
  return [2 /*return*/];
81
210
  }
82
211
  });
83
212
  }); });
84
- it.skip('cw bridge get_owner', function () { return __awaiter(void 0, void 0, void 0, function () {
213
+ it('cw bridge get_owner', function () { return __awaiter(void 0, void 0, void 0, function () {
85
214
  var result;
86
215
  return __generator(this, function (_a) {
87
216
  switch (_a.label) {
88
217
  case 0: return [4 /*yield*/, firma.CwBridge.getOwner(bridgeContractAddress)];
89
218
  case 1:
90
219
  result = _a.sent();
91
- console.log(result);
220
+ chai_1.expect(FirmaUtil_1.FirmaUtil.isValidAddress(result)).to.be.equal(true);
92
221
  return [2 /*return*/];
93
222
  }
94
223
  });
95
224
  }); });
96
- it.skip('cw bridge get_authorized_user', function () { return __awaiter(void 0, void 0, void 0, function () {
225
+ it('cw bridge get_authorized_user', function () { return __awaiter(void 0, void 0, void 0, function () {
97
226
  var result;
98
227
  return __generator(this, function (_a) {
99
228
  switch (_a.label) {
100
229
  case 0: return [4 /*yield*/, firma.CwBridge.getAuthorizedUsers(bridgeContractAddress)];
101
230
  case 1:
102
231
  result = _a.sent();
103
- console.log(result);
232
+ chai_1.expect(result).to.be.an('array');
104
233
  return [2 /*return*/];
105
234
  }
106
235
  });
107
236
  }); });
108
- it.skip('cw bridge nft_info', function () { return __awaiter(void 0, void 0, void 0, function () {
237
+ it('cw bridge nft_info', function () { return __awaiter(void 0, void 0, void 0, function () {
109
238
  var token_id, result;
110
239
  return __generator(this, function (_a) {
111
240
  switch (_a.label) {
@@ -114,67 +243,74 @@ describe('[36. Bridge query Test]', function () {
114
243
  return [4 /*yield*/, firma.CwBridge.getNftInfo(bridgeContractAddress, token_id)];
115
244
  case 1:
116
245
  result = _a.sent();
117
- console.log(result);
246
+ if (result !== null) {
247
+ chai_1.expect(result).to.have.property('owner');
248
+ chai_1.expect(result).to.have.property('token_id');
249
+ chai_1.expect(result).to.have.property('is_deposit');
250
+ }
118
251
  return [2 /*return*/];
119
252
  }
120
253
  });
121
254
  }); });
122
- it.skip('cw bridge owner_nfts', function () { return __awaiter(void 0, void 0, void 0, function () {
255
+ it('cw bridge owner_nfts', function () { return __awaiter(void 0, void 0, void 0, function () {
123
256
  var result;
124
257
  return __generator(this, function (_a) {
125
258
  switch (_a.label) {
126
259
  case 0: return [4 /*yield*/, firma.CwBridge.getOwnerNfts(bridgeContractAddress, aliceAddress)];
127
260
  case 1:
128
261
  result = _a.sent();
129
- console.log(result);
262
+ chai_1.expect(result).to.be.an('array');
130
263
  return [2 /*return*/];
131
264
  }
132
265
  });
133
266
  }); });
134
- it.skip('cw bridge owner_nfts_info', function () { return __awaiter(void 0, void 0, void 0, function () {
267
+ it('cw bridge owner_nfts_info', function () { return __awaiter(void 0, void 0, void 0, function () {
135
268
  var result;
136
269
  return __generator(this, function (_a) {
137
270
  switch (_a.label) {
138
271
  case 0: return [4 /*yield*/, firma.CwBridge.getOwnerNftsInfo(bridgeContractAddress, aliceAddress)];
139
272
  case 1:
140
273
  result = _a.sent();
141
- console.log(result);
274
+ chai_1.expect(result).to.be.an('array');
142
275
  return [2 /*return*/];
143
276
  }
144
277
  });
145
278
  }); });
146
- it.skip('cw bridge owner_withdrawable_nfts', function () { return __awaiter(void 0, void 0, void 0, function () {
279
+ it('cw bridge owner_withdrawable_nfts', function () { return __awaiter(void 0, void 0, void 0, function () {
147
280
  var result;
148
281
  return __generator(this, function (_a) {
149
282
  switch (_a.label) {
150
283
  case 0: return [4 /*yield*/, firma.CwBridge.getOwnerWithdrawableNfts(bridgeContractAddress, bobAddress)];
151
284
  case 1:
152
285
  result = _a.sent();
153
- console.log(result);
286
+ chai_1.expect(result).to.be.an('array');
154
287
  return [2 /*return*/];
155
288
  }
156
289
  });
157
290
  }); });
158
- it.skip('cw bridge owner_unlockable_nfts', function () { return __awaiter(void 0, void 0, void 0, function () {
291
+ it('cw bridge owner_unlockable_nfts', function () { return __awaiter(void 0, void 0, void 0, function () {
159
292
  var result;
160
293
  return __generator(this, function (_a) {
161
294
  switch (_a.label) {
162
295
  case 0: return [4 /*yield*/, firma.CwBridge.getOwnerUnlockableNfts(bridgeContractAddress, aliceAddress)];
163
296
  case 1:
164
297
  result = _a.sent();
165
- console.log(result);
298
+ chai_1.expect(result).to.be.an('array');
166
299
  return [2 /*return*/];
167
300
  }
168
301
  });
169
302
  }); });
170
- it.skip('cw bridge global_tx_counts', function () { return __awaiter(void 0, void 0, void 0, function () {
303
+ it('cw bridge global_tx_counts', function () { return __awaiter(void 0, void 0, void 0, function () {
171
304
  var result;
172
305
  return __generator(this, function (_a) {
173
306
  switch (_a.label) {
174
307
  case 0: return [4 /*yield*/, firma.CwBridge.getGlobalTxCounts(bridgeContractAddress)];
175
308
  case 1:
176
309
  result = _a.sent();
177
- console.log(result);
310
+ chai_1.expect(result).to.have.property('lock_count');
311
+ chai_1.expect(result).to.have.property('unlock_count');
312
+ chai_1.expect(result).to.have.property('deposit_count');
313
+ chai_1.expect(result).to.have.property('withdraw_count');
178
314
  return [2 /*return*/];
179
315
  }
180
316
  });
@@ -36,11 +36,11 @@ var __generator = (this && this.__generator) || function (thisArg, body) {
36
36
  }
37
37
  };
38
38
  Object.defineProperty(exports, "__esModule", { value: true });
39
+ var chai_1 = require("chai");
39
40
  var FirmaConfig_1 = require("../sdk/FirmaConfig");
40
41
  var FirmaSDK_1 = require("../sdk/FirmaSDK");
41
- var chai_1 = require("chai");
42
42
  var config_test_1 = require("./config_test");
43
- describe('[37. Marketplace tx Test]', function () {
43
+ describe.skip('[37. Marketplace tx Test]', function () {
44
44
  var firma;
45
45
  var aliceWallet;
46
46
  var bobWallet;
@@ -69,10 +69,10 @@ describe('[37. Marketplace tx Test]', function () {
69
69
  });
70
70
  });
71
71
  });
72
- var cw721ContractAddress = "firma1mp3dl27wwhdkhkyed5d4ypaq7h5dewazqkqhny98sxcy2cpu23ls369adt";
73
- var cw20ContractAddress = "firma1w8jfdyfdwf39w8x3j0hs5zd70upfx3ez05sty0xf9ueewsxa9w5qd9t4cr";
74
- var marketplaceContractAddress = "firma1xzwdxkf24j8ggcdvntwp4vk66hy2nfy9rfwmnwfc5fpcv9xmtkyqphfh80";
75
- it.skip('Cw nft mint & register fct and purchase same user (fail)', function () { return __awaiter(void 0, void 0, void 0, function () {
72
+ var cw721ContractAddress = "";
73
+ var cw20ContractAddress = "";
74
+ var marketplaceContractAddress = "";
75
+ it('Cw nft mint & register fct and purchase same user (fail)', function () { return __awaiter(void 0, void 0, void 0, function () {
76
76
  var new_token_id, fctAmount, new_token_uri, owner, gas, fee, result, sale_info, registerList, bobFCTBalance;
77
77
  return __generator(this, function (_a) {
78
78
  switch (_a.label) {
@@ -131,7 +131,7 @@ describe('[37. Marketplace tx Test]', function () {
131
131
  }
132
132
  });
133
133
  }); }),
134
- it.skip('Cw nft mint & register cw20 and purchase same user (fail)', function () { return __awaiter(void 0, void 0, void 0, function () {
134
+ it('Cw nft mint & register cw20 and purchase same user (fail)', function () { return __awaiter(void 0, void 0, void 0, function () {
135
135
  var new_token_id, cw20Amount, cw20Decimal, new_token_uri, owner, gas, fee, result, sale_info, registerList, bobCw20Balance;
136
136
  return __generator(this, function (_a) {
137
137
  switch (_a.label) {
@@ -190,7 +190,7 @@ describe('[37. Marketplace tx Test]', function () {
190
190
  }
191
191
  });
192
192
  }); }),
193
- it.skip('Cw nft mint & register fct and other users cancel (fail)', function () { return __awaiter(void 0, void 0, void 0, function () {
193
+ it('Cw nft mint & register fct and other users cancel (fail)', function () { return __awaiter(void 0, void 0, void 0, function () {
194
194
  var new_token_id, fctAmount, new_token_uri, owner, gas, fee, result, sale_info, registerList, registerList2;
195
195
  return __generator(this, function (_a) {
196
196
  switch (_a.label) {
@@ -247,7 +247,7 @@ describe('[37. Marketplace tx Test]', function () {
247
247
  }
248
248
  });
249
249
  }); }),
250
- it.skip('Cw nft mint & register cw20 and other users cancel (fail)', function () { return __awaiter(void 0, void 0, void 0, function () {
250
+ it('Cw nft mint & register cw20 and other users cancel (fail)', function () { return __awaiter(void 0, void 0, void 0, function () {
251
251
  var new_token_id, cw20Amount, cw20Decimal, new_token_uri, owner, gas, fee, result, sale_info, registerList, registerList2;
252
252
  return __generator(this, function (_a) {
253
253
  switch (_a.label) {
@@ -306,7 +306,7 @@ describe('[37. Marketplace tx Test]', function () {
306
306
  }
307
307
  });
308
308
  }); }),
309
- it.skip('Cw nft mint & register cw20 and cancel', function () { return __awaiter(void 0, void 0, void 0, function () {
309
+ it('Cw nft mint & register cw20 and cancel', function () { return __awaiter(void 0, void 0, void 0, function () {
310
310
  var new_token_id, cw20Amount, cw20Decimal, new_token_uri, owner, gas, fee, result, sale_info, registerList, registerList2;
311
311
  return __generator(this, function (_a) {
312
312
  switch (_a.label) {
@@ -365,7 +365,7 @@ describe('[37. Marketplace tx Test]', function () {
365
365
  }
366
366
  });
367
367
  }); }),
368
- it.skip('Cw nft mint & register cw20 and try to purchase fct (fail)', function () { return __awaiter(void 0, void 0, void 0, function () {
368
+ it('Cw nft mint & register cw20 and try to purchase fct (fail)', function () { return __awaiter(void 0, void 0, void 0, function () {
369
369
  var new_token_id, cw20Amount, cw20Decimal, new_token_uri, owner, gas, fee, result, sale_info, registerList, bobFCTBalance;
370
370
  return __generator(this, function (_a) {
371
371
  switch (_a.label) {
@@ -419,7 +419,7 @@ describe('[37. Marketplace tx Test]', function () {
419
419
  }
420
420
  });
421
421
  }); }),
422
- it.skip('Cw nft mint & register fct and try to purchase cw20 (fail)', function () { return __awaiter(void 0, void 0, void 0, function () {
422
+ it('Cw nft mint & register fct and try to purchase cw20 (fail)', function () { return __awaiter(void 0, void 0, void 0, function () {
423
423
  var new_token_id, fctAmount, new_token_uri, owner, gas, fee, result, sale_info, registerList, bobCw20Balance;
424
424
  return __generator(this, function (_a) {
425
425
  switch (_a.label) {
@@ -474,7 +474,7 @@ describe('[37. Marketplace tx Test]', function () {
474
474
  }
475
475
  });
476
476
  }); }),
477
- it.skip('Cw nft mint & register & purchase CW20', function () { return __awaiter(void 0, void 0, void 0, function () {
477
+ it('Cw nft mint & register & purchase CW20', function () { return __awaiter(void 0, void 0, void 0, function () {
478
478
  var new_token_id, cw20Amount, cw20Decimal, new_token_uri, owner, gas, fee, result, sale_info, registerList, bobCw20Balance, nftList;
479
479
  return __generator(this, function (_a) {
480
480
  switch (_a.label) {
@@ -545,7 +545,7 @@ describe('[37. Marketplace tx Test]', function () {
545
545
  }
546
546
  });
547
547
  }); }),
548
- it.skip('Cw nft mint & register & purchase FCT', function () { return __awaiter(void 0, void 0, void 0, function () {
548
+ it('Cw nft mint & register & purchase FCT', function () { return __awaiter(void 0, void 0, void 0, function () {
549
549
  var new_token_id, fctAmount, new_token_uri, owner, gas, fee, result, sale_info, registerList, bobFCTBalance, nftList;
550
550
  return __generator(this, function (_a) {
551
551
  switch (_a.label) {
@@ -616,7 +616,7 @@ describe('[37. Marketplace tx Test]', function () {
616
616
  }
617
617
  });
618
618
  }); }),
619
- it.skip('Cw nft mint temp', function () { return __awaiter(void 0, void 0, void 0, function () {
619
+ it('Cw nft mint temp', function () { return __awaiter(void 0, void 0, void 0, function () {
620
620
  var owner, new_token_id, new_token_uri, gas, fee, result;
621
621
  return __generator(this, function (_a) {
622
622
  switch (_a.label) {
@@ -636,7 +636,7 @@ describe('[37. Marketplace tx Test]', function () {
636
636
  }
637
637
  });
638
638
  }); }),
639
- it.skip('Cw marketplace get config', function () { return __awaiter(void 0, void 0, void 0, function () {
639
+ it('Cw marketplace get config', function () { return __awaiter(void 0, void 0, void 0, function () {
640
640
  var data;
641
641
  return __generator(this, function (_a) {
642
642
  switch (_a.label) {
@@ -648,7 +648,7 @@ describe('[37. Marketplace tx Test]', function () {
648
648
  }
649
649
  });
650
650
  }); }),
651
- it.skip('Cw marketplace get register list', function () { return __awaiter(void 0, void 0, void 0, function () {
651
+ it('Cw marketplace get register list', function () { return __awaiter(void 0, void 0, void 0, function () {
652
652
  var data;
653
653
  return __generator(this, function (_a) {
654
654
  switch (_a.label) {
@@ -660,7 +660,7 @@ describe('[37. Marketplace tx Test]', function () {
660
660
  }
661
661
  });
662
662
  }); }),
663
- it.skip('Cw marketplace register sale FCT', function () { return __awaiter(void 0, void 0, void 0, function () {
663
+ it('Cw marketplace register sale FCT', function () { return __awaiter(void 0, void 0, void 0, function () {
664
664
  var token_id, fctAmount, gas, fee, result, contractFCTBalance;
665
665
  return __generator(this, function (_a) {
666
666
  switch (_a.label) {
@@ -684,7 +684,7 @@ describe('[37. Marketplace tx Test]', function () {
684
684
  }
685
685
  });
686
686
  }); }),
687
- it.skip('Cw marketplace register sale cw20', function () { return __awaiter(void 0, void 0, void 0, function () {
687
+ it('Cw marketplace register sale cw20', function () { return __awaiter(void 0, void 0, void 0, function () {
688
688
  var token_id, cw20Amount, cw20Decimal, gas, fee, result, contractNFTBalance;
689
689
  return __generator(this, function (_a) {
690
690
  switch (_a.label) {
@@ -709,7 +709,7 @@ describe('[37. Marketplace tx Test]', function () {
709
709
  }
710
710
  });
711
711
  }); }),
712
- it.skip('Cw marketplace purchase sale FCT', function () { return __awaiter(void 0, void 0, void 0, function () {
712
+ it('Cw marketplace purchase sale FCT', function () { return __awaiter(void 0, void 0, void 0, function () {
713
713
  var contractBalance, token_id, fctAmount, gas, fee, result, nftBalance, contractFCTBalance;
714
714
  return __generator(this, function (_a) {
715
715
  switch (_a.label) {
@@ -740,7 +740,7 @@ describe('[37. Marketplace tx Test]', function () {
740
740
  }
741
741
  });
742
742
  }); }),
743
- it.skip('Cw marketplace purchase sale Cw20', function () { return __awaiter(void 0, void 0, void 0, function () {
743
+ it('Cw marketplace purchase sale Cw20', function () { return __awaiter(void 0, void 0, void 0, function () {
744
744
  var token_id, cw20Amount, cw20Decimal, aliceCw20Balance, gas, fee, result, contractCw20Balance;
745
745
  return __generator(this, function (_a) {
746
746
  switch (_a.label) {
@@ -769,7 +769,7 @@ describe('[37. Marketplace tx Test]', function () {
769
769
  }
770
770
  });
771
771
  }); }),
772
- it.skip('Cw marketplace chage_owner', function () { return __awaiter(void 0, void 0, void 0, function () {
772
+ it('Cw marketplace chage_owner', function () { return __awaiter(void 0, void 0, void 0, function () {
773
773
  var new_owner, gas, fee, result, data;
774
774
  return __generator(this, function (_a) {
775
775
  switch (_a.label) {
@@ -36,10 +36,10 @@ var __generator = (this && this.__generator) || function (thisArg, body) {
36
36
  }
37
37
  };
38
38
  Object.defineProperty(exports, "__esModule", { value: true });
39
- var FirmaConfig_1 = require("../sdk/FirmaConfig");
40
39
  var FirmaSDK_1 = require("../sdk/FirmaSDK");
40
+ var FirmaConfig_1 = require("../sdk/FirmaConfig");
41
41
  var config_test_1 = require("./config_test");
42
- describe('[37. Marketplace tx Test]', function () {
42
+ describe.skip('[37. Marketplace tx Test]', function () {
43
43
  var firma;
44
44
  var aliceWallet;
45
45
  var bobWallet;
@@ -68,10 +68,10 @@ describe('[37. Marketplace tx Test]', function () {
68
68
  });
69
69
  });
70
70
  });
71
- var cw721ContractAddress = "firma1mp3dl27wwhdkhkyed5d4ypaq7h5dewazqkqhny98sxcy2cpu23ls369adt";
72
- var cw20ContractAddress = "firma1w8jfdyfdwf39w8x3j0hs5zd70upfx3ez05sty0xf9ueewsxa9w5qd9t4cr";
73
- var marketplaceContractAddress = "firma1z5msu5fdzh5sux8r77gex9920jpte2jmv0v3su0cltzs9m5e6a9st2l35f";
74
- it.skip('Cw marketplace get config', function () { return __awaiter(void 0, void 0, void 0, function () {
71
+ var cw721ContractAddress = "";
72
+ var cw20ContractAddress = "";
73
+ var marketplaceContractAddress = "";
74
+ it('Cw marketplace get config', function () { return __awaiter(void 0, void 0, void 0, function () {
75
75
  var data;
76
76
  return __generator(this, function (_a) {
77
77
  switch (_a.label) {
@@ -83,7 +83,7 @@ describe('[37. Marketplace tx Test]', function () {
83
83
  }
84
84
  });
85
85
  }); }),
86
- it.skip('Cw marketplace get owner', function () { return __awaiter(void 0, void 0, void 0, function () {
86
+ it('Cw marketplace get owner', function () { return __awaiter(void 0, void 0, void 0, function () {
87
87
  var data;
88
88
  return __generator(this, function (_a) {
89
89
  switch (_a.label) {
@@ -95,7 +95,7 @@ describe('[37. Marketplace tx Test]', function () {
95
95
  }
96
96
  });
97
97
  }); }),
98
- it.skip('Cw marketplace get register list', function () { return __awaiter(void 0, void 0, void 0, function () {
98
+ it('Cw marketplace get register list', function () { return __awaiter(void 0, void 0, void 0, function () {
99
99
  var limit, start_after, data;
100
100
  return __generator(this, function (_a) {
101
101
  switch (_a.label) {
@@ -110,7 +110,7 @@ describe('[37. Marketplace tx Test]', function () {
110
110
  }
111
111
  });
112
112
  }); }),
113
- it.skip('Cw marketplace get item', function () { return __awaiter(void 0, void 0, void 0, function () {
113
+ it('Cw marketplace get item', function () { return __awaiter(void 0, void 0, void 0, function () {
114
114
  var limit, start_after, data;
115
115
  return __generator(this, function (_a) {
116
116
  switch (_a.label) {
@@ -1,5 +1,11 @@
1
- import { FirmaConfig } from "../sdk/FirmaConfig";
1
+ import { FirmaConfig } from '../sdk/FirmaConfig';
2
2
  export declare let TestChainConfig: FirmaConfig;
3
- export declare const validatorMnemonic = "patrol three crash inmate myself soon hold merge tortoise leopard celery pill affair fall second print case ignore truly interest hammer mail short kit";
4
- export declare const aliceMnemonic = "pizza venue kangaroo desert faculty circle benefit next snap buzz gas elite speed depart clown vicious country life game choice venture wealth shrimp fault";
5
- export declare const bobMnemonic = "hope tip sick hour stamp submit coach crisp fragile plunge bargain print detect bitter lecture mouse addict until great barrel truck toilet chapter double";
3
+ export declare const validatorMnemonic = "angry water bunker where iron absurd cruise deliver clutch unique creek pyramid arch express flush pill lens concert absent enemy boring mom nuclear rose";
4
+ export declare const aliceMnemonic = "immune flavor record sphere foam planet faint grid disorder flag minute eternal beef sea camp surge extra scorpion pistol plastic happy siren juice found";
5
+ export declare const bobMnemonic = "innocent enforce visit tilt job kitten actual glory flash feed wonder license rubber outer drum sun fuel relax roof universe enrich pulse fine grid";
6
+ export declare const feeMnemonic = "long shallow crumble clown truth book oval render seed canal buffalo assist sadness elbow afraid catalog brother trade food subject must luggage bread neither";
7
+ export declare const firmaFeeMnemonic = "arrest dynamic typical lunch original glare truth narrow stairs clip canyon space alley chat drive sudden music bubble time mesh color office minor draft";
8
+ export declare const signerMnemonic1 = "couch tonight jelly pond notice spring gold tornado cancel hover hill soft table can buyer already region bean mask cart gasp include change rent";
9
+ export declare const signerMnemonic2 = "frozen never essence submit moon night cement omit final guilt border draft caution zoo gorilla illegal notable whisper try name orange hollow maximum arrive";
10
+ export declare const signerMnemonic3 = "stock vapor planet van asthma upgrade scheme fuel cushion before brief knee kick lesson gun spatial protect danger they stem stay chunk critic cram";
11
+ export declare const signerMnemonic4 = "tomorrow hospital bottom lucky insane play concert casual truly certain antique airport safe envelope relax matter cute zone boring calm pudding eyebrow mouse spawn";
@@ -1,20 +1,27 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.bobMnemonic = exports.aliceMnemonic = exports.validatorMnemonic = exports.TestChainConfig = void 0;
3
+ exports.signerMnemonic4 = exports.signerMnemonic3 = exports.signerMnemonic2 = exports.signerMnemonic1 = exports.firmaFeeMnemonic = exports.feeMnemonic = exports.bobMnemonic = exports.aliceMnemonic = exports.validatorMnemonic = exports.TestChainConfig = void 0;
4
4
  exports.TestChainConfig = {
5
- chainID: "imperium-4",
6
- rpcAddress: "http://127.0.0.1:26657",
7
- restApiAddress: "http://127.0.0.1:1317",
5
+ chainID: "roma-1",
6
+ rpcAddress: "http://192.168.30.47:26657",
7
+ restApiAddress: "http://192.168.30.47:1317",
8
8
  ipfsNodeAddress: "https://ipfs-dev.firmachain.dev",
9
9
  ipfsNodePort: 5001,
10
10
  ipfsWebApiAddress: "https://ipfs-dev.firmachain.dev",
11
11
  hdPath: "m/44'/7777777'/",
12
12
  prefix: "firma",
13
13
  denom: "ufct",
14
- isShowLog: true,
15
14
  defaultFee: 20000,
16
- defaultGas: 200000
15
+ defaultGas: 200000,
16
+ isShowLog: false,
17
17
  };
18
- exports.validatorMnemonic = "patrol three crash inmate myself soon hold merge tortoise leopard celery pill affair fall second print case ignore truly interest hammer mail short kit";
19
- exports.aliceMnemonic = "pizza venue kangaroo desert faculty circle benefit next snap buzz gas elite speed depart clown vicious country life game choice venture wealth shrimp fault";
20
- exports.bobMnemonic = "hope tip sick hour stamp submit coach crisp fragile plunge bargain print detect bitter lecture mouse addict until great barrel truck toilet chapter double";
18
+ exports.validatorMnemonic = "angry water bunker where iron absurd cruise deliver clutch unique creek pyramid arch express flush pill lens concert absent enemy boring mom nuclear rose";
19
+ exports.aliceMnemonic = "immune flavor record sphere foam planet faint grid disorder flag minute eternal beef sea camp surge extra scorpion pistol plastic happy siren juice found";
20
+ exports.bobMnemonic = "innocent enforce visit tilt job kitten actual glory flash feed wonder license rubber outer drum sun fuel relax roof universe enrich pulse fine grid";
21
+ exports.feeMnemonic = "long shallow crumble clown truth book oval render seed canal buffalo assist sadness elbow afraid catalog brother trade food subject must luggage bread neither";
22
+ exports.firmaFeeMnemonic = "arrest dynamic typical lunch original glare truth narrow stairs clip canyon space alley chat drive sudden music bubble time mesh color office minor draft";
23
+ // export const firmaFeeMnemonic = "child material talent property foot sign talent congress cargo pistol suspect screen leader owner type style patch amused stable flame sure fluid april acoustic";
24
+ exports.signerMnemonic1 = "couch tonight jelly pond notice spring gold tornado cancel hover hill soft table can buyer already region bean mask cart gasp include change rent";
25
+ exports.signerMnemonic2 = "frozen never essence submit moon night cement omit final guilt border draft caution zoo gorilla illegal notable whisper try name orange hollow maximum arrive";
26
+ exports.signerMnemonic3 = "stock vapor planet van asthma upgrade scheme fuel cushion before brief knee kick lesson gun spatial protect danger they stem stay chunk critic cram";
27
+ exports.signerMnemonic4 = "tomorrow hospital bottom lucky insane play concert casual truly certain antique airport safe envelope relax matter cute zone boring calm pudding eyebrow mouse spawn";
@@ -0,0 +1,11 @@
1
+ import { FirmaConfig } from '../sdk/FirmaConfig';
2
+ export declare let TestChainConfig: FirmaConfig;
3
+ export declare const validatorMnemonic = "";
4
+ export declare const aliceMnemonic = "";
5
+ export declare const bobMnemonic = "";
6
+ export declare const feeMnemonic = "";
7
+ export declare const firmaFeeMnemonic = "";
8
+ export declare const signerMnemonic1 = "";
9
+ export declare const signerMnemonic2 = "";
10
+ export declare const signerMnemonic3 = "";
11
+ export declare const signerMnemonic4 = "";
@@ -0,0 +1,14 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.signerMnemonic4 = exports.signerMnemonic3 = exports.signerMnemonic2 = exports.signerMnemonic1 = exports.firmaFeeMnemonic = exports.feeMnemonic = exports.bobMnemonic = exports.aliceMnemonic = exports.validatorMnemonic = exports.TestChainConfig = void 0;
4
+ var FirmaConfig_1 = require("../sdk/FirmaConfig");
5
+ exports.TestChainConfig = FirmaConfig_1.FirmaConfig.TestNetConfig;
6
+ exports.validatorMnemonic = "";
7
+ exports.aliceMnemonic = "";
8
+ exports.bobMnemonic = "";
9
+ exports.feeMnemonic = "";
10
+ exports.firmaFeeMnemonic = "";
11
+ exports.signerMnemonic1 = "";
12
+ exports.signerMnemonic2 = "";
13
+ exports.signerMnemonic3 = "";
14
+ exports.signerMnemonic4 = "";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@firmachain/firma-js",
3
- "version": "0.2.64",
3
+ "version": "0.3.1",
4
4
  "description": "The Official FirmaChain Javascript SDK written in Typescript",
5
5
  "main": "dist/index.js",
6
6
  "typings": "dist/index.d.ts",
@@ -31,17 +31,19 @@
31
31
  },
32
32
  "homepage": "https://firmachain.org",
33
33
  "dependencies": {
34
- "@cosmjs/amino": "0.26.0",
35
- "@cosmjs/launchpad": "0.25.6",
36
- "@cosmjs/math": "0.26.0",
37
- "@cosmjs/proto-signing": "0.25.6",
38
- "@cosmjs/tendermint-rpc": "0.26.0",
34
+ "@cosmjs/amino": "0.33.1",
35
+ "@cosmjs/math": "0.33.1",
36
+ "@cosmjs/proto-signing": "0.33.1",
37
+ "@cosmjs/stargate": "0.33.1",
38
+ "@cosmjs/tendermint-rpc": "0.33.1",
39
+ "@kintsugi-tech/cosmjs-types": "^0.10.0",
39
40
  "@tharsis/address-converter": "0.1.8",
40
41
  "@types/pako": "2.0.0",
41
42
  "axios": "0.27.2",
42
43
  "big-number": "2.0.0",
43
- "cosmjs-types": "0.2.0",
44
+ "cosmjs-types": "0.9.0",
44
45
  "crypto-js": "4.1.1",
46
+ "fast-deep-equal": "^3.1.3",
45
47
  "form-data": "4.0.0",
46
48
  "pako": "2.0.2",
47
49
  "protobufjs": "6.10.2",