2021-03-24 15:43:12 +00:00
|
|
|
// Copyright (C) 2021 Storj Labs, Inc.
|
|
|
|
// See LICENSE for copying information.
|
|
|
|
|
|
|
|
import { createLocalVue, shallowMount } from '@vue/test-utils';
|
|
|
|
|
2022-11-04 11:48:16 +00:00
|
|
|
import WalletArea from '@/app/components/WalletArea.vue';
|
|
|
|
|
2021-03-24 15:43:12 +00:00
|
|
|
const localVue = createLocalVue();
|
|
|
|
|
|
|
|
describe('WalletArea', (): void => {
|
|
|
|
|
|
|
|
it('renders correctly with no wallet features', (): void => {
|
|
|
|
|
|
|
|
const wrapper = shallowMount(WalletArea, {
|
|
|
|
localVue,
|
|
|
|
propsData: {
|
|
|
|
walletAddress: '0x0123456789012345678901234567890123456789',
|
|
|
|
walletFeatures: [],
|
|
|
|
label: 'Wallet address',
|
|
|
|
},
|
|
|
|
});
|
|
|
|
|
|
|
|
expect(wrapper).toMatchSnapshot();
|
|
|
|
});
|
|
|
|
|
|
|
|
it('renders correctly with no wallet features', (): void => {
|
|
|
|
|
|
|
|
const wrapper = shallowMount(WalletArea, {
|
|
|
|
localVue,
|
|
|
|
propsData: {
|
|
|
|
walletAddress: '0x0123456789012345678901234567890123456789',
|
|
|
|
walletFeatures: [ 'zksync' ],
|
|
|
|
label: 'Wallet address',
|
|
|
|
},
|
|
|
|
});
|
|
|
|
|
|
|
|
expect(wrapper).toMatchSnapshot();
|
|
|
|
});
|
|
|
|
});
|