Skip to content

Commit b2c201d

Browse files
Changed test to call select instead of set
But no idea why value is readonly property.
1 parent e34e397 commit b2c201d

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

test/unit/specs/Select.spec.js

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -131,22 +131,22 @@ describe('Select.vue', () => {
131131
var select = vm.$children[0]
132132
expect(select.isValueEmpty).toEqual(true)
133133

134-
select.$set('value', ['one'])
134+
select.select(['one'])
135135
expect(select.isValueEmpty).toEqual(false)
136136

137-
select.$set('value', [{l: 'f'}])
137+
select.select([{l: 'f'}])
138138
expect(select.isValueEmpty).toEqual(false)
139139

140-
select.$set('value', 'one')
140+
select.select('one')
141141
expect(select.isValueEmpty).toEqual(false)
142142

143-
select.$set('value', {label: 'foo', value: 'foo'})
143+
select.select({label: 'foo', value: 'foo'})
144144
expect(select.isValueEmpty).toEqual(false)
145145

146-
select.$set('value', '')
146+
select.select('')
147147
expect(select.isValueEmpty).toEqual(true)
148148

149-
select.$set('value', null)
149+
select.select(null)
150150
expect(select.isValueEmpty).toEqual(true)
151151
})
152152

@@ -896,4 +896,4 @@ describe('Select.vue', () => {
896896
})
897897
})
898898
})
899-
})
899+
})

0 commit comments

Comments
 (0)