mirror of
https://github.com/Azure/cosmos-explorer.git
synced 2025-04-25 19:13:48 +01:00
21 lines
888 B
TypeScript
21 lines
888 B
TypeScript
import { shallow, ShallowWrapper } from "enzyme";
|
|
import Explorer from "Explorer/Explorer";
|
|
import { AddMaterializedViewPanel, AddMaterializedViewPanelProps } from "Explorer/Panes/AddMaterializedViewPanel/AddMaterializedViewPanel";
|
|
import React, { Component } from "react";
|
|
|
|
const props: AddMaterializedViewPanelProps = {
|
|
explorer: new Explorer()
|
|
};
|
|
|
|
describe("AddMaterializedViewPanel", () => {
|
|
it("render default panel", () => {
|
|
const wrapper: ShallowWrapper<AddMaterializedViewPanelProps, {}, Component> = shallow(<AddMaterializedViewPanel {...props} />);
|
|
expect(wrapper).toMatchSnapshot();
|
|
});
|
|
|
|
it("should render form", () => {
|
|
const wrapper: ShallowWrapper<AddMaterializedViewPanelProps, {}, Component> = shallow(<AddMaterializedViewPanel {...props} />);
|
|
const form = wrapper.find("form").first();
|
|
expect(form).toBeDefined();
|
|
});
|
|
}); |