diff --git a/.eslintrc b/.eslintrc index 0c700ae4e..b79a23330 100644 --- a/.eslintrc +++ b/.eslintrc @@ -36,6 +36,7 @@ "react/forbid-prop-types": 0, "jsx-quotes": [2, "prefer-single"], "jsx-a11y/href-no-hash": 0, + "import/prefer-default-export": 0, "no-underscore-dangle": 0, "no-return-assign": 0, "no-param-reassign": 0, diff --git a/.travis.yml b/.travis.yml index 209445510..f4918c216 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,3 +1,8 @@ +branches: + only: + - develop + - "/^\\d+\\.\\d+\\.\\d+(-rc\\.\\d+)?$/" + matrix: include: - os: linux diff --git a/__mocks__/react-native-img-cache.js b/__mocks__/react-native-img-cache.js index d9f1f0a72..7b5b48f99 100644 --- a/__mocks__/react-native-img-cache.js +++ b/__mocks__/react-native-img-cache.js @@ -1,3 +1 @@ -module.exports = { - CachedImage: 'CachedImage' -}; +export const CachedImage = 'CachedImage'; diff --git a/__mocks__/react-native-navigation.js b/__mocks__/react-native-navigation.js index 44bb307d2..1ea9fa342 100644 --- a/__mocks__/react-native-navigation.js +++ b/__mocks__/react-native-navigation.js @@ -1,6 +1,4 @@ -module.exports = { - Navigation: { - registerComponent: () => {}, - startSingleScreenApp: () => {} - } +export const Navigation = { + registerComponent: () => {}, + startSingleScreenApp: () => {} }; diff --git a/package-lock.json b/package-lock.json index 2efb58fb5..88bf0e5e0 100644 --- a/package-lock.json +++ b/package-lock.json @@ -383,6 +383,12 @@ "sprintf-js": "1.0.3" } }, + "argv": { + "version": "0.0.2", + "resolved": "https://registry.npmjs.org/argv/-/argv-0.0.2.tgz", + "integrity": "sha1-7L0W+JSbFXGDcRsb2jNPN4QBhas=", + "dev": true + }, "aria-query": { "version": "0.7.0", "resolved": "https://registry.npmjs.org/aria-query/-/aria-query-0.7.0.tgz", @@ -2248,6 +2254,17 @@ "resolved": "https://registry.npmjs.org/code-point-at/-/code-point-at-1.1.0.tgz", "integrity": "sha1-DQcLTQQ6W+ozovGkDi7bPZpMz3c=" }, + "codecov": { + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/codecov/-/codecov-2.3.0.tgz", + "integrity": "sha1-rSWixuBELRN0DZ1N27mj4nFDMPQ=", + "dev": true, + "requires": { + "argv": "0.0.2", + "request": "2.81.0", + "urlgrey": "0.4.4" + } + }, "color": { "version": "0.11.4", "resolved": "https://registry.npmjs.org/color/-/color-0.11.4.tgz", @@ -11355,6 +11372,12 @@ "requires-port": "1.0.0" } }, + "urlgrey": { + "version": "0.4.4", + "resolved": "https://registry.npmjs.org/urlgrey/-/urlgrey-0.4.4.tgz", + "integrity": "sha1-iS/pWWCAXoVRnxzUOJ8stMu3ZS8=", + "dev": true + }, "util": { "version": "0.10.3", "resolved": "https://registry.npmjs.org/util/-/util-0.10.3.tgz", diff --git a/package.json b/package.json index bce7acf76..92c704da4 100644 --- a/package.json +++ b/package.json @@ -5,6 +5,7 @@ "scripts": { "start": "node node_modules/react-native/local-cli/cli.js start", "test": "jest", + "updateSnapshot": "jest --updateSnapshot", "lint": "eslint .", "ci": "eslint . && jest && codecov", "ios": "react-native run-ios", @@ -53,6 +54,7 @@ "babel-eslint": "^7.2.3", "babel-jest": "20.0.3", "babel-preset-react-native": "2.1.0", + "codecov": "^2.3.0", "eslint": "^4.4.0", "eslint-config-airbnb": "^15.1.0", "eslint-plugin-import": "^2.7.0",