generated from Arquisoft/lomap_0
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1 changed file
with
10 additions
and
3 deletions.
There are no files selected for viewing
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,11 +1,18 @@ | ||
import Contact from "../../components/mainPage/Contact"; | ||
import { render, act} from "@testing-library/react"; | ||
import Home from "../../components/mainPage/Home"; | ||
import { BrowserRouter } from "react-router-dom"; | ||
|
||
test('check home is rendered correctly', async () => { | ||
|
||
await act(async () => { | ||
const {container, getByText} = render(<Contact/>) | ||
expect(getByText("Contact us!")).toBeInTheDocument() | ||
const {container, getByText} = render( | ||
<BrowserRouter> | ||
<Home/> | ||
</BrowserRouter> | ||
|
||
) | ||
expect(getByText("Welcome to LoMap! With this application you will be able to select and share your favourite places around " + | ||
"the world with your friends. Take a sit, log in, and most importantly, have fun!!")).toBeInTheDocument() | ||
|
||
}); | ||
}) |