Skip to content

Latest commit

 

History

History
21 lines (15 loc) · 434 Bytes

File metadata and controls

21 lines (15 loc) · 434 Bytes

at(index)

Retourne le Wrapper à l'index passé en paramètre. L'indexation commence à 0.

  • Paramètre :

    • {number} index
  • Retourne : {Wrapper}

  • Exemple :

import { shallow } from 'vue-test-utils'
import { expect } from 'chai'
import Foo from './Foo.vue'

const wrapper = shallow(Foo)
const divArray = wrapper.findAll('div')
const secondDiv = divArray.at(1)
expect(secondDiv.is('p')).toBe(true)