Skip to content

Commit 9d18924

Browse files
committed
Fixed test to match new jest version
1 parent 28fae12 commit 9d18924

File tree

2 files changed

+4
-3
lines changed

2 files changed

+4
-3
lines changed

exercises/05-adding-styles/tests.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,11 +11,12 @@ test("ReactDOM needs to be called once", () => {
1111

1212
test("The component Badge should return the exact HTML", () => {
1313
const tree = renderer.create(ReactDOM.render.mock.calls[0][0]).toJSON();
14+
// throw tree
1415
expect(tree).toMatchInlineSnapshot(`
1516
<button
1617
className="btn btn-primary"
1718
style={
18-
Object {
19+
{
1920
"background": "black",
2021
"border": "1px solid yellow",
2122
"fontSize": "16px",

exercises/05.1-second-styles/tests.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ test("The component Badge should return the exact HTML", () => {
1515
<button
1616
className="btn btn-primary"
1717
style={
18-
Object {
18+
{
1919
"background": "yellow",
2020
"border": "none",
2121
"color": "black",
@@ -27,7 +27,7 @@ test("The component Badge should return the exact HTML", () => {
2727
<span
2828
className="badge badge-light"
2929
style={
30-
Object {
30+
{
3131
"background": "red",
3232
"borderRadius": "50%",
3333
}

0 commit comments

Comments
 (0)