Skip to content

Commit

Permalink
Mover tests a carpeta tests
Browse files Browse the repository at this point in the history
  • Loading branch information
uo276026 committed Apr 9, 2024
1 parent b40a862 commit 69b10c7
Show file tree
Hide file tree
Showing 8 changed files with 8 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import React from 'react';
import { render, fireEvent, screen, waitFor } from '@testing-library/react';
import axios from 'axios';
import MockAdapter from 'axios-mock-adapter';
import AddUser from './AddUser';
import AddUser from '../AddUser';

const mockAxios = new MockAdapter(axios);

Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import React from 'react';
import { render, waitFor } from '@testing-library/react';
import axiosMock from 'axios';
import Estadisticas from './Estadisticas';
import Estadisticas from '../Pages/Estadisticas';

// Mock de datos para simular la respuesta del servidor
const mockUserData = {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import React from 'react';
import { render, fireEvent } from '@testing-library/react';
import Home from './Home';
import Home from '../Pages/Home';
import { BrowserRouter as Router } from "react-router-dom";

const mockNavigate = jest.fn();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import React from 'react';
import { render, fireEvent, waitFor } from '@testing-library/react';
import axios from 'axios';
import MockAdapter from 'axios-mock-adapter';
import Juego from './Juego';
import Juego from '../Pages/Juego';
import '@testing-library/jest-dom/extend-expect';
import { act } from 'react-dom/test-utils';

Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import React from 'react';
import { render, fireEvent } from '@testing-library/react';
import '@testing-library/jest-dom/extend-expect'; // Extiende las expectativas de Jest
import Layout from './Layout'; // Importa el componente a probar
import Layout from '../Pages/Layout'; // Importa el componente a probar
import { BrowserRouter as Router } from "react-router-dom";

describe('Layout component', () => {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import React from 'react';
import { render, fireEvent, screen, waitFor, act } from '@testing-library/react';
import axios from 'axios';
import MockAdapter from 'axios-mock-adapter';
import Login from './Login';
import Login from '../Login';
import userEvent from '@testing-library/user-event'

const mockAxios = new MockAdapter(axios);
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import React from 'react';
import { render, waitFor } from '@testing-library/react';
import '@testing-library/jest-dom/extend-expect';
import NotFound from './NotFound';
import NotFound from '../Pages/NotFound';
import { BrowserRouter as Router } from 'react-router-dom';

jest.useFakeTimers();
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import React from 'react';
import { render, screen, fireEvent, act } from '@testing-library/react';
import Temporizador from './Temporizador';
import Temporizador from '../Temporizador';

describe('Temporizador', () => {
it('renders the initial countdown time', () => {
Expand Down

0 comments on commit 69b10c7

Please sign in to comment.