react-native-navigation的迁移库

app.test.js 636B

123456789101112131415161718192021222324
  1. describe('app', () => {
  2. beforeEach((done) => {
  3. global.simulator.relaunchApp(done);
  4. });
  5. it('shows welcome screen', () => {
  6. expect(elementByLabel('React Native Navigation!')).toBeVisible();
  7. });
  8. it('switch to tab based app', () => {
  9. elementByLabel('Switch to tab based app').tap();
  10. expect(elementByLabel('This is tab 1')).toBeVisible();
  11. });
  12. xit('switch to tabs with side menus', () => {
  13. elementByLabel('Switch to tab based app with side menus').tap();
  14. // expect(elementByLabel('This is a tab screen')).toBeVisible();
  15. });
  16. });
  17. function elementByLabel(label) {
  18. return element(by.label(label));
  19. }