Event model improvements

- Drop selected_event_schedule function
- Rename scheduled_room and scheduled_start_time to room and time as if there is no selected_schedule, the event is not scheduled.
This commit is contained in:
Ana 2016-08-01 21:25:12 +02:00
parent 5001848af7
commit a578167cf5
13 changed files with 32 additions and 35 deletions

View file

@ -16,8 +16,8 @@ describe SchedulesController do
it 'assigns variables' do
expect(assigns(:conference)).to eq conference
expect(assigns(:events_xml)).to eq conference.selected_event_schedules.map(&:event)
.group_by{ |event| event.scheduled_start_time.to_date }
expect(assigns(:events_xml)).to eq conference.program.selected_event_schedules.map(&:event)
.group_by{ |event| event.time.to_date }
end
it 'renders successfully' do