Commit | Line | Data |
---|---|---|
258a5c7f JB |
1 | import { expect } from 'chai'; |
2 | import { shallowMount } from '@vue/test-utils'; | |
3 | import CSTable from '@/components/charging-stations/CSTable.vue'; | |
4 | import type { ChargingStationData } from '@/type/ChargingStationType'; | |
5 | ||
6 | describe('CSTable.vue', () => { | |
7 | it('renders CS table columns name', () => { | |
8 | const chargingStations: Record<string, ChargingStationData> = { | |
9 | '0': {} as unknown as ChargingStationData, | |
10 | }; | |
11 | const wrapper = shallowMount(CSTable, { | |
12 | props: { chargingStations, idTag: '0' }, | |
13 | }); | |
14 | console.log(wrapper.text()); | |
15 | expect(wrapper.text()).to.include('Action'); | |
16 | expect(wrapper.text()).to.include('Connector'); | |
17 | expect(wrapper.text()).to.include('Status'); | |
18 | expect(wrapper.text()).to.include('Transaction'); | |
19 | expect(wrapper.text()).to.include('Name'); | |
20 | expect(wrapper.text()).to.include('Stopped'); | |
21 | expect(wrapper.text()).to.include('Registration Status'); | |
22 | expect(wrapper.text()).to.include('Vendor'); | |
23 | expect(wrapper.text()).to.include('Model'); | |
24 | expect(wrapper.text()).to.include('Firmware Version'); | |
25 | }); | |
26 | }); |