mirror of
https://github.com/PaiGramTeam/sqlmodel.git
synced 2024-11-21 22:58:22 +00:00
support AnyURL
This commit is contained in:
parent
d13fb7435b
commit
c02b579f1b
@ -57,6 +57,7 @@ def test_nullable_fields(clear_sqlmodel, caplog):
|
||||
str_default_str_nullable: str = Field(default="default", nullable=True)
|
||||
str_default_ellipsis_non_nullable: str = Field(default=..., nullable=False)
|
||||
str_default_ellipsis_nullable: str = Field(default=..., nullable=True)
|
||||
base_url : AnyUrl
|
||||
optional_url: Optional[MoveSharedUrl] = Field(default=None, description="")
|
||||
url: MoveSharedUrl
|
||||
annotated_url: Annotated[MoveSharedUrl, Field(description="")]
|
||||
@ -93,6 +94,7 @@ def test_nullable_fields(clear_sqlmodel, caplog):
|
||||
assert "str_default_str_nullable VARCHAR," in create_table_log
|
||||
assert "str_default_ellipsis_non_nullable VARCHAR NOT NULL," in create_table_log
|
||||
assert "str_default_ellipsis_nullable VARCHAR," in create_table_log
|
||||
assert "base_url VARCHAR NOT NULL," in create_table_log
|
||||
assert "optional_url VARCHAR(512), " in create_table_log
|
||||
assert "url VARCHAR(512) NOT NULL," in create_table_log
|
||||
assert "annotated_url VARCHAR(512) NOT NULL," in create_table_log
|
||||
|
Loading…
Reference in New Issue
Block a user