From 7c828b4cd299f91e4d6d996fa5d630ff5e13e8a0 Mon Sep 17 00:00:00 2001 From: Bilal Date: Tue, 25 Aug 2020 11:33:49 +0300 Subject: [PATCH] add spec --- spec/features/user_managing_broadcasts_spec.rb | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/spec/features/user_managing_broadcasts_spec.rb b/spec/features/user_managing_broadcasts_spec.rb index 9c40b71..3146d66 100644 --- a/spec/features/user_managing_broadcasts_spec.rb +++ b/spec/features/user_managing_broadcasts_spec.rb @@ -223,6 +223,18 @@ feature 'User managing broadcasts' do expect(page).to have_content("Recording of the live stream will appear here") end + scenario 'Broadcast recording preview thumbnail is shown' do + broadcast = create(:broadcast, :with_stream, :with_files, project: project) + recording = create(:broadcast_recording, broadcast: broadcast, asset_uid: "another_asset_uid") + + visit project_broadcast_path(project, broadcast) + + click_on 'Previous Sessions' + + expect(page).to have_css('img.img-thumbnail') + expect(page.find('img.img-thumbnail')['src']).to match recording.asset_playback_uid + end + context 'When the user is associate' do let(:current_user) { create(:user, :associate) }