Conversation
|
Gridiron Survivor Application
Project name: Gridiron Survivor Application
Only deployments on the production branch are activated automatically. If you'd like to activate this deployment, navigate to your deployments. Learn more about Appwrite Function deployments.
|
|
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
shashilo
left a comment
There was a problem hiding this comment.
For this, I'm expecting a unit test for each functional component. Even though Drawer brings them all in, each functional component should have its own isolated unit tests.
shashilo
left a comment
There was a problem hiding this comment.
If this component is called NavDrawer, why do have have all these drawer components inside of it? The only thing NavDrawer is the name.
| <DrawerClose> | ||
| <X /> | ||
| <DrawerClose data-testid="drawer-close"> | ||
| <X data-testid="drawer-close-icon" /> |
There was a problem hiding this comment.
BEM naming convention please.
| <X data-testid="drawer-close-icon" /> | |
| <X data-testid="drawer-close__icon" /> |
|
|
||
| describe('DrawerHeader Component', () => { | ||
| it('renders with default classes', () => { | ||
| render(<DrawerHeader data-testid="drawer-header" />); |
There was a problem hiding this comment.
We should not be manually setting data-testid's via test. These attributes should be part of the component.
| render(<DrawerHeader data-testid="drawer-header" />); | ||
|
|
||
| const header = screen.getByTestId('drawer-header'); | ||
| expect(header).toHaveClass( |
There was a problem hiding this comment.
No need to test the styles. E2E testing will cover this. Whenever we get it. Instead, test the default state and the props coming in to the component. Ensure they work as intended and change and intended.

Closes #223