Skip to content

Commit 8b50f56

Browse files
author
Jeffrey Na
committed
Cleaned up Login.test.tsx
1 parent b04163f commit 8b50f56

File tree

1 file changed

+0
-5
lines changed

1 file changed

+0
-5
lines changed

__tests__/components/Login.test.tsx

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -34,9 +34,6 @@ describe('Create Admin Page', () => {
3434
});
3535

3636
it('Login button should submit username and password to addUser', () => {
37-
const element = screen.getByTestId('Login');
38-
const inputs = element.querySelectorAll('input');
39-
4037
const usernameInput = screen.getByPlaceholderText('username');
4138
const passwordInput = screen.getByPlaceholderText('password');
4239
const loginButton = screen.getByRole('button', { name: /Login/i });
@@ -45,8 +42,6 @@ describe('Create Admin Page', () => {
4542
fireEvent.change(passwordInput, { target: { value: 'me123' } });
4643

4744
fireEvent.click(loginButton);
48-
// expect(ipcRenderer.sendSync).toHaveBeenCalled;
49-
// above passes test but below fails and says number of calls is zero
5045
expect(ipcRenderer.sendSync).toHaveBeenCalledWith('login', {
5146
username: 'St1nky',
5247
password: 'me123',

0 commit comments

Comments
 (0)