diff --git a/test/specs/mounting-options/sync.spec.js b/test/specs/mounting-options/sync.spec.js
index 7426d1ce4..8f6cb59a4 100644
--- a/test/specs/mounting-options/sync.spec.js
+++ b/test/specs/mounting-options/sync.spec.js
@@ -113,9 +113,17 @@ describeWithShallowAndMount('options.sync', (mountingMethod) => {
})
it('call updated when sync is not false', () => {
+ const foo_spy = sinon.stub()
+ const Foo = {
+ template: '
{{ foo }}
',
+ props: ['foo'],
+ updated () {
+ foo_spy()
+ }
+ }
const spy = sinon.stub()
const TestComponent = {
- template: '{{ foo }}
',
+ template: '{{ foo }}
',
data () {
return {
foo: 'foo'
@@ -126,10 +134,13 @@ describeWithShallowAndMount('options.sync', (mountingMethod) => {
}
}
const wrapper = mountingMethod(TestComponent, {
+ stubs: { foo: Foo },
sync: true
})
expect(spy.notCalled).to.equal(true)
+ expect(foo_spy.notCalled).to.equal(true)
wrapper.vm.foo = 'bar'
expect(spy.calledOnce).to.equal(true)
+ expect(foo_spy.calledOnce).to.equal(true)
})
})