Skip to content

Commit

Permalink
fix linting errors
Browse files Browse the repository at this point in the history
  • Loading branch information
cortisiko committed Jan 17, 2025
1 parent a5abe22 commit 0617ce1
Show file tree
Hide file tree
Showing 7 changed files with 18 additions and 18 deletions.
2 changes: 1 addition & 1 deletion app/components/UI/Ramp/components/PaymentMethodIcon.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ function getIconComponent(icon: PaymentIcon) {
}

/*
* With the integration of Expo, it introduced a compatibility layer (https://github.com/expo/vector-icons)
* With the integration of Expo, it introduced a compatibility layer (https://github.com/expo/vector-icons)
* around react-native-vector-icons which doesn't expose hasIcon anymore so we need to build our own based on
* the implementation https://github.com/oblador/react-native-vector-icons/blob/master/lib/create-icon-set.js#L158
*/
Expand Down
20 changes: 10 additions & 10 deletions app/core/NotificationsManager.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,7 @@ describe('NotificationManager', () => {
expect(message).toBe(strings('notifications.default_message_description'));
});
});

describe('smartTransactionListener', () => {
const mockTransactionController = {
getTransactions: jest.fn(),
Expand Down Expand Up @@ -172,7 +172,7 @@ describe('NotificationManager', () => {
beforeEach(() => {
// Clear all mock interactions before each test
jest.clearAllMocks();

// Reset the notification manager before each test
notificationManager = NotificationManager.init({
navigation: mockNavigation,
Expand All @@ -197,14 +197,14 @@ describe('NotificationManager', () => {
transactionId: '0x123',
};

notificationManager.watchSubmittedTransaction({
notificationManager.watchSubmittedTransaction({
id: '0x123',
txParams: {
nonce: '0x1'
},
silent: false
});

// Get the subscriber callback
const subscriberCallback = mockControllerMessenger.subscribe.mock.calls[0][1];
await subscriberCallback(transaction);
Expand All @@ -217,7 +217,7 @@ describe('NotificationManager', () => {
});

it('shows a cancelled notification for cancelled smart transactions', async () => {
const mockTransaction = {
const mockTransaction = {
id: '0x123',
txParams: {
nonce: '0x1'
Expand All @@ -230,14 +230,14 @@ describe('NotificationManager', () => {
transactionId: '0x123',
};

notificationManager.watchSubmittedTransaction({
notificationManager.watchSubmittedTransaction({
id: '0x123',
txParams: {
nonce: '0x1'
},
silent: false
});

// Get the subscriber callback
const subscriberCallback = mockControllerMessenger.subscribe.mock.calls[0][1];
await subscriberCallback(smartTransaction);
Expand All @@ -256,14 +256,14 @@ describe('NotificationManager', () => {
transactionId: '0x123',
};

notificationManager.watchSubmittedTransaction({
notificationManager.watchSubmittedTransaction({
id: '0x123',
txParams: {
nonce: '0x1'
},
silent: false
});

// Get the subscriber callback
const subscriberCallback = mockControllerMessenger.subscribe.mock.calls[0][1];
await subscriberCallback(transaction);
Expand All @@ -275,7 +275,7 @@ describe('NotificationManager', () => {
});

it('sets up transaction event listeners correctly', () => {
const transaction = {
const transaction = {
id: '0x123',
txParams: {
nonce: '0x1'
Expand Down
2 changes: 1 addition & 1 deletion app/core/SDKConnect/utils/isUUID.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@ export const isUUID = (str: string) => {
const uuidRegex =
/^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i;
return uuidRegex.test(str);
};
};
4 changes: 2 additions & 2 deletions app/util/notifications/services/NotificationService.ts
Original file line number Diff line number Diff line change
Expand Up @@ -224,9 +224,9 @@ class NotificationsService {
getInitialNotification = async (
callback: HandleNotificationCallback
): Promise<void> => {
const event = await notifee.getInitialNotification()
const event = await notifee.getInitialNotification();
if (event) {
callback(event.notification.data as Notification['data'])
callback(event.notification.data as Notification['data']);
}
};

Expand Down
1 change: 1 addition & 0 deletions e2e/specs/accounts/error-boundary-srp-backup.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ import { SmokeAccounts } from '../../tags';
import Assertions from '../../utils/Assertions';
import RevealSecretRecoveryPhrase from '../../pages/Settings/SecurityAndPrivacy/RevealSecretRecoveryPhrase';
import ErrorBoundaryView from '../../pages/ErrorBoundaryView/ErrorBoundaryView';
import Utilities from '../../utils/Utilities';
const PASSWORD = '123123123';

describe(SmokeAccounts('Error Boundary Screen'), () => {
Expand Down
2 changes: 1 addition & 1 deletion e2e/specs/networks/add-popular-networks.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import { withFixtures } from '../../fixtures/fixture-helper';
import WalletView from '../../pages/wallet/WalletView';
import NetworkListModal from '../../pages/Network/NetworkListModal';
import Assertions from '../../utils/Assertions';

import Utilities from '../../utils/Utilities';
describe(Regression('Add all popular networks'), () => {
beforeAll(async () => {
jest.setTimeout(170000);
Expand Down
5 changes: 2 additions & 3 deletions e2e/utils/Utilities.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,7 @@ import {
getGanachePort,
getLocalTestDappPort,
getMockServerPort,
} from './fixtures/utils';
import Utilities from './utils/Utilities';
} from '../fixtures/utils';
import { resolveConfig } from 'detox/internals';
export default class Utilities {
static async openDeepLink(inputURL) {
Expand All @@ -16,7 +15,7 @@ export default class Utilities {
sourceApp: 'io.metamask',
launchArgs: {
fixtureServerPort: `${getFixturesServerPort()}`,
detoxURLBlacklistRegex: Utilities.BlacklistURLs,
detoxURLBlacklistRegex: this.BlacklistURLs,
},
});
}
Expand Down

0 comments on commit 0617ce1

Please sign in to comment.