-
Notifications
You must be signed in to change notification settings - Fork 3
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 #25 from dabapps/jest
Jest
- Loading branch information
Showing
36 changed files
with
670 additions
and
540 deletions.
There are no files selected for viewing
This file was deleted.
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
This file was deleted.
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
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 |
---|---|---|
@@ -1,9 +1,13 @@ | ||
// Jest Snapshot v1, https://goo.gl/fbAQLP | ||
|
||
exports[`Alert should match snapshot 1`] = ` | ||
<div | ||
className="alert" /> | ||
className="alert" | ||
/> | ||
`; | ||
|
||
exports[`Alert should take regular element attributes 1`] = ` | ||
<div | ||
className="alert my-class" /> | ||
className="alert my-class" | ||
/> | ||
`; |
17 changes: 12 additions & 5 deletions
17
tests/button.tsx.snap → tests/__snapshots__/button.tsx.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 |
---|---|---|
@@ -1,24 +1,31 @@ | ||
// Jest Snapshot v1, https://goo.gl/fbAQLP | ||
|
||
exports[`Button should match snapshot 1`] = ` | ||
<button | ||
className="button" /> | ||
className="button" | ||
/> | ||
`; | ||
|
||
exports[`Button should take an optional large prop 1`] = ` | ||
<button | ||
className="button large" /> | ||
className="button large" | ||
/> | ||
`; | ||
|
||
exports[`Button should take regular element attributes 1`] = ` | ||
<button | ||
className="button my-class" /> | ||
className="button my-class" | ||
/> | ||
`; | ||
|
||
exports[`Button should use a block prop (boolean) as a class name 1`] = ` | ||
<button | ||
className="button block" /> | ||
className="button block" | ||
/> | ||
`; | ||
|
||
exports[`Button should use a type prop as a class name 1`] = ` | ||
<button | ||
className="button primary" /> | ||
className="button primary" | ||
/> | ||
`; |
35 changes: 22 additions & 13 deletions
35
tests/code-block.tsx.snap → tests/__snapshots__/code-block.tsx.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 |
---|---|---|
@@ -1,48 +1,57 @@ | ||
// Jest Snapshot v1, https://goo.gl/fbAQLP | ||
|
||
exports[`CodeBlock should handle empty code snippets 1`] = ` | ||
<pre | ||
className="language-javascript"> | ||
className="language-javascript" | ||
> | ||
</pre> | ||
`; | ||
|
||
exports[`CodeBlock should match snapshot 1`] = ` | ||
<pre | ||
className="" /> | ||
className="" | ||
/> | ||
`; | ||
|
||
exports[`CodeBlock should remove weird indentation from multi line snippets 1`] = ` | ||
<pre | ||
className=""> | ||
<p> | ||
className="" | ||
> | ||
<p> | ||
Hello, World! | ||
</p> | ||
</p> | ||
</pre> | ||
`; | ||
|
||
exports[`CodeBlock should remove weird indentation from multi line snippets 2`] = ` | ||
<pre | ||
className=""> | ||
<p> | ||
className="" | ||
> | ||
<p> | ||
Hello, World! | ||
</p> | ||
</p> | ||
</pre> | ||
`; | ||
|
||
exports[`CodeBlock should remove weird indentation from single line snippets 1`] = ` | ||
<pre | ||
className=""> | ||
console.log(\'test\') | ||
className="" | ||
> | ||
console.log('test') | ||
</pre> | ||
`; | ||
|
||
exports[`CodeBlock should remove weird indentation from single line snippets 2`] = ` | ||
<pre | ||
className=""> | ||
console.log(\'test\') | ||
className="" | ||
> | ||
console.log('test') | ||
</pre> | ||
`; | ||
|
||
exports[`CodeBlock should take an optional language prop 1`] = ` | ||
<pre | ||
className="language-javascript" /> | ||
className="language-javascript" | ||
/> | ||
`; |
Oops, something went wrong.