mirror of
https://github.com/johndoe6345789/metabuilder.git
synced 2026-04-25 14:25:02 +00:00
code: tsx,nextjs,levelsclient (1 files)
This commit is contained in:
@@ -4,11 +4,11 @@ import LevelsClient from './LevelsClient'
|
||||
describe('LevelsClient', () => {
|
||||
it('renders permission levels and promotes to the next tier', () => {
|
||||
render(<LevelsClient />)
|
||||
expect(screen.getByText(/Level 1 · Guest/)).toBeInTheDocument()
|
||||
expect(screen.getByText(/Level 1 · Public/)).toBeInTheDocument()
|
||||
|
||||
const promoteButton = screen.getByRole('button', { name: /Promote to/ })
|
||||
fireEvent.click(promoteButton)
|
||||
|
||||
expect(screen.getByText(/Upgraded to Regular User/)).toBeInTheDocument()
|
||||
expect(screen.getByText(/Upgraded to User/)).toBeInTheDocument()
|
||||
})
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user