Skip to content
This repository has been archived by the owner on Mar 30, 2018. It is now read-only.

Commit

Permalink
update tests
Browse files Browse the repository at this point in the history
  • Loading branch information
sureshHARDIYA committed Mar 15, 2017
1 parent b012aea commit bb02e39
Show file tree
Hide file tree
Showing 4 changed files with 111 additions and 71 deletions.
6 changes: 5 additions & 1 deletion src/Modal/__tests__/__snapshots__/Dialog-test.js.snap
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,10 @@ exports[`Dialog renders correctly 1`] = `
/>
Lorem Ipsum
<div
className="uk-modal-body"
>
Lorem Ipsum
</div>
</div>
`;
108 changes: 72 additions & 36 deletions src/Modal/__tests__/__snapshots__/index-test.js.snap
Original file line number Diff line number Diff line change
Expand Up @@ -34,28 +34,32 @@ exports[`Modal renders a Blank Modal 1`] = `
<div
className="uk-grid uk-flex-middle"
className="uk-modal-body"
>
<div
className="uk-width-medium-1-2 uk-height-viewport uk-cover-background uk-row-first"
style={
Object {
"backgroundImage": "url(http://getuikit.com/docs/images/placeholder_120x255.svg)",
}
}
/>
<div
className="uk-width-medium-1-2"
className="uk-grid uk-flex-middle"
>
<h1>
Headline
</h1>
<div
className="uk-width-medium-1-3"
className="uk-width-medium-1-2 uk-height-viewport uk-cover-background uk-row-first"
style={
Object {
"backgroundImage": "url(http://getuikit.com/docs/images/placeholder_120x255.svg)",
}
}
/>
<div
className="uk-width-medium-1-2"
>
<p>
Lorem ipsum
</p>
<h1>
Headline
</h1>
<div
className="uk-width-medium-1-3"
>
<p>
Lorem ipsum
</p>
</div>
</div>
</div>
</div>
Expand Down Expand Up @@ -101,7 +105,11 @@ exports[`Modal renders a Caption 1`] = `
>
Caption
</div>
Lorem ipsum
<div
className="uk-modal-body"
>
Lorem ipsum
</div>
</div>
</div>
</Portal>
Expand Down Expand Up @@ -146,7 +154,11 @@ exports[`Modal renders a Header and Footer 1`] = `
</h2>
</div>
Lorem ipsum
<div
className="uk-modal-body"
>
Lorem ipsum
</div>
<div
className="uk-modal-footer uk-text-right"
>
Expand Down Expand Up @@ -194,11 +206,15 @@ exports[`Modal renders a Lightbox 1`] = `
/>
<img
alt=""
role="presentation"
src="http://getuikit.com/docs/images/placeholder_600x400.svg"
/>
<div
className="uk-modal-body"
>
<img
alt=""
role="presentation"
src="http://getuikit.com/docs/images/placeholder_600x400.svg"
/>
</div>
</div>
</div>
</Portal>
Expand Down Expand Up @@ -234,8 +250,12 @@ exports[`Modal renders a Spinner 1`] = `
<div
className="uk-modal-spinner"
/>
className="uk-modal-body"
>
<div
className="uk-modal-spinner"
/>
</div>
</div>
</div>
</Portal>
Expand Down Expand Up @@ -270,7 +290,11 @@ exports[`Modal renders an alert modal 1`] = `
>
Something bad happened!
<div
className="uk-modal-body"
>
Something bad happened!
</div>
<div
className="uk-modal-footer uk-text-right"
>
Expand Down Expand Up @@ -316,7 +340,11 @@ exports[`Modal renders an confirm modal 1`] = `
>
Are you absolutely sure about this?
<div
className="uk-modal-body"
>
Are you absolutely sure about this?
</div>
<div
className="uk-modal-footer uk-text-right"
>
Expand Down Expand Up @@ -373,14 +401,18 @@ exports[`Modal renders an prompt modal 1`] = `
<div
className="uk-margin-small-top uk-modal-content uk-form"
className="uk-modal-body"
>
<p>
<input
className="uk-width-1-1"
type="text"
/>
</p>
<div
className="uk-margin-small-top uk-modal-content uk-form"
>
<p>
<input
className="uk-width-1-1"
type="text"
/>
</p>
</div>
</div>
<div
className="uk-modal-footer uk-text-right"
Expand Down Expand Up @@ -441,7 +473,11 @@ exports[`Modal renders correctly 1`] = `
/>
Lorem ipsum
<div
className="uk-modal-body"
>
Lorem ipsum
</div>
</div>
</div>
</Portal>
Expand Down
36 changes: 18 additions & 18 deletions src/__tests__/__snapshots__/Dropdown-test.js.snap
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ exports[`Dropdown changes the class when clicked 1`] = `
<div
aria-expanded={false}
aria-haspopup={true}
className="uk-button-dropdown"
className="uk-inline"
onClick={[Function]}
onMouseEnter={false}
onMouseLeave={false}
Expand All @@ -24,7 +24,7 @@ exports[`Dropdown changes the class when clicked 2`] = `
<div
aria-expanded={true}
aria-haspopup={true}
className="uk-button-dropdown uk-open"
className="uk-inline uk-open"
onClick={[Function]}
onMouseEnter={false}
onMouseLeave={false}
Expand All @@ -44,7 +44,7 @@ exports[`Dropdown changes the class when clicked 3`] = `
<div
aria-expanded={false}
aria-haspopup={true}
className="uk-button-dropdown"
className="uk-inline"
onClick={[Function]}
onMouseEnter={false}
onMouseLeave={false}
Expand All @@ -64,7 +64,7 @@ exports[`Dropdown changes the class when hovered 1`] = `
<div
aria-expanded={false}
aria-haspopup={true}
className="uk-button-dropdown"
className="uk-inline"
onClick={[Function]}
onMouseEnter={[Function]}
onMouseLeave={[Function]}
Expand All @@ -84,7 +84,7 @@ exports[`Dropdown changes the class when hovered 2`] = `
<div
aria-expanded={true}
aria-haspopup={true}
className="uk-button-dropdown uk-open"
className="uk-inline uk-open"
onClick={[Function]}
onMouseEnter={[Function]}
onMouseLeave={[Function]}
Expand All @@ -104,7 +104,7 @@ exports[`Dropdown changes the class when hovered 3`] = `
<div
aria-expanded={true}
aria-haspopup={true}
className="uk-button-dropdown uk-open"
className="uk-inline uk-open"
onClick={[Function]}
onMouseEnter={[Function]}
onMouseLeave={[Function]}
Expand All @@ -124,7 +124,7 @@ exports[`Dropdown changes the class when hovered 4`] = `
<div
aria-expanded={false}
aria-haspopup={true}
className="uk-button-dropdown"
className="uk-inline"
onClick={[Function]}
onMouseEnter={[Function]}
onMouseLeave={[Function]}
Expand All @@ -144,7 +144,7 @@ exports[`Dropdown changes the class when hovered 5`] = `
<div
aria-expanded={true}
aria-haspopup={true}
className="uk-button-dropdown uk-open"
className="uk-inline uk-open"
onClick={[Function]}
onMouseEnter={[Function]}
onMouseLeave={[Function]}
Expand All @@ -164,7 +164,7 @@ exports[`Dropdown changes the class when hovered 6`] = `
<div
aria-expanded={true}
aria-haspopup={true}
className="uk-button-dropdown uk-open"
className="uk-inline uk-open"
onClick={[Function]}
onMouseEnter={[Function]}
onMouseLeave={[Function]}
Expand All @@ -184,7 +184,7 @@ exports[`Dropdown closes sibling Dropdown on open 1`] = `
<div
aria-expanded={false}
aria-haspopup={true}
className="uk-button-dropdown"
className="uk-inline"
onClick={[Function]}
onMouseEnter={[Function]}
onMouseLeave={[Function]}
Expand All @@ -204,7 +204,7 @@ exports[`Dropdown closes sibling Dropdown on open 2`] = `
<div
aria-expanded={true}
aria-haspopup={true}
className="uk-button-dropdown uk-open"
className="uk-inline uk-open"
onClick={[Function]}
onMouseEnter={[Function]}
onMouseLeave={[Function]}
Expand All @@ -224,7 +224,7 @@ exports[`Dropdown closes sibling Dropdown on open 3`] = `
<div
aria-expanded={false}
aria-haspopup={true}
className="uk-button-dropdown"
className="uk-inline"
onClick={[Function]}
onMouseEnter={[Function]}
onMouseLeave={[Function]}
Expand All @@ -244,7 +244,7 @@ exports[`Dropdown closes when clicked when in hover mode 1`] = `
<div
aria-expanded={true}
aria-haspopup={true}
className="uk-button-dropdown uk-open"
className="uk-inline uk-open"
onClick={[Function]}
onMouseEnter={[Function]}
onMouseLeave={[Function]}
Expand All @@ -264,7 +264,7 @@ exports[`Dropdown closes when clicked when in hover mode 2`] = `
<div
aria-expanded={false}
aria-haspopup={true}
className="uk-button-dropdown"
className="uk-inline"
onClick={[Function]}
onMouseEnter={[Function]}
onMouseLeave={[Function]}
Expand All @@ -284,7 +284,7 @@ exports[`Dropdown closes when clicked when in hover mode 3`] = `
<div
aria-expanded={false}
aria-haspopup={true}
className="uk-button-dropdown"
className="uk-inline"
onClick={[Function]}
onMouseEnter={[Function]}
onMouseLeave={[Function]}
Expand All @@ -304,7 +304,7 @@ exports[`Dropdown renders correctly 1`] = `
<div
aria-expanded={false}
aria-haspopup={true}
className="uk-button-dropdown"
className="uk-inline"
onClick={[Function]}
onMouseEnter={[Function]}
onMouseLeave={[Function]}
Expand Down Expand Up @@ -342,7 +342,7 @@ exports[`should be closed 1`] = `
<div
aria-expanded={false}
aria-haspopup={true}
className="uk-button-dropdown"
className="uk-inline"
onClick={[Function]}
onMouseEnter={[Function]}
onMouseLeave={[Function]}
Expand All @@ -362,7 +362,7 @@ exports[`should be open 1`] = `
<div
aria-expanded={true}
aria-haspopup={true}
className="uk-button-dropdown uk-open"
className="uk-inline uk-open"
onClick={[Function]}
onMouseEnter={[Function]}
onMouseLeave={[Function]}
Expand Down

0 comments on commit bb02e39

Please sign in to comment.