Commit d7c84a84 authored by Martin Fahl's avatar Martin Fahl
Browse files

moves tests to __tests__ folder

parent 823b7331
import * as actions from "./addDialogActions" import * as actions from "../addDialogActions"
import * as types from "../constants/ActionTypes" import * as types from "../../constants/ActionTypes"
describe("addDialogActions", () => { describe("addDialogActions", () => {
it("should create an action to open the add dialog", () => { it("should create an action to open the add dialog", () => {
......
import * as actions from "./filterTermActions" import * as actions from "../filterTermActions"
import * as types from "../constants/ActionTypes" import * as types from "../../constants/ActionTypes"
describe("filterTermActions", () => { describe("filterTermActions", () => {
it("should create an action to update the filter", () => { it("should create an action to update the filter", () => {
......
import * as actions from "./itemsActions" import * as actions from "../itemsActions"
import * as types from "../constants/ActionTypes" import * as types from "../../constants/ActionTypes"
describe("itemsActions", () => { describe("itemsActions", () => {
it("should create an action to add an item locally", () => { it("should create an action to add an item locally", () => {
......
...@@ -2,8 +2,8 @@ import configureMockStore from "redux-mock-store" ...@@ -2,8 +2,8 @@ import configureMockStore from "redux-mock-store"
import thunk from "redux-thunk" import thunk from "redux-thunk"
import axios from "axios"; import axios from "axios";
import MockAdapter from "axios-mock-adapter"; import MockAdapter from "axios-mock-adapter";
import * as actions from "./itemsActions" import * as actions from "../itemsActions"
import * as types from "../constants/ActionTypes" import * as types from "../../constants/ActionTypes"
const middlewares = [thunk] const middlewares = [thunk]
const mockStore = configureMockStore(middlewares) const mockStore = configureMockStore(middlewares)
......
import React from "react"; import React from "react";
import CodecentricFooter from "./CodecentricFooter"; import CodecentricFooter from "../CodecentricFooter";
import renderer from "react-test-renderer"; import renderer from "react-test-renderer";
describe("CodecentricFooter", () => { describe("CodecentricFooter", () => {
......
import React from "react"; import React from "react";
import Filter from "./Filter"; import Filter from "../Filter";
import renderer from "react-test-renderer"; import renderer from "react-test-renderer";
import { shallow } from "enzyme"; import { shallow } from "enzyme";
......
import React from "react" import React from "react"
import InventoryList from "./InventoryList" import InventoryList from "../InventoryList"
import renderer from "react-test-renderer" import renderer from "react-test-renderer"
jest.mock("../Filter/Filter") jest.mock("../../Filter/Filter")
jest.mock("../../container/ItemContainer/ItemContainer") jest.mock("../../../container/ItemContainer/ItemContainer")
jest.mock("../../container/AddDialogContainer/AddDialogContainer") jest.mock("../../../container/AddDialogContainer/AddDialogContainer")
describe("InventoryList", () => { describe("InventoryList", () => {
it("should render as expected", () => { it("should render as expected", () => {
......
import React from 'react' import React from 'react'
import { shallow } from 'enzyme'; import { shallow } from 'enzyme';
import Item from './Item' import Item from '../Item'
import { ListItem, ListItemText, Typography, IconButton, Avatar } from '@material-ui/core'; import { ListItem, ListItemText, Typography, IconButton, Avatar } from '@material-ui/core';
import renderer from "react-test-renderer"; import renderer from "react-test-renderer";
......
import React from "react" import React from "react"
import Navbar from "./Navbar" import Navbar from "../Navbar"
import renderer from "react-test-renderer" import renderer from "react-test-renderer"
describe("Navbar", () => { describe("Navbar", () => {
......
import reducer from "./addDialog" import reducer from "../addDialog"
import * as types from "../constants/ActionTypes" import * as types from "../../constants/ActionTypes"
describe("addDialog reducer", () => { describe("addDialog reducer", () => {
it("should return the initial state", () => { it("should return the initial state", () => {
......
import reducer from "./filterTerm" import reducer from "../filterTerm"
import * as types from "../constants/ActionTypes" import * as types from "../../constants/ActionTypes"
describe("filterTerm reducer", () => { describe("filterTerm reducer", () => {
it("should return the initial state", () => { it("should return the initial state", () => {
......
import reducer from "./items" import reducer from "../items"
import * as types from "../constants/ActionTypes" import * as types from "../../constants/ActionTypes"
describe("items reducer", () => { describe("items reducer", () => {
it("should return the initial state", () => { it("should return the initial state", () => {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment