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 Sep 23, 2024
1 parent 764988e commit 0f91012
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions tests/enums/test_enum.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,8 @@

import strawberry
from strawberry.exceptions import ObjectIsNotAnEnumError
from strawberry.types.enum import EnumDefinition

from strawberry.types.base import get_object_definition
from strawberry.types.enum import EnumDefinition


def test_basic_enum():
Expand Down Expand Up @@ -206,6 +205,7 @@ def foo(self, foo: Foo) -> int:
assert res.data
assert res.data["foo"] == 1


def test_default_enum_reuse() -> None:
class Foo(Enum):
BAR = "bar"
Expand All @@ -215,6 +215,6 @@ class Foo(Enum):
class SomeType:
foo: Foo
bar: Foo

definition = get_object_definition(SomeType, strict=True)
assert definition.fields[1].type is definition.fields[1].type
assert definition.fields[1].type is definition.fields[1].type

0 comments on commit 0f91012

Please sign in to comment.