Daniel Zlotin 7 anos atrás
pai
commit
d13f42bbf9
3 arquivos alterados com 6 adições e 11 exclusões
  1. 1
    2
      package.json
  2. 5
    8
      playground/src/containers/ModalScreen.js
  3. 0
    1
      scripts/travis.sh

+ 1
- 2
package.json Ver arquivo

@@ -26,8 +26,7 @@
26 26
   "main": "src/index.js",
27 27
   "scripts": {
28 28
     "build": ":",
29
-    "lint": "eslint src integration scripts playground/src playground/e2e playground/scripts",
30
-    "test-js": "BABEL_ENV=test jest --coverage",
29
+    "test-js": "eslint src integration scripts playground/src playground/e2e playground/scripts && BABEL_ENV=test jest --coverage",
31 30
     "test-android": "node ./scripts/test.android.js",
32 31
     "test-ios": "node ./scripts/test.ios.js",
33 32
     "test": "npm run lint && npm run test-js && npm run test-android && npm run test-ios",

+ 5
- 8
playground/src/containers/ModalScreen.js Ver arquivo

@@ -31,7 +31,7 @@ class ModalScreen extends Component {
31 31
         {this.props.previousModalIds ? (<Button title="Dismiss ALL Previous Modals" onPress={this.onClickDismissAllPreviousModals} />) : undefined}
32 32
         {this.props.previousModalIds ? (<Button title="Dismiss First In Stack" onPress={this.onClickDismissFirstInStack} />) : undefined}
33 33
         <Text style={styles.footer}>{`this.props.id = ${this.props.id}`}</Text>
34
-        
34
+
35 35
       </View>
36 36
     );
37 37
   }
@@ -53,26 +53,23 @@ class ModalScreen extends Component {
53 53
   onClickDismissPreviousModal() {
54 54
     Navigation.dismissModal(this.getPreviousModalId());
55 55
   }
56
-  
56
+
57 57
   onClickDismissUnknownModal() {
58 58
     Navigation.dismissModal('unknown');
59 59
   }
60
-  
60
+
61 61
   onClickDismissAllPreviousModals() {
62 62
     _.forEach(this.props.previousModalIds, (id) => Navigation.dismissModal(id));
63 63
   }
64
-  
65
-  
64
+
66 65
   onClickDismissFirstInStack() {
67
-    console.log('RANG', 'getFirstInStackModalId', _.head(this.props.previousModalIds));;
68 66
     Navigation.dismissModal(_.head(this.props.previousModalIds));
69 67
   }
70 68
 
71
-  
72 69
   getModalPosition() {
73 70
     return (this.props.modalPosition || 1);
74 71
   }
75
-  
72
+
76 73
   getPreviousModalId() {
77 74
     return _.last(this.props.previousModalIds);
78 75
   }

+ 0
- 1
scripts/travis.sh Ver arquivo

@@ -20,7 +20,6 @@ run_f () {
20 20
 }
21 21
 
22 22
 run_f "yarn install"
23
-run_f "yarn run lint"
24 23
 run_f "yarn run test-js"
25 24
 run_f "yarn run test-android"
26 25
 run_f "yarn run test-ios"