diff --git a/db/schema.rb b/db/schema.rb index ac277ab39..58dc54b48 100644 --- a/db/schema.rb +++ b/db/schema.rb @@ -486,7 +486,6 @@ ActiveRecord::Schema[7.0].define(version: 2023_07_20_211851) do t.index ["exclude_article_ids"], name: "index_display_ads_on_exclude_article_ids", using: :gin t.index ["placement_area"], name: "index_display_ads_on_placement_area" t.index ["target_geolocations"], name: "gist_index_display_ads_on_target_geolocations", using: :gist - t.index ["target_geolocations"], name: "index_display_ads_on_target_geolocations" end create_table "email_authorizations", force: :cascade do |t| diff --git a/spec/queries/display_ads/filtered_ads_query_spec.rb b/spec/queries/display_ads/filtered_ads_query_spec.rb index c9e7e33ee..98bfeb276 100644 --- a/spec/queries/display_ads/filtered_ads_query_spec.rb +++ b/spec/queries/display_ads/filtered_ads_query_spec.rb @@ -151,6 +151,7 @@ RSpec.describe DisplayAds::FilteredAdsQuery, type: :query do let(:organization) { create(:organization) } let(:other_org) { create(:organization) } + let(:no_ads_org) { create(:organization) } let!(:community_ad) { create_display_ad organization_id: organization.id, type_of: :community } let!(:other_community) { create_display_ad organization_id: other_org.id, type_of: :community } @@ -162,7 +163,7 @@ RSpec.describe DisplayAds::FilteredAdsQuery, type: :query do expect(filtered).to contain_exactly(community_ad) expect(filtered).not_to include(other_community) - filtered = filter_ads organization_id: 123 + filtered = filter_ads organization_id: no_ads_org.id expect(filtered).to contain_exactly(in_house_ad) expect(filtered).not_to include(other_community)