Skip to content

Commit

Permalink
make sign tests great again (#1584)
Browse files Browse the repository at this point in the history
  • Loading branch information
ibrahimtaveras00 authored May 19, 2020
1 parent 496f85b commit fe04a9a
Show file tree
Hide file tree
Showing 2 changed files with 23 additions and 18 deletions.
32 changes: 16 additions & 16 deletions e2e/browser-tests.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -87,10 +87,10 @@ describe('Browser Tests', () => {
}
// Tap on SIGN button
if (device.getPlatform() === 'ios') {
await TestHelpers.tapByText('SIGN');
await TestHelpers.tapByText('Sign');
} else {
await TestHelpers.delay(1000);
await TestHelpers.tapByText('SIGN');
await TestHelpers.tapByText('Sign');
await TestHelpers.delay(1000);
}
// Tap on personal_sign button
Expand All @@ -102,10 +102,10 @@ describe('Browser Tests', () => {
}
// Tap on SIGN button
if (device.getPlatform() === 'ios') {
await TestHelpers.tapByText('SIGN');
await TestHelpers.tapByText('Sign');
} else {
await TestHelpers.delay(1000);
await TestHelpers.tapByText('SIGN');
await TestHelpers.tapByText('Sign');
await TestHelpers.delay(1000);
}
// Tap ok in alert box
Expand All @@ -123,10 +123,10 @@ describe('Browser Tests', () => {
}
// Tap on SIGN button
if (device.getPlatform() === 'ios') {
await TestHelpers.tapByText('SIGN');
await TestHelpers.tapByText('Sign');
} else {
await TestHelpers.delay(1000);
await TestHelpers.tapByText('SIGN');
await TestHelpers.tapByText('Sign');
await TestHelpers.delay(1000);
}
// Scroll to bottom of browser view
Expand All @@ -146,10 +146,10 @@ describe('Browser Tests', () => {
}
// Tap on SIGN button
if (device.getPlatform() === 'ios') {
await TestHelpers.tapByText('SIGN');
await TestHelpers.tapByText('Sign');
} else {
await TestHelpers.delay(1000);
await TestHelpers.tapByText('SIGN');
await TestHelpers.tapByText('Sign');
await TestHelpers.delay(1000);
}
// Tap on sign typed data button
Expand All @@ -161,10 +161,10 @@ describe('Browser Tests', () => {
}
// Tap on SIGN button
if (device.getPlatform() === 'ios') {
await TestHelpers.tapByText('SIGN');
await TestHelpers.tapByText('Sign');
} else {
await TestHelpers.delay(1000);
await TestHelpers.tapByText('SIGN');
await TestHelpers.tapByText('Sign');
await TestHelpers.delay(1000);
}
// Tap ok in alert box
Expand All @@ -182,10 +182,10 @@ describe('Browser Tests', () => {
}
// Tap on SIGN button
if (device.getPlatform() === 'ios') {
await TestHelpers.tapByText('SIGN');
await TestHelpers.tapByText('Sign');
} else {
await TestHelpers.delay(1000);
await TestHelpers.tapByText('SIGN');
await TestHelpers.tapByText('Sign');
await TestHelpers.delay(1000);
}
// Tap ok in alert box
Expand All @@ -203,10 +203,10 @@ describe('Browser Tests', () => {
}
// Tap on SIGN button
if (device.getPlatform() === 'ios') {
await TestHelpers.tapByText('SIGN');
await TestHelpers.tapByText('Sign');
} else {
await TestHelpers.delay(1000);
await TestHelpers.tapByText('SIGN');
await TestHelpers.tapByText('Sign');
await TestHelpers.delay(1000);
}
// Tap ok in alert box
Expand All @@ -224,10 +224,10 @@ describe('Browser Tests', () => {
}
// Tap on SIGN button
if (device.getPlatform() === 'ios') {
await TestHelpers.tapByText('SIGN');
await TestHelpers.tapByText('Sign');
} else {
await TestHelpers.delay(1000);
await TestHelpers.tapByText('SIGN');
await TestHelpers.tapByText('Sign');
await TestHelpers.delay(1000);
}
});
Expand Down
9 changes: 7 additions & 2 deletions e2e/dapp-initiated-txn.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -240,8 +240,13 @@ describe('Test Dapp Initiated Transactions', () => {
await TestHelpers.tap('hamburger-menu-button-browser');
// Check that the drawer is visbile
await TestHelpers.checkIfVisible('drawer-screen');
// Tap on Log Out
await TestHelpers.tapByText('Log Out');
if (device.getPlatform() === 'android') {
await TestHelpers.swipe('drawer-screen', 'up');
await TestHelpers.tapByText('Log Out');
} else {
// Tap on Log Out
await TestHelpers.tapByText('Log Out');
}
// Tap YES
await TestHelpers.tapAlertWithButton('YES');
// Check that we are on the login screen
Expand Down

0 comments on commit fe04a9a

Please sign in to comment.