cleanup
This commit is contained in:
parent
71a4781080
commit
d8d766932a
|
@ -125,7 +125,6 @@ export const deserialize = (input) => {
|
|||
|
||||
output.directives = Object.fromEntries(content.map(d => {
|
||||
const [property, value] = d.split(':')
|
||||
console.log(property, value)
|
||||
let realValue = value.trim()
|
||||
if (property === 'shadow') {
|
||||
realValue = parseShadow(value.split(',').map(v => v.trim()))
|
||||
|
|
|
@ -4,12 +4,12 @@ import Button from 'src/components/button.style.js'
|
|||
|
||||
describe.only('ISS (de)serialization', () => {
|
||||
describe('ISS deserialization', () => {
|
||||
it('Output should = input', () => {
|
||||
it('Output should equal input', () => {
|
||||
const normalized = Button.defaultRules.map(x => ({ component: 'Button', ...x }))
|
||||
const serialized = serialize(normalized)
|
||||
const deserialized = deserialize(serialized)
|
||||
// deserialized.toString()
|
||||
|
||||
// for some reason comparing objects directly fails the assert
|
||||
expect(JSON.stringify(deserialized)).to.equal(JSON.stringify(normalized))
|
||||
})
|
||||
})
|
||||
|
|
Loading…
Reference in a new issue