diff --git a/webapp/package.json b/webapp/package.json index 2bbe828..b0cb0fd 100644 --- a/webapp/package.json +++ b/webapp/package.json @@ -2,7 +2,6 @@ "name": "webapp", "version": "0.1.0", "private": true, - "type": "module", "dependencies": { "@greatsumini/react-facebook-login": "^3.3.3", "@react-oauth/google": "^0.11.1", diff --git a/webapp/src/Todo.js b/webapp/src/Todo.js index bb477cb..4035bff 100644 --- a/webapp/src/Todo.js +++ b/webapp/src/Todo.js @@ -1,7 +1,7 @@ import React, { useEffect, useState } from "react"; import FloatingLabel from 'react-bootstrap/FloatingLabel'; import Form from 'react-bootstrap/Form'; - +import { Link } from "react-router-dom"; import Button from 'react-bootstrap/Button'; import Spinner from 'react-bootstrap/Spinner'; import Alert from 'react-bootstrap/Alert'; @@ -60,9 +60,9 @@ export default function Todo() {
- + Forgot your password? - +
{feedBack && setFeedback("") } variant="danger" className=" text-center" dismissible >{feedBack} } @@ -101,7 +101,7 @@ export default function Todo() {

- If you haven't registered yet? Register now + If you haven't registered yet? Register now

diff --git a/webapp/src/__tests__/Login.test.js b/webapp/src/__tests__/Login.test.js index f2a3c9a..086c399 100644 --- a/webapp/src/__tests__/Login.test.js +++ b/webapp/src/__tests__/Login.test.js @@ -1,3 +1,13 @@ -test('Login test ', () => { - expect(true).toBe(true) -}) +import { render, screen } from '@testing-library/react'; +import Todo from '../Todo'; +import { MemoryRouter } from 'react-router-dom'; + +test('renders learn react link', () => { + render( + + + + ); +// const linkElement = screen.getByText(/learn react/i); +// expect(linkElement).toBeInTheDocument(); +}); diff --git a/webapp/src/__tests__/ProgressChart.test.js b/webapp/src/__tests__/ProgressChart.test.js new file mode 100644 index 0000000..4baa4ab --- /dev/null +++ b/webapp/src/__tests__/ProgressChart.test.js @@ -0,0 +1,3 @@ +test('ProgressChart component renders withput crashing', () => { + expect(true).toBe(true) +}) diff --git a/webapp/src/__tests__/Todo.test.js b/webapp/src/__tests__/Todo.test.js deleted file mode 100644 index 267cebc..0000000 --- a/webapp/src/__tests__/Todo.test.js +++ /dev/null @@ -1,8 +0,0 @@ -import { render, screen } from '@testing-library/react'; -import Todo from '../Todo'; - -test('renders learn react link', () => { - render(); -// const linkElement = screen.getByText(/learn react/i); -// expect(linkElement).toBeInTheDocument(); -}); diff --git a/webapp/src/__tests__/Topic.test.js b/webapp/src/__tests__/Topic.test.js new file mode 100644 index 0000000..0f402d2 --- /dev/null +++ b/webapp/src/__tests__/Topic.test.js @@ -0,0 +1,3 @@ +test('Topic component renders withput crashing', () => { + expect(true).toBe(true) +})