export const isDebuggerConnected = (): boolean =>
  typeof window === 'object' && !!window.__REDUX_DEVTOOLS_EXTENSION__;

export const isTest = (): boolean => typeof __TEST__ !== 'undefined';

export const noop = () => null;

export const testIdProps = (testId: string) => ({ accessibilityLabel: testId, testID: testId });

export const flushPromises = (): Promise<any> => new Promise((resolve) => setImmediate(resolve));
