Add state search spec

This commit is contained in:
2025-10-07 22:53:24 -07:00
parent 7f82574b86
commit d0a517a3d4

View File

@@ -17,6 +17,11 @@ RSpec.describe "Api::V1::Parks", type: :request do
) )
end end
it "filters by state" do
get api_v1_parks_url, params: { state: "OR" }
expect(response.parsed_body.pluck("code")).to eq(["crla"])
end
context "with pagination" do context "with pagination" do
it "respects page size param" do it "respects page size param" do
get api_v1_parks_url, params: { per_page: 1 } get api_v1_parks_url, params: { per_page: 1 }