generated from pesto-students/PESTO_NINJA-TEMPLATE
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #11 from pesto-students/feature/sprintsUi
Added test cases
- Loading branch information
Showing
19 changed files
with
258 additions
and
19 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -24,6 +24,11 @@ function LoginView(props) { | |
if (!validateEmail(values.email)) return Notification("Validation Failed", "invalid email"); | ||
dispatch(ForgotPassword(values.email)); | ||
}; | ||
const loginFix = (isScrumMaster) => { | ||
// if (!validateEmail(email)) return openAuthNotification("Validation Failed", "invalid email"); | ||
if (isScrumMaster) dispatch(LoginUser("[email protected]", "P@ssword1")); | ||
else dispatch(LoginUser("[email protected]", "CRIMINALcase1")); | ||
}; | ||
return ( | ||
<> | ||
<div align="middle"> | ||
|
@@ -65,6 +70,28 @@ function LoginView(props) { | |
Log in | ||
</AppButton> | ||
</Form.Item> | ||
<Form.Item> | ||
<FullLengthButton | ||
type="primary" | ||
size="large" | ||
disabled={loading} | ||
htmlType="submit" | ||
onClick={() => loginFix(true)} | ||
> | ||
Log in as ScrumMaster * | ||
</FullLengthButton> | ||
</Form.Item> | ||
<Form.Item> | ||
<FullLengthButton | ||
type="primary" | ||
size="large" | ||
disabled={loading} | ||
htmlType="submit" | ||
onClick={() => loginFix(false)} | ||
> | ||
Log in as Developer * | ||
</FullLengthButton> | ||
</Form.Item> | ||
<Form.Item> | ||
<Text type="secondary"> | ||
forgot password? | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
import React from "react"; | ||
import renderer from "react-test-renderer"; | ||
import ActiveMark from "src/components/Common/ActiveMark/ActiveMark"; | ||
it("ActiveMark renders correctly", () => { | ||
const tree = renderer.create(<ActiveMark />).toJSON(); | ||
expect(tree).toMatchSnapshot(); | ||
}); |
3 changes: 3 additions & 0 deletions
3
src/components/Common/ActiveMark/__snapshots__/ActiveMark.test.js.snap
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
// Jest Snapshot v1, https://goo.gl/fbAQLP | ||
|
||
exports[`ActiveMark renders correctly 1`] = `<div />`; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
import React from "react"; | ||
import renderer from "react-test-renderer"; | ||
import AppButton from "src/components/Common/AppButton/AppButton"; | ||
it("ActiveMark renders correctly", () => { | ||
const tree = renderer.create(<AppButton>Button</AppButton>).toJSON(); | ||
expect(tree).toMatchSnapshot(); | ||
}); |
13 changes: 13 additions & 0 deletions
13
src/components/Common/AppButton/__snapshots__/AppButton.test.js.snap
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
// Jest Snapshot v1, https://goo.gl/fbAQLP | ||
|
||
exports[`ActiveMark renders correctly 1`] = ` | ||
<button | ||
className="ant-btn ant-btn-primary" | ||
onClick={[Function]} | ||
type="button" | ||
> | ||
<span> | ||
Button | ||
</span> | ||
</button> | ||
`; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
import React from "react"; | ||
import renderer from "react-test-renderer"; | ||
import AppDropDown from "src/components/Common/AppDropDown/AppDropDown"; | ||
it("ActiveMark renders correctly", () => { | ||
const tree = renderer.create(<AppDropDown />).toJSON(); | ||
expect(tree).toMatchSnapshot(); | ||
}); |
83 changes: 83 additions & 0 deletions
83
src/components/Common/AppDropDown/__snapshots__/AppDropDown.test.js.snap
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,83 @@ | ||
// Jest Snapshot v1, https://goo.gl/fbAQLP | ||
|
||
exports[`ActiveMark renders correctly 1`] = ` | ||
<div | ||
className="ant-select ant-select-lg ant-select-single ant-select-show-arrow" | ||
onBlur={[Function]} | ||
onFocus={[Function]} | ||
onKeyDown={[Function]} | ||
onKeyUp={[Function]} | ||
onMouseDown={[Function]} | ||
> | ||
<div | ||
className="ant-select-selector" | ||
onClick={[Function]} | ||
onMouseDown={[Function]} | ||
> | ||
<span | ||
className="ant-select-selection-search" | ||
> | ||
<input | ||
aria-activedescendant="undefined_list_0" | ||
aria-autocomplete="list" | ||
aria-controls="undefined_list" | ||
aria-haspopup="listbox" | ||
aria-owns="undefined_list" | ||
autoComplete="off" | ||
className="ant-select-selection-search-input" | ||
onChange={[Function]} | ||
onCompositionEnd={[Function]} | ||
onCompositionStart={[Function]} | ||
onKeyDown={[Function]} | ||
onMouseDown={[Function]} | ||
onPaste={[Function]} | ||
readOnly={true} | ||
role="combobox" | ||
style={ | ||
Object { | ||
"opacity": 0, | ||
} | ||
} | ||
type="search" | ||
unselectable="on" | ||
value="" | ||
/> | ||
</span> | ||
<span | ||
className="ant-select-selection-placeholder" | ||
/> | ||
</div> | ||
<span | ||
aria-hidden={true} | ||
className="ant-select-arrow" | ||
onMouseDown={[Function]} | ||
style={ | ||
Object { | ||
"WebkitUserSelect": "none", | ||
"userSelect": "none", | ||
} | ||
} | ||
unselectable="on" | ||
> | ||
<span | ||
aria-label="down" | ||
className="anticon anticon-down ant-select-suffix" | ||
role="img" | ||
> | ||
<svg | ||
aria-hidden="true" | ||
data-icon="down" | ||
fill="currentColor" | ||
focusable="false" | ||
height="1em" | ||
viewBox="64 64 896 896" | ||
width="1em" | ||
> | ||
<path | ||
d="M884 256h-75c-5.1 0-9.9 2.5-12.9 6.6L512 654.2 227.9 262.6c-3-4.1-7.8-6.6-12.9-6.6h-75c-6.5 0-10.3 7.4-6.5 12.7l352.6 486.1c12.8 17.6 39 17.6 51.7 0l352.6-486.1c3.9-5.3.1-12.7-6.4-12.7z" | ||
/> | ||
</svg> | ||
</span> | ||
</span> | ||
</div> | ||
`; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
import React from "react"; | ||
import renderer from "react-test-renderer"; | ||
import AppInput from "src/components/Common/AppInput/AppInput"; | ||
it("ActiveMark renders correctly", () => { | ||
const tree = renderer.create(<AppInput />).toJSON(); | ||
expect(tree).toMatchSnapshot(); | ||
}); |
13 changes: 13 additions & 0 deletions
13
src/components/Common/AppInput/__snapshots__/AppInput.test.js.snap
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
// Jest Snapshot v1, https://goo.gl/fbAQLP | ||
|
||
exports[`ActiveMark renders correctly 1`] = ` | ||
<input | ||
className="ant-input ant-input-lg" | ||
onBlur={[Function]} | ||
onChange={[Function]} | ||
onFocus={[Function]} | ||
onKeyDown={[Function]} | ||
type="text" | ||
value="" | ||
/> | ||
`; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
import React from "react"; | ||
import renderer from "react-test-renderer"; | ||
import AppModal from "src/components/Common/AppModal/AppModal"; | ||
it("ActiveMark renders correctly", () => { | ||
const tree = renderer.create(<AppModal>Modal</AppModal>).toJSON(); | ||
expect(tree).toMatchSnapshot(); | ||
}); |
3 changes: 3 additions & 0 deletions
3
src/components/Common/AppModal/__snapshots__/AppModal.test.js.snap
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
// Jest Snapshot v1, https://goo.gl/fbAQLP | ||
|
||
exports[`ActiveMark renders correctly 1`] = `null`; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
import React from "react"; | ||
import styles from "src/components/Common/Landing/About/About.module.less"; | ||
|
||
const About = () => { | ||
return ( | ||
<div className={styles.about}> | ||
Made with the collaborative efforts of | ||
<span>Vishnu Thiyagarajan</span>, <span>Vipan Kumar</span> and <span>Jyotrimaya Sahu</span>. | ||
</div> | ||
); | ||
}; | ||
|
||
export default About; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
@import "../../../themes/themes.less"; | ||
.about { | ||
padding: 1em; | ||
background-color: @primary-color; | ||
color: white; | ||
text-align: center; | ||
span { | ||
font-weight: bold; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters