Skip to content
Permalink
Browse files

chore: ugprade jest (#158)

* chore: ugprade jest

* chore: enable outputing sourcemaps
  • Loading branch information...
dariocravero authored and amymc committed Mar 10, 2019
1 parent 9d7971d commit a9c4feeb861b62c53926d40269a4fa9ed4c4bee0
Showing with 2,582 additions and 2,759 deletions.
  1. +9 −1 .babelrc
  2. +48 −72 __tests__/__snapshots__/react.js.snap
  3. +1 −1 index.js
  4. +13 −18 package.json
  5. +2 −19 rollup.config.js
  6. +2 −19 rollup.config.parse.js
  7. +2,507 −2,629 yarn.lock
@@ -1,7 +1,15 @@
{
"env": {
"test": {
"plugins": ["transform-es2015-modules-commonjs", "transform-object-rest-spread"]
"presets": [
[
"@babel/preset-env",
{
"useBuiltIns": false,
"exclude": ["@babel/plugin-transform-regenerator"]
}
]
]
}
}
}
@@ -1471,10 +1471,7 @@ class Code extends React.Component {
);
}
}
Code.defaultProps = {
text: 'hey',
color: 'white',
};
Code.defaultProps = { text: 'hey', color: 'white' };
export default Code;
",
"dependencies": Set {
@@ -1527,10 +1524,7 @@ const DefaultProps = props => {
</div>
);
};
DefaultProps.defaultProps = {
text: 'hey',
texto: 'ho',
};
DefaultProps.defaultProps = { text: 'hey', texto: 'ho' };
export default DefaultProps;
",
"dependencies": Set {},
@@ -1693,10 +1687,7 @@ const DynamicFontProps = props => {
</div>
);
};
DynamicFontProps.defaultProps = {
fontFamily: 'Montserrat',
fontWeight: 200,
};
DynamicFontProps.defaultProps = { fontFamily: 'Montserrat', fontWeight: 200 };
export default DynamicFontProps;
",
"dependencies": Set {
@@ -2860,31 +2851,31 @@ const Scope = props => {
props.somethingGreen
? 'somethingGreen|'
: props.whatMakesBlue
? 'whatMakesBlue|'
: !props.whatMakesBlue
? 'notWhatMakesBlue|'
: ''
? 'whatMakesBlue|'
: !props.whatMakesBlue
? 'notWhatMakesBlue|'
: ''
}\`}
style={{
'--color': \`\${
props.somethingGreen
? 'rgb(0,255,0)'
: props.whatMakesBlue
? 'rgb(0,0,255)'
: !props.whatMakesBlue
? 'rgb(255,255,0)'
: 'red'
? 'rgb(0,0,255)'
: !props.whatMakesBlue
? 'rgb(255,255,0)'
: 'red'
}\`,
}}
className={\`views-text \${Scope1}\`}
>
{props.somethingGreen
? '2 green'
: props.whatMakesBlue
? props.blue
: !props.whatMakesBlue
? 'is Yellow'
: '1 red'}
? props.blue
: !props.whatMakesBlue
? 'is Yellow'
: '1 red'}
</span>
);
};
@@ -2961,15 +2952,15 @@ const ScopePopup = props => {
props.somethingGreen
? 'somethingGreen|'
: props.whatMakesBlue
? 'whatMakesBlue|'
: ''
? 'whatMakesBlue|'
: ''
}\`}
onClick={
props.somethingGreen
? props.onClickGreen
: props.whatMakesBlue
? props.onClickBlue
: props.toggle
? props.onClickBlue
: props.toggle
}
className=\\"views-block\\"
>
@@ -3037,8 +3028,8 @@ const ScopePopup2 = props => {
props.isShown
? 'isShown|'
: props.isSuperVisible
? 'isSuperVisible|'
: ''
? 'isSuperVisible|'
: ''
}\`}
style={{
'--opacity': \`\${props.isShown ? 1 : props.isSuperVisible ? 3 : 0}\`,
@@ -3481,10 +3472,7 @@ const TextInterpolation = props => {
</div>
);
};
TextInterpolation.defaultProps = {
firstName: '',
surname: '',
};
TextInterpolation.defaultProps = { firstName: '', surname: '' };
export default TextInterpolation;
",
"dependencies": Set {},
@@ -5233,10 +5221,7 @@ class Code extends React.Component {
);
}
}
Code.defaultProps = {
text: 'hey',
color: 'white',
};
Code.defaultProps = { text: 'hey', color: 'white' };
export default Code;
",
"dependencies": Set {},
@@ -5280,10 +5265,7 @@ const DefaultProps = props => {
</View>
);
};
DefaultProps.defaultProps = {
text: 'hey',
texto: 'ho',
};
DefaultProps.defaultProps = { text: 'hey', texto: 'ho' };
export default DefaultProps;
",
"dependencies": Set {},
@@ -5348,10 +5330,10 @@ const DynamicCaptureType = props => {
props.type === 'email'
? 'email-address'
: props.type === 'number'
? 'numeric'
: props.type === 'phone'
? 'phone-pad'
: 'default'
? 'numeric'
: props.type === 'phone'
? 'phone-pad'
: 'default'
}
autoCorrect={false}
underlineColorAndroid=\\"transparent\\"
@@ -5425,10 +5407,7 @@ const DynamicFontProps = props => {
</View>
);
};
DynamicFontProps.defaultProps = {
fontFamily: 'Montserrat',
fontWeight: 200,
};
DynamicFontProps.defaultProps = { fontFamily: 'Montserrat', fontWeight: 200 };
export default DynamicFontProps;
",
"dependencies": Set {},
@@ -6415,31 +6394,31 @@ const Scope = props => {
props.somethingGreen
? 'somethingGreen|'
: props.whatMakesBlue
? 'whatMakesBlue|'
: !props.whatMakesBlue
? 'notWhatMakesBlue|'
: ''
? 'whatMakesBlue|'
: !props.whatMakesBlue
? 'notWhatMakesBlue|'
: ''
}\`}
style={[
null,
{
color: props.somethingGreen
? 'rgb(0,255,0)'
: props.whatMakesBlue
? 'rgb(0,0,255)'
: !props.whatMakesBlue
? 'rgb(255,255,0)'
: 'red',
? 'rgb(0,0,255)'
: !props.whatMakesBlue
? 'rgb(255,255,0)'
: 'red',
},
]}
>
{props.somethingGreen
? '2 green'
: props.whatMakesBlue
? props.blue
: !props.whatMakesBlue
? 'is Yellow'
: '1 red'}
? props.blue
: !props.whatMakesBlue
? 'is Yellow'
: '1 red'}
</Text>
);
};
@@ -6510,8 +6489,8 @@ const ScopePopup = props => {
props.somethingGreen
? props.onClickGreen
: props.whatMakesBlue
? props.onClickBlue
: props.toggle
? props.onClickBlue
: props.toggle
}
underlayColor=\\"transparent\\"
>
@@ -6520,8 +6499,8 @@ const ScopePopup = props => {
props.somethingGreen
? 'somethingGreen|'
: props.whatMakesBlue
? 'whatMakesBlue|'
: ''
? 'whatMakesBlue|'
: ''
}\`}
>
<Text testID={\`ScopePopup.Text|\`}>toggle popup</Text>
@@ -6577,8 +6556,8 @@ const ScopePopup2 = props => {
props.isShown
? 'isShown|'
: props.isSuperVisible
? 'isSuperVisible|'
: ''
? 'isSuperVisible|'
: ''
}\`}
style={[
null,
@@ -7009,10 +6988,7 @@ const TextInterpolation = props => {
</View>
);
};
TextInterpolation.defaultProps = {
firstName: '',
surname: '',
};
TextInterpolation.defaultProps = { firstName: '', surname: '' };
export default TextInterpolation;
",
"dependencies": Set {},
@@ -48,7 +48,7 @@ export const morph = ({

if (pretty) {
morphed.code = prettier.format(morphed.code, {
parser: 'babylon',
parser: 'babel',
singleQuote: true,
trailingComma: 'es5',
})
@@ -15,32 +15,27 @@
},
"repository": {
"type": "git",
"url": "git+https://github.com/viewsdx/morph.git"
"url": "git+https://github.com/viewstools/morph.git"
},
"author": "Darío Javier Cravero <dario@uxtemple.com>",
"license": "BSD-3-Clause",
"bugs": {
"url": "https://github.com/viewsdx/morph/issues"
"url": "https://github.com/viewstools/morph/issues"
},
"homepage": "https://github.com/viewsdx/morph#readme",
"homepage": "https://github.com/viewstools/morph#readme",
"devDependencies": {
"animated": "^0.2.2",
"babel-eslint": "^8.0.3",
"babel-jest": "^23.0.1",
"babel-plugin-external-helpers": "^6.22.0",
"babel-plugin-transform-es2015-modules-commonjs": "^6.24.1",
"babel-plugin-transform-object-rest-spread": "^6.23.0",
"babel-preset-env": "^1.6.0",
"@babel/core": "^7.3.4",
"@babel/preset-env": "^7.3.4",
"babel-eslint": "^10.0.1",
"babel-jest": "^24.3.1",
"cross-env": "^5.2.0",
"eslint": "^4.13.1",
"eslint": "^5.15.1",
"eslint-plugin-import": "^2.3.0",
"husky": "^0.14.3",
"import-export": "^1.0.1",
"jest": "^23.1.0",
"lint-staged": "^7.2.0",
"rollup": "^0.63.0",
"rollup-plugin-babel": "^3.0.3",
"rollup-watch": "^4.3.1"
"husky": "^1.3.1",
"jest": "^24.3.1",
"lint-staged": "^8.1.5",
"rollup": "^1.6.0",
"rollup-plugin-babel": "^4.3.2"
},
"dependencies": {
"array-uniq": "^2.0.0",
@@ -11,25 +11,8 @@ export default {
},
plugins: [
babel({
plugins: ['external-helpers', 'transform-object-rest-spread'],
presets: [
[
'env',
{
targets: {
// React parses on ie 9, so we should too
ie: 11,
// We currently minify with uglify
// Remove after https://github.com/mishoo/UglifyJS2/issues/448
uglify: true,
},
// Disable polyfill transforms
useBuiltIns: false,
// Do not transform modules to CJS
modules: false,
},
],
],
babelrc: false,
presets: [['@babel/preset-env', { modules: false, useBuiltIns: false }]],
}),
],
}
@@ -11,25 +11,8 @@ export default {
},
plugins: [
babel({
plugins: ['external-helpers', 'transform-object-rest-spread'],
presets: [
[
'env',
{
targets: {
// React parses on ie 9, so we should too
ie: 11,
// We currently minify with uglify
// Remove after https://github.com/mishoo/UglifyJS2/issues/448
uglify: true,
},
// Disable polyfill transforms
useBuiltIns: false,
// Do not transform modules to CJS
modules: false,
},
],
],
babelrc: false,
presets: [['@babel/preset-env', { modules: false, useBuiltIns: false }]],
}),
],
}

0 comments on commit a9c4fee

Please sign in to comment.
You can’t perform that action at this time.