Skip to content

Commit

Permalink
adding 2 new test cases
Browse files Browse the repository at this point in the history
  • Loading branch information
yashb196 committed Aug 25, 2023
1 parent cce7f8b commit a053364
Show file tree
Hide file tree
Showing 4 changed files with 36 additions and 0 deletions.
15 changes: 15 additions & 0 deletions __tests__/LoginScreen.test.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
import Enzyme from 'enzyme';
import Adapter from 'enzyme-adapter-react-16';

Enzyme.configure({ adapter: new Adapter() });

import React from 'react';
import { shallow } from "enzyme";
import LoginScreen from '../lib/screens/loginScreens/LoginScreen.tsx';

describe("LoginScreen", () => {
it("renders without crashing", () => {
const wrapper = shallow(<LoginScreen />);
expect(wrapper).toMatchSnapshot();
});
});
15 changes: 15 additions & 0 deletions __tests__/NoteDetailModal.test.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
import Enzyme from 'enzyme';
import Adapter from 'enzyme-adapter-react-16';

Enzyme.configure({ adapter: new Adapter() });

import React from 'react';
import { shallow } from "enzyme";
import NoteDetailModal from '../lib/screens/mapPage/NoteDetailModal.tsx';

describe("NoteDetailModal", () => {
it("renders without crashing", () => {
const wrapper = shallow(<NoteDetailModal />);
expect(wrapper).toMatchSnapshot();
});
});
3 changes: 3 additions & 0 deletions __tests__/__snapshots__/LoginScreen.test.tsx.snap
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP

exports[`LoginScreen renders without crashing 1`] = `ShallowWrapper {}`;
3 changes: 3 additions & 0 deletions __tests__/__snapshots__/NoteDetailModal.test.tsx.snap
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP

exports[`NoteDetailModal renders without crashing 1`] = `ShallowWrapper {}`;

0 comments on commit a053364

Please sign in to comment.