react-native-navigation的迁移库

SetRoot.test.js 536B

1234567891011121314151617
  1. const Utils = require('./Utils');
  2. const TestIDs = require('../playground/src/testIDs');
  3. const { elementById } = Utils;
  4. describe('SetRoot', () => {
  5. beforeEach(async () => {
  6. await device.relaunchApp();
  7. await elementById(TestIDs.NAVIGATION_TAB).tap();
  8. await elementById(TestIDs.SET_ROOT_BTN).tap();
  9. });
  10. it('set root multiple times with the same componentId', async () => {
  11. await elementById(TestIDs.SET_MULTIPLE_ROOTS_BTN).tap();
  12. await expect(elementById(TestIDs.PUSHED_SCREEN_HEADER)).toBeVisible();
  13. });
  14. });