diff --git a/config/templates/tests/patterns/config.test.js b/config/templates/tests/patterns/config.test.js.template similarity index 100% rename from config/templates/tests/patterns/config.test.js rename to config/templates/tests/patterns/config.test.js.template diff --git a/packages/components/src/DraftConfigurator/OptionPreamble/index.js b/packages/components/src/DraftConfigurator/OptionPreamble/index.js index a2ec4f2c3dc..b058a475b80 100644 --- a/packages/components/src/DraftConfigurator/OptionPreamble/index.js +++ b/packages/components/src/DraftConfigurator/OptionPreamble/index.js @@ -34,10 +34,6 @@ const OptionPreamble = props => { id: 'app.restorePatternDefaults', defaultMessage: ' ♻️ ' }) - const docsLabel = props.intl.formatMessage({ - id: 'app.docs', - defaultMessage: ' 🤔 ' - }) let pattern = false if (props.dflt !== props.designDflt) pattern = true @@ -109,7 +105,6 @@ OptionPreamble.propTypes = { title: PropTypes.node.isRequired, desc: PropTypes.node.isRequired, reset: PropTypes.func.isRequired, - showHelp: PropTypes.func.isRequired, expanded: PropTypes.bool, displayFormat: PropTypes.string } diff --git a/packages/sven/config/index.js b/packages/sven/config/index.js index d9a30b857fe..e2af7ef3eeb 100644 --- a/packages/sven/config/index.js +++ b/packages/sven/config/index.js @@ -116,9 +116,9 @@ export default { sleevecapTopFactorX: { pct: 50, min: 25, max: 75 }, sleevecapTopFactorY: { pct: 100, min: 35, max: 165 }, sleevecapBackFactorX: { pct: 60, min: 35, max: 65 }, - sleevecapBackFactorY: { pct: 33, min: 35, max: 65 }, + sleevecapBackFactorY: { pct: 33, min: 30, max: 65 }, sleevecapFrontFactorX: { pct: 55, min: 35, max: 65 }, - sleevecapFrontFactorY: { pct: 33, min: 35, max: 65 }, + sleevecapFrontFactorY: { pct: 33, min: 30, max: 65 }, sleevecapQ1Offset: { pct: 3, min: 0, max: 7 }, sleevecapQ2Offset: { pct: 5.5, min: 0, max: 7 }, sleevecapQ3Offset: { pct: 4.5, min: 0, max: 7 }, diff --git a/scripts/reconfigure.js b/scripts/reconfigure.js index 593d85cbc24..1b9cd2359af 100644 --- a/scripts/reconfigure.js +++ b/scripts/reconfigure.js @@ -486,7 +486,7 @@ function configurePatternUnitTests(pkg, config) { fs.writeFileSync( path.join(dest, file), Mustache.render( - fs.readFileSync(path.join(source, file), "utf-8"), + fs.readFileSync(path.join(source, file+'.template'), "utf-8"), replace ) ); diff --git a/tests/patterns/config.js b/tests/patterns/config.js index 7a382c28b00..fe9896fa54a 100644 --- a/tests/patterns/config.js +++ b/tests/patterns/config.js @@ -68,7 +68,7 @@ const testPatternConfig = (design, pattern, expect, models, patterns) => { } - if (['rendertest', 'tutorial'].indexOf(design) !== -1) { + if (['rendertest', 'tutorial'].indexOf(design) === -1) { /* * Ensure pattern is listed as being for breasts or not */ @@ -103,11 +103,9 @@ const testPatternConfig = (design, pattern, expect, models, patterns) => { for (let name in pattern.config.options) { let option = pattern.config.options[name] let type = typeof option - let dflt if (type === 'object' && typeof option.pct !== 'undefined') { // Percentage option it(` - '${name}' is a percentage option`, () => true) - dflt = option.pct it(` - Should have a default value`, () => { expect(typeof option.pct).to.equal('number') }) @@ -121,7 +119,6 @@ const testPatternConfig = (design, pattern, expect, models, patterns) => { else if (type === 'object' && typeof option.deg !== 'undefined') { // Degree option it(` - '${name}' is a degree option`, () => true) - dflt = option.deg it(` - Should have a default value`, () => { expect(typeof option.deg).to.equal('number') }) @@ -135,7 +132,6 @@ const testPatternConfig = (design, pattern, expect, models, patterns) => { else if (type === 'object' && typeof option.mm !== 'undefined') { // Millimeter option it(` - '${name}' is a distance (mm) option`, () => true) - dflt = option.mm it(` - Should have a default value`, () => { expect(typeof option.mm).to.equal('number') }) @@ -149,7 +145,6 @@ const testPatternConfig = (design, pattern, expect, models, patterns) => { else if (type === 'object' && typeof option.bool !== 'undefined') { // Boolean option it(` - '${name}' is a boolean option`, () => true) - dflt = option.bool it(` - Should have a default value`, () => { expect(typeof option.bool).to.equal('boolean') }) @@ -160,7 +155,6 @@ const testPatternConfig = (design, pattern, expect, models, patterns) => { else if (type === 'object' && typeof option.count !== 'undefined') { // Count option it(` - '${name}' is a count option`, () => true) - dflt = option.count it(` - Should have a default value`, () => { expect(typeof option.count).to.equal('number') }) @@ -174,7 +168,6 @@ const testPatternConfig = (design, pattern, expect, models, patterns) => { else if (type === 'object' && typeof option.list !== 'undefined') { // List option it(` - '${name}' is a list option`, () => true) - dflt = option.dflt it(` - Should have a default value`, () => { expect(typeof option.dflt).to.not.equal('undefined') })