Updated approve test

Removed hacky workaround
This commit is contained in:
Alexandre Paillier
2022-02-08 17:27:03 +01:00
parent 74fcac61aa
commit 1417120b4f
5 changed files with 5 additions and 8 deletions

View File

@@ -0,0 +1 @@
00007.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 349 B

View File

@@ -0,0 +1 @@
00005.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 382 B

View File

@@ -11,15 +11,10 @@ nano_models.forEach(function(model) {
);
let clicks;
if (model.letter === 'S') clicks = [8];
else clicks = [6];
if (model.letter === 'S') clicks = 8;
else clicks = 6;
await waitForAppScreen(sim);
// Go to the reject screen
await sim.navigateAndCompareSnapshots('.', model.name + '_approve_dai_tokens', clicks);
// Accepting the transaction somehow takes too long for Zemu and takes the same screenshot
// twice, so accept it manually
await sim.clickLeft();
await sim.clickBoth();
await sim.navigateAndCompareSnapshots('.', model.name + '_approve_dai_tokens', [clicks, -1, 0]);
await expect(tx).resolves.toEqual({
"r": "92243511396b65a4faa735a5472ea99b3ce0f7f2338eab426206730bc0ddc57f",