Skip to content

Commit

Permalink
Update test_backends_sqlalchemy.py
Browse files Browse the repository at this point in the history
  • Loading branch information
Dreamsorcerer authored Dec 24, 2023
1 parent 13e2dcf commit 53f4802
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions tests/test_backends_sqlalchemy.py
Original file line number Diff line number Diff line change
Expand Up @@ -44,8 +44,7 @@ class TestModel(base): # type: ignore[misc,valid-type]
assert r.name == "dummy"
assert r.primary_key == "id"
assert r.fields == {"id": comp("NumberField", {"source": "id"}),
"num": comp("TextField", {"source": "num", "fullWidth": True,
"multiline": True})}
"num": comp("TextField", {"source": "num", "fullWidth": True})}
# Autoincremented PK should not be in create form
assert r.inputs == {
"id": comp("NumberInput", {"source": "id", "validate": [func("required", ())]})
Expand Down Expand Up @@ -86,8 +85,7 @@ class TestModel(base): # type: ignore[misc,valid-type]

r = SAResource(mock_engine, TestModel)
assert r.fields["num"]["props"] == {
"source": "num", "fullWidth": True, "multiline": True, "placeholder": "Bar",
"helperText": "Foo"}
"source": "num", "fullWidth": True, "placeholder": "Bar", "helperText": "Foo"}
assert r.inputs["num"]["props"] == {
"source": "num", "fullWidth": True, "multiline": True, "placeholder": "Bar",
"helperText": "Foo", "validate": [func("maxLength", (128,))]}
Expand Down

0 comments on commit 53f4802

Please sign in to comment.