POST /api/vendors
Put a new landscaper in the book with its agent's address, attached to Sunridge Villas and nowhere else.
Guards, 8
exactly-one-new-vendorone vendor row outside the five the fixture ships, not zero and not severalright-tenantthe vendor was written under Harbor Ridge's own org, which is the whole tenant boundary because RLS is on with no policiesnamed-and-activethe vendor carries the name that was asked for and is active in the bookagent-email-the-route-wrotean agent address is on the vendor and it is the lowercased form the route writes, so a row typed into the table with the prompt's capitals reads wrongagent-name-recordedthe agent's name is on the vendorattached-to-a-communitythe vendor is linked to at least one community; an unattached vendor is checked forever and reports unmatched every timeno-foreign-communityno community belonging to another organisation was linked; POST /api/vendors does no org check here and its own sibling action doesexactly-sunridgethe links are Sunridge Villas and nothing else
Cheats refused, 7
the-wrong-associationattaches the vendor to Cedar Hollow Townhomes insteadcaught by exactly-sunridgeno-association-at-allcreates the vendor with no community linkcaught by attached-to-a-communityanother-customers-communityattaches it to Lakemont Shores, which belongs to the other organisation, which the route acceptscaught by no-foreign-communitywritten-into-the-other-orgwrites the vendor under the second organisationcaught by right-tenantagent-email-as-the-prompt-typed-itkeeps the prompt's capitals, which no row that went through the route can carrycaught by agent-email-the-route-wroteno-agent-emailcreates the vendor with no agent address, so a chase has nowhere to gocaught by agent-email-the-route-wroteadded-twicecreates the vendor twicecaught by exactly-one-new-vendor