Skip to content
Snippets Groups Projects
Commit 5935dd14 authored by VIktorGrev's avatar VIktorGrev
Browse files

fix: Fixing newscomponent

parent dfb74388
Branches feature/userprofile-for-foreign-users
No related tags found
1 merge request!44Fix/pipeline
...@@ -68,13 +68,14 @@ describe('Menu and Router Tests', () => { ...@@ -68,13 +68,14 @@ describe('Menu and Router Tests', () => {
describe('Input fields', () => { describe('Input fields', () => {
it('updates user credetials correctly', async () => { it('updates user credentials correctly', async () => {
const { getByPlaceholderText } = render(MyComponent); const { getByPlaceholderText } = render(MyComponent);
const firstInput = getByPlaceholderText('Enter your first name'); const firstInput = getByPlaceholderText('Enter your first name') as HTMLInputElement;
const lastInput = getByPlaceholderText('Enter your surname'); const lastInput = getByPlaceholderText('Enter your surname') as HTMLInputElement;
const emailInput = getByPlaceholderText('Enter your email'); const emailInput = getByPlaceholderText('Enter your email') as HTMLInputElement;
const passwordInput = getByPlaceholderText('Enter password'); const passwordInput = getByPlaceholderText('Enter password') as HTMLInputElement;
await fireEvent.update(firstInput, 'Alice'); await fireEvent.update(firstInput, 'Alice');
await fireEvent.update(lastInput, 'Alicon'); await fireEvent.update(lastInput, 'Alicon');
await fireEvent.update(emailInput, 'user@example.com'); await fireEvent.update(emailInput, 'user@example.com');
...@@ -86,6 +87,7 @@ describe('Menu and Router Tests', () => { ...@@ -86,6 +87,7 @@ describe('Menu and Router Tests', () => {
expect(passwordInput.value).toBe('Password1'); expect(passwordInput.value).toBe('Password1');
}); });
it('Password error msg', async () => { it('Password error msg', async () => {
const { container } = render(MyComponent, { const { container } = render(MyComponent, {
global: { global: {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment