Skip to content

Commit

Permalink
style: order imports
Browse files Browse the repository at this point in the history
Signed-off-by: rare-magma <[email protected]>
  • Loading branch information
rare-magma committed Sep 2, 2024
1 parent 8cc0c27 commit 9991bab
Show file tree
Hide file tree
Showing 13 changed files with 14 additions and 14 deletions.
2 changes: 1 addition & 1 deletion src/App.test.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@ import userEvent from "@testing-library/user-event";
import { describe, expect, it } from "vitest";
import { App } from "./App";
import { budgetsDB, calcHistDB, optionsDB } from "./db";
import { budgetContextSpy, testEmptyBudgetContext } from "./setupTests";
import { BudgetMother } from "./guitos/domain/budget.mother";
import { budgetContextSpy, testEmptyBudgetContext } from "./setupTests";

describe("App", () => {
const comp = <App />;
Expand Down
2 changes: 1 addition & 1 deletion src/components/Budget/BudgetPage.test.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ import { act } from "react-dom/test-utils";
import { BrowserRouter } from "react-router-dom";
import { describe, expect, it } from "vitest";
import { budgetsDB } from "../../db";
import { BudgetMother } from "../../guitos/domain/budget.mother";
import {
budgetContextSpy,
redoMock,
Expand All @@ -13,7 +14,6 @@ import {
undoMock,
} from "../../setupTests";
import { BudgetPage } from "./BudgetPage";
import { BudgetMother } from "../../guitos/domain/budget.mother";

describe("BudgetPage", () => {
const comp = (
Expand Down
2 changes: 1 addition & 1 deletion src/components/CalculateButton/CalculateButton.test.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@ import userEvent from "@testing-library/user-event";
import { BrowserRouter } from "react-router-dom";
import { vi } from "vitest";
import { describe, expect, it } from "vitest";
import { CalculateButton } from "./CalculateButton";
import { BudgetItemsMother } from "../../guitos/domain/budgetItem.mother";
import { CalculateButton } from "./CalculateButton";

describe("CalculateButton", () => {
const onCalculate = vi.fn();
Expand Down
2 changes: 1 addition & 1 deletion src/components/Chart/Chart.test.tsx
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import { render, screen } from "@testing-library/react";
import { vi } from "vitest";
import { afterEach, beforeEach, describe, expect, it } from "vitest";
import { Chart } from "./Chart";
import { BudgetMother } from "../../guitos/domain/budget.mother";
import { Chart } from "./Chart";

describe("Chart", () => {
const comp = (
Expand Down
4 changes: 2 additions & 2 deletions src/components/ItemForm/ItemFormGroup.test.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,14 @@ import userEvent from "@testing-library/user-event";
import { createRef } from "react";
import { BrowserRouter } from "react-router-dom";
import { describe, expect, it } from "vitest";
import { BudgetMother } from "../../guitos/domain/budget.mother";
import { BudgetItemsMother } from "../../guitos/domain/budgetItem.mother";
import {
configContextSpy,
setBudgetMock,
testSpanishConfigContext,
} from "../../setupTests";
import { ItemFormGroup } from "./ItemFormGroup";
import { BudgetMother } from "../../guitos/domain/budget.mother";
import { BudgetItemsMother } from "../../guitos/domain/budgetItem.mother";

describe("ItemFormGroup", () => {
const ref = createRef<HTMLInputElement>();
Expand Down
2 changes: 1 addition & 1 deletion src/components/LandingPage/LandingPage.test.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ import { render, screen } from "@testing-library/react";
import userEvent from "@testing-library/user-event";
import { BrowserRouter } from "react-router-dom";
import { beforeEach, describe, expect, it } from "vitest";
import { BudgetMother } from "../../guitos/domain/budget.mother";
import {
budgetContextSpy,
generalContextSpy,
Expand All @@ -10,7 +11,6 @@ import {
testGeneralContext,
} from "../../setupTests";
import { LandingPage } from "./LandingPage";
import { BudgetMother } from "../../guitos/domain/budget.mother";

describe("LandingPage", () => {
const comp = (
Expand Down
2 changes: 1 addition & 1 deletion src/components/NavBar/NavBar.test.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,13 @@ import { render, screen, waitFor } from "@testing-library/react";
import userEvent from "@testing-library/user-event";
import { BrowserRouter } from "react-router-dom";
import { describe, expect, it } from "vitest";
import { BudgetMother } from "../../guitos/domain/budget.mother";
import {
budgetContextSpy,
setBudgetMock,
testEmptyBudgetContext,
} from "../../setupTests";
import { NavBar } from "./NavBar";
import { BudgetMother } from "../../guitos/domain/budget.mother";

describe("NavBar", () => {
const comp = (
Expand Down
2 changes: 1 addition & 1 deletion src/components/StatCard/StatCard.test.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@ import { render, screen } from "@testing-library/react";
import userEvent from "@testing-library/user-event";
import { vi } from "vitest";
import { describe, expect, it } from "vitest";
import { BudgetMother } from "../../guitos/domain/budget.mother";
import { setBudgetMock } from "../../setupTests";
import { StatCard } from "./StatCard";
import { BudgetMother } from "../../guitos/domain/budget.mother";

describe("StatCard", () => {
const onShowGraphs = vi.fn();
Expand Down
2 changes: 1 addition & 1 deletion src/components/TableCard/TableCard.test.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@ import { cleanup, render, screen } from "@testing-library/react";
import userEvent from "@testing-library/user-event";
import { BrowserRouter } from "react-router-dom";
import { describe, expect, it } from "vitest";
import { BudgetMother } from "../../guitos/domain/budget.mother";
import { setBudgetMock } from "../../setupTests";
import TableCard from "./TableCard";
import { BudgetMother } from "../../guitos/domain/budget.mother";

describe("TableCard", () => {
const comp = (
Expand Down
2 changes: 1 addition & 1 deletion src/context/BudgetContext.test.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { render, screen } from "@testing-library/react";
import { describe, expect, it } from "vitest";
import { BudgetProvider, useBudget } from "./BudgetContext";
import { BudgetMother } from "../guitos/domain/budget.mother";
import { BudgetProvider, useBudget } from "./BudgetContext";

function TestComponent() {
const { budget, budgetList } = useBudget();
Expand Down
2 changes: 1 addition & 1 deletion src/guitos/domain/budget.mother.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { Budget } from "./budget";
import { BudgetItem } from "./budgetItem";
import { Uuid } from "./uuid";
import { Budget } from "./budget";

// biome-ignore lint/complexity/noStaticOnlyClass: <explanation>
export class BudgetMother {
Expand Down
2 changes: 1 addition & 1 deletion src/guitos/domain/budget.test.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import Big from "big.js";
import Papa from "papaparse";
import { expect, test, describe } from "vitest";
import { describe, expect, test } from "vitest";
import { Budget } from "./budget";
import { BudgetMother } from "./budget.mother";
import { BudgetItem } from "./budgetItem";
Expand Down
2 changes: 1 addition & 1 deletion src/utils.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ import Big from "big.js";
import { expect, test } from "vitest";
import type { FilteredItem } from "./components/ChartsPage/ChartsPage";
import type { Budget } from "./guitos/domain/budget";
import { BudgetMother } from "./guitos/domain/budget.mother";
import type { ItemOperation } from "./guitos/domain/calculationHistoryItem";
import { Uuid } from "./guitos/domain/uuid";
import { chromeLocalesList } from "./lists/chromeLocalesList";
Expand All @@ -21,7 +22,6 @@ import {
parseLocaleNumber,
roundBig,
} from "./utils";
import { BudgetMother } from "./guitos/domain/budget.mother";

test("round", () => {
expect(roundBig(Big(123.123123123), 5)).eq(123.12312);
Expand Down

0 comments on commit 9991bab

Please sign in to comment.