@@ -861,12 +861,11 @@ import Button from '../../src/components/Button.vue'
861861
862862Cypress .Commands .add (' mount' , (component , options = {}) => {
863863 // Setup options object
864- options .extensions = options .extensions || {}
865- options .extensions .plugins = options .extensions .plugins || []
866- options .extensions .components = options .extensions .components || {}
864+ options .global = options .global || {}
865+ options .global .components = options .global .components || {}
867866
868867 // Register global components
869- options .extensions .components [' Button' ] = Button
868+ options .global .components [' Button' ] = Button
870869
871870 return mount (component, options)
872871})
@@ -876,16 +875,16 @@ Cypress.Commands.add('mount', (component, options = {}) => {
876875<TabItem value = " Vue 2" >
877876
878877``` js
879- import { mount } from ' cypress/vue '
878+ import { mount } from ' cypress/vue2 '
880879import Button from ' ../../src/components/Button.vue'
881880
882881Cypress .Commands .add (' mount' , (component , options = {}) => {
883882 // Setup options object
884- options .global = options .global || {}
885- options .global .components = options .global .components || {}
883+ options .extensions = options .extensions || {}
884+ options .extensions .components = options .extensions .components || {}
886885
887886 // Register global components
888- options .global .components [' Button' ] = Button
887+ options .extensions .components [' Button' ] = Button
889888
890889 return mount (component, options)
891890})
0 commit comments