-
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
7 changed files
with
92 additions
and
1 deletion.
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
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 |
---|---|---|
@@ -0,0 +1,12 @@ | ||
import type { Page } from "@playwright/test"; | ||
import { SharedPage } from "./shared-page"; | ||
|
||
export class AboutPage extends SharedPage { | ||
constructor(page: Page, baseURL: string) { | ||
super(page, baseURL); | ||
} | ||
|
||
async goto() { | ||
await super.goto("/about"); | ||
} | ||
} |
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 |
---|---|---|
@@ -0,0 +1,9 @@ | ||
import { test, expect } from "../fixtures"; | ||
|
||
test.beforeEach(async ({ aboutPage }) => { | ||
await aboutPage.goto(); | ||
}); | ||
|
||
test("has title", async ({ page }) => { | ||
await expect(page).toHaveTitle("Gil Hanan | About Me"); | ||
}); |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
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 |
---|---|---|
@@ -0,0 +1,22 @@ | ||
import { render, screen } from "@testing-library/react"; | ||
import AboutPage, { metadata } from "./page"; | ||
|
||
describe("About", () => { | ||
it("should contain metadata", () => { | ||
expect(metadata.title).toBeTruthy(); | ||
}); | ||
|
||
it("should render title", () => { | ||
render(<AboutPage />); | ||
|
||
expect( | ||
screen.getByRole("heading", { name: "About Me" }), | ||
).toBeInTheDocument(); | ||
}); | ||
|
||
it("should render content", () => { | ||
const { container } = render(<AboutPage />); | ||
|
||
expect(container.querySelectorAll("p").length).toBeGreaterThan(0); | ||
}); | ||
}); |
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 |
---|---|---|
@@ -0,0 +1,43 @@ | ||
import type { Metadata } from "next"; | ||
import Image from "next/image"; | ||
import collage from "../../../public/images/collage.png"; | ||
|
||
export const metadata: Metadata = { | ||
title: "About Me", | ||
}; | ||
|
||
export default function AboutPage() { | ||
return ( | ||
<div className="mt-12 sm:mt-6"> | ||
<section> | ||
<h1 className="text-3xl text-primary text-center">About Me</h1> | ||
<div className="text-secondary"> | ||
<p className="mt-4"> | ||
My name is Gil Hanan and I'm a web developer at Microsoft with | ||
over 10 years of experience π¨βπ». <br /> Programming is my passion, | ||
and I discovered it when I developed bots to play games for me and | ||
level up my characters. I'm not sure if that's cheating or | ||
genius π€, but it was a lot of fun π₯³. | ||
</p> | ||
<p className="mt-4"> | ||
Although I have a roman with ChatGPT, I'm happily married π. | ||
In my spare time, I like to build wooden items π¨πͺ΅ and play ball | ||
games β½οΈπ, but I hate running πββοΈ. <br /> I love animals more than | ||
humans, and our home is somewhat of a zoo πΆπ±π¦π. | ||
</p> | ||
<p className="mt-4"> | ||
Recently, I've taken an interest in building open-source | ||
projects, and I created this portfolio website to showcase them πΌοΈ. | ||
<br /> I hope you enjoy them, and I would appreciate any feedback | ||
π¨. | ||
</p> | ||
</div> | ||
<Image | ||
src={collage} | ||
alt="My family" | ||
className="m-4 ml-0 rounded-md shadow-md w-[100%] sm:w-[300px]" | ||
/> | ||
</section> | ||
</div> | ||
); | ||
} |