Skip to content

OpenProject is the leading open source project management software for product, project and portfolio management. A powerful Jira alternative with agile planning, issue tracking, roadmaps, Gantt charts, time tracking, collaboration features, and more. Available on premises or in the cloud. ⭐ Star us on GitHub

Add test to validate that visible but not participated meetings are not included

Klaus Zandersafa2c2e2adfa
diff --git a/modules/meeting/spec/services/all_meetings/ical_service_spec.rb b/modules/meeting/spec/services/all_meetings/ical_service_spec.rb
index efc53ba842a..8f46ac62c80 100644
--- a/modules/meeting/spec/services/all_meetings/ical_service_spec.rb
+++ b/modules/meeting/spec/services/all_meetings/ical_service_spec.rb
@@ -100,8 +100,18 @@ RSpec.describe AllMeetings::ICalService, type: :model do # rubocop:disable RSpec
let!(:invisible_meeting) do
create(:meeting,
- author: user, # creatd by the user but in a project the user cannot see
- project: create(:project, name: "Invisible Project"),
+ author: user,
+ project: create(:project, name: "Invisible Project"), # in a project the user cannot see
+ title: "Important meeting",
+ location: "https://example.com/meet/important-meeting",
+ start_time: relevant_time + 1.week,
+ duration: 1.0)
+ end
+
+ let!(:not_invited_meeting) do
+ create(:meeting,
+ author: user,
+ project:,
title: "Important meeting",
location: "https://example.com/meet/important-meeting",
start_time: relevant_time + 1.week,