-
Notifications
You must be signed in to change notification settings - Fork 91
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'master' into ahtesham/VAN-1601/design
- Loading branch information
Showing
42 changed files
with
2,147 additions
and
1,819 deletions.
There are no files selected for viewing
Large diffs are not rendered by default.
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
53 changes: 53 additions & 0 deletions
53
src/components/ModalView/__snapshots__/index.test.jsx.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,53 @@ | ||
// Jest Snapshot v1, https://goo.gl/fbAQLP | ||
|
||
exports[`Banner snapshot renders default ModalView 1`] = ` | ||
<div | ||
className="containers" | ||
> | ||
<ModalDialog | ||
hasCloseButton={false} | ||
isFullscreenScroll={true} | ||
isOpen={true} | ||
onClose={[Function]} | ||
title="" | ||
> | ||
<ModalDialog.Header> | ||
<Component> | ||
<h3 | ||
className="mt-2" | ||
> | ||
Thank you for your interest! | ||
</h3> | ||
</Component> | ||
</ModalDialog.Header> | ||
<ModalDialog.Body> | ||
<div | ||
className="modal-continer" | ||
> | ||
<p | ||
className="mt-2" | ||
> | ||
Personalized recommendations feature is not yet available. We are working hard on bringing it to your learner home in the near future. | ||
</p> | ||
<p> | ||
Would you like to be alerted when it becomes available? | ||
</p> | ||
</div> | ||
</ModalDialog.Body> | ||
<Component> | ||
<ActionRow> | ||
<Component | ||
variant="tertiary" | ||
> | ||
Skip for now | ||
</Component> | ||
<Button | ||
variant="primary" | ||
> | ||
Count me in! | ||
</Button> | ||
</ActionRow> | ||
</Component> | ||
</ModalDialog> | ||
</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,26 @@ | ||
import { shallow } from 'enzyme'; | ||
|
||
import ModalView from '.'; | ||
|
||
describe('Banner', () => { | ||
const props = { | ||
isOpen: true, | ||
onClose: jest.fn(), | ||
}; | ||
describe('snapshot', () => { | ||
test('renders default ModalView', () => { | ||
const wrapper = shallow(<ModalView {...props} />); | ||
expect(wrapper).toMatchSnapshot(); | ||
}); | ||
// test('renders with variants', () => { | ||
// const wrapper = shallow(<Banner {...props} variant="success" />); | ||
// expect(wrapper).toMatchSnapshot(); | ||
|
||
// expect(wrapper.find(Alert).prop('variant')).toEqual('success'); | ||
// }); | ||
// test('renders with custom class', () => { | ||
// const wrapper = shallow(<Banner {...props} className="custom-class" />); | ||
// expect(wrapper).toMatchSnapshot(); | ||
// }); | ||
}); | ||
}); |
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
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
Oops, something went wrong.