Browse Source

Fix test regression

pull/1663/head
Artur Arseniev 8 years ago
parent
commit
518fb9c15a
  1. 5
      src/style_manager/model/Layer.js
  2. 8
      test/specs/style_manager/model/Models.js

5
src/style_manager/model/Layer.js

@ -18,7 +18,10 @@ module.exports = Backbone.Model.extend({
'properties',
properties instanceof Properties ? properties : new Properties(properties)
);
this.get('properties').forEach(item => item.parent = this.collection.property);
this.get('properties').forEach(item => {
const { collection } = this;
item.parent = collection && collection.property;
});
// If there is no value I'll try to get it from values
// I need value setted to make preview working

8
test/specs/style_manager/model/Models.js

@ -703,7 +703,7 @@ module.exports = {
property: 'border-top-left-radius',
type: 'integer',
units: ['px', '%'],
defaults: 0,
defaults: '0px',
min: 0
},
{
@ -711,21 +711,21 @@ module.exports = {
type: 'integer',
units: ['px', '%'],
min: 0,
defaults: 0
defaults: '0px'
},
{
property: 'border-bottom-left-radius',
type: 'integer',
units: ['px', '%'],
min: 0,
defaults: 0
defaults: '0px'
},
{
property: 'border-bottom-right-radius',
type: 'integer',
units: ['px', '%'],
min: 0,
defaults: 0
defaults: '0px'
}
]
};

Loading…
Cancel
Save