@ledgerhq/live-common 34.35.0-nightly.2 → 34.35.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/e2e/enum/Swap.d.ts +1 -2
- package/lib/e2e/enum/Swap.d.ts.map +1 -1
- package/lib/e2e/enum/Swap.js +10 -12
- package/lib/e2e/enum/Swap.js.map +1 -1
- package/lib/e2e/families/cardano.d.ts.map +1 -1
- package/lib/e2e/families/cardano.js +26 -55
- package/lib/e2e/families/cardano.js.map +1 -1
- package/lib/e2e/families/evm.d.ts.map +1 -1
- package/lib/e2e/families/evm.js +1 -2
- package/lib/e2e/families/evm.js.map +1 -1
- package/lib/e2e/families/solana.d.ts.map +1 -1
- package/lib/e2e/families/solana.js +2 -5
- package/lib/e2e/families/solana.js.map +1 -1
- package/lib/e2e/speculos.d.ts +0 -2
- package/lib/e2e/speculos.d.ts.map +1 -1
- package/lib/e2e/speculos.js +32 -48
- package/lib/e2e/speculos.js.map +1 -1
- package/lib-es/e2e/enum/Swap.d.ts +1 -2
- package/lib-es/e2e/enum/Swap.d.ts.map +1 -1
- package/lib-es/e2e/enum/Swap.js +10 -12
- package/lib-es/e2e/enum/Swap.js.map +1 -1
- package/lib-es/e2e/families/cardano.d.ts.map +1 -1
- package/lib-es/e2e/families/cardano.js +27 -56
- package/lib-es/e2e/families/cardano.js.map +1 -1
- package/lib-es/e2e/families/evm.d.ts.map +1 -1
- package/lib-es/e2e/families/evm.js +1 -2
- package/lib-es/e2e/families/evm.js.map +1 -1
- package/lib-es/e2e/families/solana.d.ts.map +1 -1
- package/lib-es/e2e/families/solana.js +2 -5
- package/lib-es/e2e/families/solana.js.map +1 -1
- package/lib-es/e2e/speculos.d.ts +0 -2
- package/lib-es/e2e/speculos.d.ts.map +1 -1
- package/lib-es/e2e/speculos.js +31 -45
- package/lib-es/e2e/speculos.js.map +1 -1
- package/package.json +62 -62
- package/src/e2e/enum/Swap.ts +9 -10
- package/src/e2e/families/cardano.ts +28 -63
- package/src/e2e/families/evm.ts +1 -2
- package/src/e2e/families/solana.ts +2 -5
- package/src/e2e/speculos.ts +31 -46
- package/lib/e2e/enum/Device.d.ts +0 -8
- package/lib/e2e/enum/Device.d.ts.map +0 -1
- package/lib/e2e/enum/Device.js +0 -14
- package/lib/e2e/enum/Device.js.map +0 -1
- package/lib/families/hedera/logic.d.ts +0 -2
- package/lib/families/hedera/logic.d.ts.map +0 -1
- package/lib/families/hedera/logic.js +0 -19
- package/lib/families/hedera/logic.js.map +0 -1
- package/lib-es/e2e/enum/Device.d.ts +0 -8
- package/lib-es/e2e/enum/Device.d.ts.map +0 -1
- package/lib-es/e2e/enum/Device.js +0 -10
- package/lib-es/e2e/enum/Device.js.map +0 -1
- package/lib-es/families/hedera/logic.d.ts +0 -2
- package/lib-es/families/hedera/logic.d.ts.map +0 -1
- package/lib-es/families/hedera/logic.js +0 -3
- package/lib-es/families/hedera/logic.js.map +0 -1
- package/src/e2e/enum/Device.ts +0 -7
- package/src/families/hedera/logic.ts +0 -2
@@ -1,78 +1,43 @@
|
|
1
1
|
import expect from "expect";
|
2
2
|
import { Transaction } from "../models/Transaction";
|
3
|
-
import {
|
4
|
-
pressBoth,
|
5
|
-
pressUntilTextFound,
|
6
|
-
containsSubstringInEvent,
|
7
|
-
waitFor,
|
8
|
-
pressRightButton,
|
9
|
-
} from "../speculos";
|
3
|
+
import { pressBoth, pressUntilTextFound, containsSubstringInEvent, waitFor } from "../speculos";
|
10
4
|
import { DeviceLabels } from "../enum/DeviceLabels";
|
11
|
-
import { Device } from "../enum/Device";
|
12
5
|
|
13
6
|
export async function sendCardano(tx: Transaction) {
|
14
|
-
const isNanoS = process.env.SPECULOS_DEVICE === Device.LNS;
|
15
7
|
await waitFor(DeviceLabels.NEW_ORDINARY);
|
16
|
-
await
|
17
|
-
|
18
|
-
|
19
|
-
await pressBoth();
|
20
|
-
} else {
|
21
|
-
await pressUntilTextFound(DeviceLabels.SEND_TO_ADDRESS_2);
|
22
|
-
await pressBoth();
|
23
|
-
}
|
8
|
+
await pressBoth();
|
9
|
+
await pressUntilTextFound(DeviceLabels.SEND_TO_ADDRESS_2);
|
10
|
+
await pressBoth();
|
24
11
|
const events = await pressUntilTextFound(DeviceLabels.SEND);
|
25
|
-
|
26
|
-
|
27
|
-
expect(isAmountCorrect).toBeTruthy();
|
28
|
-
}
|
12
|
+
const isAmountCorrect = containsSubstringInEvent(tx.amount, events);
|
13
|
+
expect(isAmountCorrect).toBeTruthy();
|
29
14
|
await pressBoth();
|
30
15
|
await waitFor(DeviceLabels.TRANSACTION_FEE);
|
31
16
|
await pressBoth();
|
32
17
|
await waitFor(DeviceLabels.CONFIRM_TRANSACTION);
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
const isAddressCorrect = containsSubstringInEvent(tx.accountToCredit.address, events);
|
38
|
-
expect(isAddressCorrect).toBeTruthy();
|
39
|
-
}
|
18
|
+
await pressBoth();
|
19
|
+
|
20
|
+
const isAddressCorrect = containsSubstringInEvent(tx.accountToCredit.address, events);
|
21
|
+
expect(isAddressCorrect).toBeTruthy();
|
40
22
|
}
|
41
23
|
|
42
24
|
export async function delegateCardano() {
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
{ label: DeviceLabels.DELEGATE_STAKE, action: "both" },
|
62
|
-
{ label: DeviceLabels.STAKE_KEY, action: "both" },
|
63
|
-
{ label: DeviceLabels.CONFIRM, action: "right" },
|
64
|
-
{ label: DeviceLabels.CONFIRM, action: "right" },
|
65
|
-
];
|
66
|
-
|
67
|
-
const stepsToExecute =
|
68
|
-
process.env.SPECULOS_DEVICE === Device.LNS ? LNSSpecificSteps : commonSteps;
|
69
|
-
|
70
|
-
for (const step of stepsToExecute) {
|
71
|
-
await waitFor(step.label);
|
72
|
-
if (step.action === "both") {
|
73
|
-
await pressBoth();
|
74
|
-
} else if (step.action === "right") {
|
75
|
-
await pressRightButton();
|
76
|
-
}
|
77
|
-
}
|
25
|
+
await waitFor(DeviceLabels.NEW_ORDINARY);
|
26
|
+
await pressBoth();
|
27
|
+
await waitFor(DeviceLabels.TRANSACTION_FEE);
|
28
|
+
await pressBoth();
|
29
|
+
await waitFor(DeviceLabels.REGISTER);
|
30
|
+
await pressBoth();
|
31
|
+
await waitFor(DeviceLabels.STAKE_KEY);
|
32
|
+
await pressBoth();
|
33
|
+
await waitFor(DeviceLabels.CONFIRM);
|
34
|
+
await pressBoth();
|
35
|
+
await waitFor(DeviceLabels.DELEGATE_STAKE);
|
36
|
+
await pressBoth();
|
37
|
+
await waitFor(DeviceLabels.STAKE_KEY);
|
38
|
+
await pressBoth();
|
39
|
+
await waitFor(DeviceLabels.CONFIRM);
|
40
|
+
await pressBoth();
|
41
|
+
await waitFor(DeviceLabels.CONFIRM);
|
42
|
+
await pressBoth();
|
78
43
|
}
|
package/src/e2e/families/evm.ts
CHANGED
@@ -2,13 +2,12 @@ import expect from "expect";
|
|
2
2
|
import { NFTTransaction, Transaction } from "../models/Transaction";
|
3
3
|
import { pressBoth, pressUntilTextFound, containsSubstringInEvent, waitFor } from "../speculos";
|
4
4
|
import { DeviceLabels } from "../enum/DeviceLabels";
|
5
|
-
import { Device } from "../enum/Device";
|
6
5
|
|
7
6
|
export async function sendEVM(tx: Transaction) {
|
8
7
|
const events = await pressUntilTextFound(DeviceLabels.ACCEPT);
|
9
8
|
const isAmountCorrect = containsSubstringInEvent(tx.amount, events);
|
10
9
|
expect(isAmountCorrect).toBeTruthy();
|
11
|
-
if (tx.accountToCredit.ensName
|
10
|
+
if (tx.accountToCredit.ensName) {
|
12
11
|
const isENSNameCorrect = containsSubstringInEvent(tx.accountToCredit.ensName, events);
|
13
12
|
expect(isENSNameCorrect).toBeTruthy();
|
14
13
|
} else {
|
@@ -1,7 +1,6 @@
|
|
1
1
|
import expect from "expect";
|
2
2
|
import { pressBoth, pressUntilTextFound, waitFor, containsSubstringInEvent } from "../speculos";
|
3
3
|
import { DeviceLabels } from "../enum/DeviceLabels";
|
4
|
-
import { Device } from "../enum/Device";
|
5
4
|
import { Transaction } from "../models/Transaction";
|
6
5
|
|
7
6
|
export async function delegateSolana() {
|
@@ -14,10 +13,8 @@ export async function sendSolana(tx: Transaction) {
|
|
14
13
|
const events = await pressUntilTextFound(DeviceLabels.APPROVE);
|
15
14
|
const isAmountCorrect = containsSubstringInEvent(tx.amount, events);
|
16
15
|
expect(isAmountCorrect).toBeTruthy();
|
17
|
-
|
18
|
-
|
19
|
-
expect(isAddressCorrect).toBeTruthy();
|
20
|
-
}
|
16
|
+
const isAddressCorrect = containsSubstringInEvent(tx.accountToCredit.address, events);
|
17
|
+
expect(isAddressCorrect).toBeTruthy();
|
21
18
|
|
22
19
|
await pressBoth();
|
23
20
|
}
|
package/src/e2e/speculos.ts
CHANGED
@@ -16,7 +16,6 @@ import { getEnv } from "@ledgerhq/live-env";
|
|
16
16
|
import { getCryptoCurrencyById } from "../currencies";
|
17
17
|
import { DeviceLabels } from "../e2e/enum/DeviceLabels";
|
18
18
|
import { Account } from "./enum/Account";
|
19
|
-
import { Device as CryptoWallet } from "./enum/Device";
|
20
19
|
import { Currency } from "./enum/Currency";
|
21
20
|
import expect from "expect";
|
22
21
|
import { sendBTCBasedCoin } from "./families/bitcoin";
|
@@ -62,19 +61,6 @@ export function setExchangeDependencies(dependencies: Dependency[]) {
|
|
62
61
|
specs["Exchange"].dependencies = Array.from(map.values());
|
63
62
|
}
|
64
63
|
|
65
|
-
export function getSpeculosModel() {
|
66
|
-
const speculosDevice = process.env.SPECULOS_DEVICE;
|
67
|
-
switch (speculosDevice) {
|
68
|
-
case CryptoWallet.LNS:
|
69
|
-
return DeviceModelId.nanoS;
|
70
|
-
case CryptoWallet.LNX:
|
71
|
-
return DeviceModelId.nanoX;
|
72
|
-
case CryptoWallet.LNSP:
|
73
|
-
default:
|
74
|
-
return DeviceModelId.nanoSP;
|
75
|
-
}
|
76
|
-
}
|
77
|
-
|
78
64
|
type Specs = {
|
79
65
|
[key: string]: Spec;
|
80
66
|
};
|
@@ -89,7 +75,7 @@ export const specs: Specs = {
|
|
89
75
|
Bitcoin: {
|
90
76
|
currency: getCryptoCurrencyById("bitcoin"),
|
91
77
|
appQuery: {
|
92
|
-
model:
|
78
|
+
model: DeviceModelId.nanoSP,
|
93
79
|
appName: "Bitcoin",
|
94
80
|
},
|
95
81
|
dependency: "",
|
@@ -97,21 +83,21 @@ export const specs: Specs = {
|
|
97
83
|
Aptos: {
|
98
84
|
currency: getCryptoCurrencyById("aptos"),
|
99
85
|
appQuery: {
|
100
|
-
model:
|
86
|
+
model: DeviceModelId.nanoSP,
|
101
87
|
appName: "Aptos",
|
102
88
|
},
|
103
89
|
dependency: "",
|
104
90
|
},
|
105
91
|
Exchange: {
|
106
92
|
appQuery: {
|
107
|
-
model:
|
93
|
+
model: DeviceModelId.nanoSP,
|
108
94
|
appName: "Exchange",
|
109
95
|
},
|
110
96
|
dependencies: [],
|
111
97
|
},
|
112
98
|
LedgerSync: {
|
113
99
|
appQuery: {
|
114
|
-
model:
|
100
|
+
model: DeviceModelId.nanoX,
|
115
101
|
appName: "Ledger Sync",
|
116
102
|
},
|
117
103
|
dependency: "",
|
@@ -119,7 +105,7 @@ export const specs: Specs = {
|
|
119
105
|
Dogecoin: {
|
120
106
|
currency: getCryptoCurrencyById("dogecoin"),
|
121
107
|
appQuery: {
|
122
|
-
model:
|
108
|
+
model: DeviceModelId.nanoSP,
|
123
109
|
appName: "Dogecoin",
|
124
110
|
},
|
125
111
|
dependency: "",
|
@@ -127,7 +113,7 @@ export const specs: Specs = {
|
|
127
113
|
Ethereum: {
|
128
114
|
currency: getCryptoCurrencyById("ethereum"),
|
129
115
|
appQuery: {
|
130
|
-
model:
|
116
|
+
model: DeviceModelId.nanoSP,
|
131
117
|
appName: "Ethereum",
|
132
118
|
},
|
133
119
|
dependency: "",
|
@@ -135,7 +121,7 @@ export const specs: Specs = {
|
|
135
121
|
Ethereum_Holesky: {
|
136
122
|
currency: getCryptoCurrencyById("ethereum_holesky"),
|
137
123
|
appQuery: {
|
138
|
-
model:
|
124
|
+
model: DeviceModelId.nanoSP,
|
139
125
|
appName: "Ethereum",
|
140
126
|
},
|
141
127
|
dependency: "",
|
@@ -143,7 +129,7 @@ export const specs: Specs = {
|
|
143
129
|
Ethereum_Sepolia: {
|
144
130
|
currency: getCryptoCurrencyById("ethereum_sepolia"),
|
145
131
|
appQuery: {
|
146
|
-
model:
|
132
|
+
model: DeviceModelId.nanoSP,
|
147
133
|
appName: "Ethereum",
|
148
134
|
},
|
149
135
|
dependency: "",
|
@@ -151,7 +137,7 @@ export const specs: Specs = {
|
|
151
137
|
Ethereum_Classic: {
|
152
138
|
currency: getCryptoCurrencyById("ethereum_classic"),
|
153
139
|
appQuery: {
|
154
|
-
model:
|
140
|
+
model: DeviceModelId.nanoSP,
|
155
141
|
appName: "Ethereum Classic",
|
156
142
|
},
|
157
143
|
dependency: "Ethereum",
|
@@ -159,7 +145,7 @@ export const specs: Specs = {
|
|
159
145
|
Bitcoin_Testnet: {
|
160
146
|
currency: getCryptoCurrencyById("bitcoin_testnet"),
|
161
147
|
appQuery: {
|
162
|
-
model:
|
148
|
+
model: DeviceModelId.nanoSP,
|
163
149
|
appName: "Bitcoin Test",
|
164
150
|
},
|
165
151
|
dependency: "",
|
@@ -167,7 +153,7 @@ export const specs: Specs = {
|
|
167
153
|
Solana: {
|
168
154
|
currency: getCryptoCurrencyById("solana"),
|
169
155
|
appQuery: {
|
170
|
-
model:
|
156
|
+
model: DeviceModelId.nanoSP,
|
171
157
|
appName: "Solana",
|
172
158
|
},
|
173
159
|
dependency: "",
|
@@ -175,7 +161,7 @@ export const specs: Specs = {
|
|
175
161
|
Cardano: {
|
176
162
|
currency: getCryptoCurrencyById("cardano"),
|
177
163
|
appQuery: {
|
178
|
-
model:
|
164
|
+
model: DeviceModelId.nanoSP,
|
179
165
|
appName: "CardanoADA",
|
180
166
|
},
|
181
167
|
dependency: "",
|
@@ -183,7 +169,7 @@ export const specs: Specs = {
|
|
183
169
|
Polkadot: {
|
184
170
|
currency: getCryptoCurrencyById("polkadot"),
|
185
171
|
appQuery: {
|
186
|
-
model:
|
172
|
+
model: DeviceModelId.nanoSP,
|
187
173
|
appName: "Polkadot",
|
188
174
|
},
|
189
175
|
dependency: "",
|
@@ -191,7 +177,7 @@ export const specs: Specs = {
|
|
191
177
|
Tron: {
|
192
178
|
currency: getCryptoCurrencyById("tron"),
|
193
179
|
appQuery: {
|
194
|
-
model:
|
180
|
+
model: DeviceModelId.nanoSP,
|
195
181
|
appName: "Tron",
|
196
182
|
},
|
197
183
|
dependency: "",
|
@@ -199,7 +185,7 @@ export const specs: Specs = {
|
|
199
185
|
XRP: {
|
200
186
|
currency: getCryptoCurrencyById("ripple"),
|
201
187
|
appQuery: {
|
202
|
-
model:
|
188
|
+
model: DeviceModelId.nanoSP,
|
203
189
|
appName: "XRP",
|
204
190
|
},
|
205
191
|
dependency: "",
|
@@ -207,7 +193,7 @@ export const specs: Specs = {
|
|
207
193
|
Stellar: {
|
208
194
|
currency: getCryptoCurrencyById("stellar"),
|
209
195
|
appQuery: {
|
210
|
-
model:
|
196
|
+
model: DeviceModelId.nanoSP,
|
211
197
|
appName: "Stellar",
|
212
198
|
},
|
213
199
|
dependency: "",
|
@@ -215,7 +201,7 @@ export const specs: Specs = {
|
|
215
201
|
Bitcoin_Cash: {
|
216
202
|
currency: getCryptoCurrencyById("bitcoin_cash"),
|
217
203
|
appQuery: {
|
218
|
-
model:
|
204
|
+
model: DeviceModelId.nanoSP,
|
219
205
|
appName: "Bitcoin Cash",
|
220
206
|
},
|
221
207
|
dependency: "",
|
@@ -223,7 +209,7 @@ export const specs: Specs = {
|
|
223
209
|
Algorand: {
|
224
210
|
currency: getCryptoCurrencyById("algorand"),
|
225
211
|
appQuery: {
|
226
|
-
model:
|
212
|
+
model: DeviceModelId.nanoSP,
|
227
213
|
appName: "Algorand",
|
228
214
|
},
|
229
215
|
dependency: "",
|
@@ -231,7 +217,7 @@ export const specs: Specs = {
|
|
231
217
|
Cosmos: {
|
232
218
|
currency: getCryptoCurrencyById("cosmos"),
|
233
219
|
appQuery: {
|
234
|
-
model:
|
220
|
+
model: DeviceModelId.nanoSP,
|
235
221
|
appName: "Cosmos",
|
236
222
|
},
|
237
223
|
dependency: "",
|
@@ -239,7 +225,7 @@ export const specs: Specs = {
|
|
239
225
|
Tezos: {
|
240
226
|
currency: getCryptoCurrencyById("tezos"),
|
241
227
|
appQuery: {
|
242
|
-
model:
|
228
|
+
model: DeviceModelId.nanoSP,
|
243
229
|
appName: "TezosWallet",
|
244
230
|
},
|
245
231
|
dependency: "",
|
@@ -247,7 +233,7 @@ export const specs: Specs = {
|
|
247
233
|
Polygon: {
|
248
234
|
currency: getCryptoCurrencyById("polygon"),
|
249
235
|
appQuery: {
|
250
|
-
model:
|
236
|
+
model: DeviceModelId.nanoSP,
|
251
237
|
appName: "Ethereum",
|
252
238
|
},
|
253
239
|
dependency: "",
|
@@ -255,7 +241,7 @@ export const specs: Specs = {
|
|
255
241
|
Binance_Smart_Chain: {
|
256
242
|
currency: getCryptoCurrencyById("bsc"),
|
257
243
|
appQuery: {
|
258
|
-
model:
|
244
|
+
model: DeviceModelId.nanoSP,
|
259
245
|
appName: "Ethereum",
|
260
246
|
},
|
261
247
|
dependency: "",
|
@@ -263,7 +249,7 @@ export const specs: Specs = {
|
|
263
249
|
Ton: {
|
264
250
|
currency: getCryptoCurrencyById("ton"),
|
265
251
|
appQuery: {
|
266
|
-
model:
|
252
|
+
model: DeviceModelId.nanoSP,
|
267
253
|
appName: "TON",
|
268
254
|
},
|
269
255
|
dependency: "",
|
@@ -271,7 +257,7 @@ export const specs: Specs = {
|
|
271
257
|
Near: {
|
272
258
|
currency: getCryptoCurrencyById("near"),
|
273
259
|
appQuery: {
|
274
|
-
model:
|
260
|
+
model: DeviceModelId.nanoSP,
|
275
261
|
appName: "NEAR",
|
276
262
|
},
|
277
263
|
dependency: "",
|
@@ -279,7 +265,7 @@ export const specs: Specs = {
|
|
279
265
|
Multivers_X: {
|
280
266
|
currency: getCryptoCurrencyById("elrond"),
|
281
267
|
appQuery: {
|
282
|
-
model:
|
268
|
+
model: DeviceModelId.nanoSP,
|
283
269
|
appName: "MultiversX",
|
284
270
|
},
|
285
271
|
dependency: "",
|
@@ -287,7 +273,7 @@ export const specs: Specs = {
|
|
287
273
|
Osmosis: {
|
288
274
|
currency: getCryptoCurrencyById("osmo"),
|
289
275
|
appQuery: {
|
290
|
-
model:
|
276
|
+
model: DeviceModelId.nanoSP,
|
291
277
|
appName: "Cosmos",
|
292
278
|
},
|
293
279
|
dependency: "",
|
@@ -295,7 +281,7 @@ export const specs: Specs = {
|
|
295
281
|
Injective: {
|
296
282
|
currency: getCryptoCurrencyById("injective"),
|
297
283
|
appQuery: {
|
298
|
-
model:
|
284
|
+
model: DeviceModelId.nanoSP,
|
299
285
|
appName: "Cosmos",
|
300
286
|
},
|
301
287
|
dependency: "",
|
@@ -304,7 +290,7 @@ export const specs: Specs = {
|
|
304
290
|
Celo: {
|
305
291
|
currency: getCryptoCurrencyById("celo"),
|
306
292
|
appQuery: {
|
307
|
-
model:
|
293
|
+
model: DeviceModelId.nanoSP,
|
308
294
|
appName: "Celo",
|
309
295
|
},
|
310
296
|
dependency: "",
|
@@ -312,7 +298,7 @@ export const specs: Specs = {
|
|
312
298
|
Litecoin: {
|
313
299
|
currency: getCryptoCurrencyById("litecoin"),
|
314
300
|
appQuery: {
|
315
|
-
model:
|
301
|
+
model: DeviceModelId.nanoSP,
|
316
302
|
appName: "Litecoin",
|
317
303
|
},
|
318
304
|
dependency: "",
|
@@ -441,7 +427,7 @@ export async function pressUntilTextFound(
|
|
441
427
|
return await fetchAllEvents(speculosApiPort);
|
442
428
|
}
|
443
429
|
|
444
|
-
await pressRightButton();
|
430
|
+
await pressRightButton(speculosApiPort);
|
445
431
|
await waitForTimeOut(200);
|
446
432
|
}
|
447
433
|
|
@@ -464,8 +450,7 @@ async function fetchAllEvents(speculosApiPort: number): Promise<string[]> {
|
|
464
450
|
return response.data.events.map(event => event.text);
|
465
451
|
}
|
466
452
|
|
467
|
-
|
468
|
-
const speculosApiPort = getEnv("SPECULOS_API_PORT");
|
453
|
+
async function pressRightButton(speculosApiPort: number): Promise<void> {
|
469
454
|
await axios.post(`http://127.0.0.1:${speculosApiPort}/button/right`, {
|
470
455
|
action: "press-and-release",
|
471
456
|
});
|
package/lib/e2e/enum/Device.d.ts
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"Device.d.ts","sourceRoot":"","sources":["../../../src/e2e/enum/Device.ts"],"names":[],"mappings":"AAAA,qBAAa,MAAM;aACW,IAAI,EAAE,MAAM;gBAAZ,IAAI,EAAE,MAAM;IAExC,MAAM,CAAC,QAAQ,CAAC,GAAG,WAAW;IAC9B,MAAM,CAAC,QAAQ,CAAC,GAAG,WAAW;IAC9B,MAAM,CAAC,QAAQ,CAAC,IAAI,YAAY;CACjC"}
|
package/lib/e2e/enum/Device.js
DELETED
@@ -1,14 +0,0 @@
|
|
1
|
-
"use strict";
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
-
exports.Device = void 0;
|
4
|
-
class Device {
|
5
|
-
name;
|
6
|
-
constructor(name) {
|
7
|
-
this.name = name;
|
8
|
-
}
|
9
|
-
static LNS = "nanoS";
|
10
|
-
static LNX = "nanoX";
|
11
|
-
static LNSP = "nanoSP";
|
12
|
-
}
|
13
|
-
exports.Device = Device;
|
14
|
-
//# sourceMappingURL=Device.js.map
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"Device.js","sourceRoot":"","sources":["../../../src/e2e/enum/Device.ts"],"names":[],"mappings":";;;AAAA,MAAa,MAAM;IACW;IAA5B,YAA4B,IAAY;QAAZ,SAAI,GAAJ,IAAI,CAAQ;IAAG,CAAC;IAE5C,MAAM,CAAU,GAAG,GAAG,OAAO,CAAC;IAC9B,MAAM,CAAU,GAAG,GAAG,OAAO,CAAC;IAC9B,MAAM,CAAU,IAAI,GAAG,QAAQ,CAAC;;AALlC,wBAMC"}
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"logic.d.ts","sourceRoot":"","sources":["../../../src/families/hedera/logic.ts"],"names":[],"mappings":"AACA,cAAc,6BAA6B,CAAC"}
|
@@ -1,19 +0,0 @@
|
|
1
|
-
"use strict";
|
2
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
3
|
-
if (k2 === undefined) k2 = k;
|
4
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
5
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
6
|
-
desc = { enumerable: true, get: function() { return m[k]; } };
|
7
|
-
}
|
8
|
-
Object.defineProperty(o, k2, desc);
|
9
|
-
}) : (function(o, m, k, k2) {
|
10
|
-
if (k2 === undefined) k2 = k;
|
11
|
-
o[k2] = m[k];
|
12
|
-
}));
|
13
|
-
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
14
|
-
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
15
|
-
};
|
16
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
17
|
-
// Encapsulate for LLD & LLM
|
18
|
-
__exportStar(require("@ledgerhq/coin-hedera/logic"), exports);
|
19
|
-
//# sourceMappingURL=logic.js.map
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"logic.js","sourceRoot":"","sources":["../../../src/families/hedera/logic.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,4BAA4B;AAC5B,8DAA4C"}
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"Device.d.ts","sourceRoot":"","sources":["../../../src/e2e/enum/Device.ts"],"names":[],"mappings":"AAAA,qBAAa,MAAM;aACW,IAAI,EAAE,MAAM;gBAAZ,IAAI,EAAE,MAAM;IAExC,MAAM,CAAC,QAAQ,CAAC,GAAG,WAAW;IAC9B,MAAM,CAAC,QAAQ,CAAC,GAAG,WAAW;IAC9B,MAAM,CAAC,QAAQ,CAAC,IAAI,YAAY;CACjC"}
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"Device.js","sourceRoot":"","sources":["../../../src/e2e/enum/Device.ts"],"names":[],"mappings":"AAAA,MAAM,OAAO,MAAM;IACW;IAA5B,YAA4B,IAAY;QAAZ,SAAI,GAAJ,IAAI,CAAQ;IAAG,CAAC;IAE5C,MAAM,CAAU,GAAG,GAAG,OAAO,CAAC;IAC9B,MAAM,CAAU,GAAG,GAAG,OAAO,CAAC;IAC9B,MAAM,CAAU,IAAI,GAAG,QAAQ,CAAC"}
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"logic.d.ts","sourceRoot":"","sources":["../../../src/families/hedera/logic.ts"],"names":[],"mappings":"AACA,cAAc,6BAA6B,CAAC"}
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"logic.js","sourceRoot":"","sources":["../../../src/families/hedera/logic.ts"],"names":[],"mappings":"AAAA,4BAA4B;AAC5B,cAAc,6BAA6B,CAAC"}
|
package/src/e2e/enum/Device.ts
DELETED