Skip to content

Commit 52539f5

Browse files
committed
updated new About, Contact and Settings tsx files to correct react import error, update MainContainer.test update to test render of About Contact and Settings
1 parent 0818ed2 commit 52539f5

4 files changed

Lines changed: 24 additions & 3 deletions

File tree

__tests__/app/containers/MainContainer.test.tsx

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,9 @@ import Home from '../../../app/components/Home'
88
import Copyright from '../../../app/components/Copyright'
99
import Occupied from '../../../app/components/Occupied'
1010
import GraphsContainer from '../../../app/containers/GraphsContainer'
11+
import About from '../../../app/components/About'
12+
import Contact from '../../../app/components/Contact';
13+
import Settings from '../../../app/components/Settings';
1114

1215
describe('<MainContainer />', () => {
1316
it(' renders component Home', () => {
@@ -33,6 +36,24 @@ describe('<MainContainer />', () => {
3336
expect(wrapper.contains(<Route exact path="/applications/:app/:service" component={GraphsContainer} />)).toBe(true);
3437

3538
})
39+
it('renders container About', () => {
40+
const wrapper = shallow (<MainContainer />);
41+
42+
expect(wrapper.contains(<Route path="/about" component={About} />)).toBe(true);
43+
44+
})
45+
it('renders container Contact', () => {
46+
const wrapper = shallow (<MainContainer />);
47+
48+
expect(wrapper.contains(<Route path="/contact" component={Contact} />)).toBe(true);
49+
50+
})
51+
it('renders container Settings', () => {
52+
const wrapper = shallow (<MainContainer />);
53+
54+
expect(wrapper.contains(<Route path="/settings" component={Settings} />)).toBe(true);
55+
56+
})
3657

3758
});
3859

app/components/About.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import React from 'React';
1+
import React from 'react';
22

33
const About: React.FC = () => {
44
return <div className="home">Hello this is the About</div>;

app/components/Contact.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import React from 'React';
1+
import React from 'react';
22

33
const Contact: React.FC = () => {
44
return <div className="home">Hello this is the Contact</div>;

app/components/Settings.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import React from 'React';
1+
import React from 'react';
22

33
// Need to add flag to turn off the splash at start
44
// Need to add flag to turn off getting started page

0 commit comments

Comments
 (0)