Skip to content

Commit

Permalink
[pre-commit.ci] auto fixes from pre-commit.com hooks
Browse files Browse the repository at this point in the history
for more information, see https://pre-commit.ci
  • Loading branch information
pre-commit-ci[bot] committed Mar 26, 2024
1 parent c2d2700 commit e4a74e3
Show file tree
Hide file tree
Showing 5 changed files with 13 additions and 37 deletions.
3 changes: 1 addition & 2 deletions src/pytest_rich/capture.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
import re
from datetime import datetime
from datetime import timezone
from datetime import datetime, timezone
from pathlib import Path
from typing import Tuple

Expand Down
3 changes: 1 addition & 2 deletions src/pytest_rich/header.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
import sys
from typing import Iterable
from typing import Union
from typing import Iterable, Union

import pytest
from _pytest.main import Session
Expand Down
14 changes: 3 additions & 11 deletions src/pytest_rich/terminal.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,24 +2,16 @@
import warnings
from collections import defaultdict
from pathlib import Path
from typing import Dict
from typing import List
from typing import Optional
from typing import Sequence
from typing import Tuple
from typing import Union
from typing import Dict, List, Optional, Sequence, Tuple, Union

import attr
import pytest
from _pytest._code.code import ExceptionChainRepr
from _pytest._code.code import ExceptionRepr
from _pytest._code.code import ExceptionChainRepr, ExceptionRepr
from rich.console import Console
from rich.live import Live
from rich.padding import Padding
from rich.panel import Panel
from rich.progress import Progress
from rich.progress import SpinnerColumn
from rich.progress import TaskID
from rich.progress import Progress, SpinnerColumn, TaskID
from rich.rule import Rule
from rich.table import Table
from rich.text import Text
Expand Down
27 changes: 7 additions & 20 deletions src/pytest_rich/traceback.py
Original file line number Diff line number Diff line change
@@ -1,34 +1,21 @@
import ast
import sys
from typing import Dict
from typing import Optional
from typing import Sequence
from typing import Dict, Optional, Sequence

import attr
from _pytest._code.code import ExceptionChainRepr
from _pytest._code.code import ReprEntry
from _pytest._code.code import ReprFileLocation
from _pytest._code.code import ReprFuncArgs
from pygments.token import Comment
from pygments.token import Keyword
from pygments.token import Name
from pygments.token import Number
from pygments.token import Operator
from pygments.token import String
from _pytest._code.code import (ExceptionChainRepr, ReprEntry,
ReprFileLocation, ReprFuncArgs)
from pygments.token import Comment, Keyword, Name, Number, Operator, String
from pygments.token import Text as TextToken
from pygments.token import Token
from rich._loop import loop_last
from rich.console import Console
from rich.console import ConsoleOptions
from rich.console import ConsoleRenderable
from rich.console import RenderResult
from rich.console import group
from rich.console import (Console, ConsoleOptions, ConsoleRenderable,
RenderResult, group)
from rich.highlighter import ReprHighlighter
from rich.panel import Panel
from rich.rule import Rule
from rich.style import Style
from rich.syntax import Syntax
from rich.syntax import SyntaxTheme
from rich.syntax import Syntax, SyntaxTheme
from rich.text import Text
from rich.theme import Theme
from rich.traceback import PathHighlighter
Expand Down
3 changes: 1 addition & 2 deletions tests/test_capture.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
from datetime import datetime
from datetime import timezone
from datetime import datetime, timezone

import pytest
from freezegun import freeze_time
Expand Down

0 comments on commit e4a74e3

Please sign in to comment.