diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2021-11-18 16:16:36 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2021-11-18 16:16:36 +0300 |
commit | 311b0269b4eb9839fa63f80c8d7a58f32b8138a0 (patch) | |
tree | 07e7870bca8aed6d61fdcc810731c50d2c40af47 /spec/features/explore | |
parent | 27909cef6c4170ed9205afa7426b8d3de47cbb0c (diff) |
Add latest changes from gitlab-org/gitlab@14-5-stable-eev14.5.0-rc42
Diffstat (limited to 'spec/features/explore')
-rw-r--r-- | spec/features/explore/topics_spec.rb | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/spec/features/explore/topics_spec.rb b/spec/features/explore/topics_spec.rb new file mode 100644 index 00000000000..9d2e76bc3a1 --- /dev/null +++ b/spec/features/explore/topics_spec.rb @@ -0,0 +1,25 @@ +# frozen_string_literal: true + +require 'spec_helper' + +RSpec.describe 'Explore Topics' do + context 'when no topics exist' do + it 'renders empty message', :aggregate_failures do + visit topics_explore_projects_path + + expect(current_path).to eq topics_explore_projects_path + expect(page).to have_content('There are no topics to show.') + end + end + + context 'when topics exist' do + let!(:topic) { create(:topic, name: 'topic1') } + + it 'renders topic list' do + visit topics_explore_projects_path + + expect(current_path).to eq topics_explore_projects_path + expect(page).to have_content('topic1') + end + end +end |