Browse Source

ios - added relaunch app

Ran Greenberg 8 years ago
parent
commit
090ffcc8c4
2 changed files with 11 additions and 0 deletions
  1. 1
    0
      ios/RNN.m
  2. 10
    0
      playground/e2e/app.test.js

+ 1
- 0
ios/RNN.m View File

76
 
76
 
77
 -(void)onJavaScriptDevReload
77
 -(void)onJavaScriptDevReload
78
 {
78
 {
79
+	self.store = [RNNStore new];
79
 	UIApplication.sharedApplication.delegate.window.rootViewController = nil;
80
 	UIApplication.sharedApplication.delegate.window.rootViewController = nil;
80
 }
81
 }
81
 
82
 

+ 10
- 0
playground/e2e/app.test.js View File

38
     elementByLabel('Pop').tap();
38
     elementByLabel('Pop').tap();
39
     expect(elementByLabel('React Native Navigation!')).toBeVisible();
39
     expect(elementByLabel('React Native Navigation!')).toBeVisible();
40
   });
40
   });
41
+  
42
+});
43
+
44
+describe('reload app', () => {
45
+  before(function (done) {
46
+    simulator.reloadReactNativeApp(done);
47
+  });
48
+  it('shows welcome screen', () => {
49
+    expect(elementByLabel('React Native Navigation!')).toBeVisible();
50
+  });
41
 });
51
 });
42
 
52
 
43
 function elementByLabel(label) {
53
 function elementByLabel(label) {