Skip to content

Commit 6a4ac28

Browse files
committed
Update readme with proper usage
1 parent 3713f55 commit 6a4ac28

File tree

1 file changed

+9
-4
lines changed

1 file changed

+9
-4
lines changed

readme.md

+9-4
Original file line numberDiff line numberDiff line change
@@ -35,12 +35,17 @@ $ npm install --save-dev bs-react-testing-library
3535
open Jest;
3636
3737
describe("Component", () => {
38-
open ExpectJs;
38+
open Expect;
3939
4040
test("renders", () => {
41-
let component = ReactShallowRenderer.renderWithRenderer(<Component />);
42-
43-
expect(Js.Undefined.return(component)) |> toBeDefined;
41+
(
42+
<div style=ReactDOMRe.Style.make(~color="rebeccapurple", ())>
43+
<h1> {ReasonReact.string("Heading")} </h1>
44+
</div>
45+
)
46+
|> render
47+
|> expect
48+
|> toMatchSnapshot;
4449
});
4550
});
4651
```

0 commit comments

Comments
 (0)