1
Fork 0
mirror of https://github.com/Airsequel/AirGQL.git synced 2025-07-28 14:03:20 +03:00

Add tests for _by_pk queries

This commit is contained in:
prescientmoon 2024-11-15 14:34:36 +01:00
commit 768b711a6f
3 changed files with 860 additions and 721 deletions
source/AirGQL

View file

@ -738,7 +738,10 @@ lintTable allEntries parsed =
CreateTable names _ _
| Just name <- getFirstName (Just names)
, "_by_pk" `isInfixOf` name ->
pure "Table names cannot contain \"_by_pk\""
pure $
"Table names shouldn't contain \"_by_pk\", yet \""
<> name
<> "\" does"
_ -> []
in
rowidReferenceWarnings <> withoutRowidWarning <> illegalName