summaryrefslogtreecommitdiff
path: root/spec/features
diff options
context:
space:
mode:
authorZeger-Jan van de Weg <git@zjvandeweg.nl>2017-10-03 13:25:41 +0200
committerZeger-Jan van de Weg <git@zjvandeweg.nl>2017-10-03 13:25:41 +0200
commit6a40c21675848ae9ef9afd28b1eabc241994a6f4 (patch)
tree473f2cc1d5453e8aa8660276c0d28f2b92ec3e75 /spec/features
parentdfd9185da10314cdb57081b93a9245b6a8637198 (diff)
downloadgitlab-ce-6a40c21675848ae9ef9afd28b1eabc241994a6f4.tar.gz
Update tests for new implementation
Diffstat (limited to 'spec/features')
-rw-r--r--spec/features/projects/artifacts/browse_spec.rb9
1 files changed, 3 insertions, 6 deletions
diff --git a/spec/features/projects/artifacts/browse_spec.rb b/spec/features/projects/artifacts/browse_spec.rb
index 40af0247bce..1bfdf3c2727 100644
--- a/spec/features/projects/artifacts/browse_spec.rb
+++ b/spec/features/projects/artifacts/browse_spec.rb
@@ -1,8 +1,6 @@
require 'spec_helper'
feature 'Browse artifact', :js do
- include ArtifactHelper
-
let(:project) { create(:project, :public) }
let(:pipeline) { create(:ci_empty_pipeline, project: project) }
let(:job) { create(:ci_build, :artifacts, pipeline: pipeline) }
@@ -24,8 +22,8 @@ feature 'Browse artifact', :js do
end
end
- context 'when browsing a directory with an HTML file' do
- let(:html_entry) { job.artifacts_metadata_entry("other_artifacts_0.1.2/index.html") }
+ context 'when browsing a directory with an text file' do
+ let(:txt_entry) { job.artifacts_metadata_entry('other_artifacts_0.1.2/doc_sample.txt') }
before do
allow(Gitlab.config.pages).to receive(:enabled).and_return(true)
@@ -37,8 +35,7 @@ feature 'Browse artifact', :js do
it "shows external link icon and styles" do
link = first('.tree-item-file-external-link')
- expect(link).to have_content('index.html')
- expect(link[:href]).to eq(html_artifact_url(project, job, html_entry.blob))
+ expect(link).to have_content('doc_sample.txt')
expect(page).to have_selector('.js-artifact-tree-external-icon')
end
end