2021-04-30 10:33:36 +01:00
|
|
|
// Copyright (C) 2021 Storj Labs, Inc.
|
|
|
|
// See LICENSE for copying information.
|
|
|
|
|
|
|
|
import { shallowMount } from '@vue/test-utils';
|
|
|
|
|
2022-11-04 11:57:05 +00:00
|
|
|
import NodeOptions from '@/app/components/common/NodeOptions.vue';
|
|
|
|
|
2021-04-30 10:33:36 +01:00
|
|
|
describe('NodeOptions', (): void => {
|
2021-08-02 18:09:54 +01:00
|
|
|
it('renders correctly', async(): Promise<void> => {
|
2021-04-30 10:33:36 +01:00
|
|
|
const wrapper = shallowMount(NodeOptions, {
|
|
|
|
propsData: { id: 'id' },
|
2021-08-31 13:36:31 +01:00
|
|
|
directives: {
|
|
|
|
clickOutside: {},
|
|
|
|
},
|
2021-04-30 10:33:36 +01:00
|
|
|
});
|
|
|
|
|
|
|
|
expect(wrapper).toMatchSnapshot();
|
|
|
|
|
|
|
|
await wrapper.find('.options-button').trigger('click');
|
|
|
|
|
|
|
|
expect(wrapper).toMatchSnapshot();
|
|
|
|
});
|
|
|
|
});
|