Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'spec/helpers/button_helper_spec.rb')
-rw-r--r--spec/helpers/button_helper_spec.rb7
1 files changed, 7 insertions, 0 deletions
diff --git a/spec/helpers/button_helper_spec.rb b/spec/helpers/button_helper_spec.rb
index ecb9c98b1bf..09495bbde35 100644
--- a/spec/helpers/button_helper_spec.rb
+++ b/spec/helpers/button_helper_spec.rb
@@ -171,6 +171,7 @@ RSpec.describe ButtonHelper do
expect(element.attr('data-placement')).to eq('bottom')
expect(element.attr('data-container')).to eq('body')
expect(element.attr('data-clipboard-text')).to eq(nil)
+ expect(element.attr('itemprop')).to eq(nil)
expect(element.inner_text).to eq("")
expect(element.to_html).to include sprite_icon('copy-to-clipboard')
@@ -209,5 +210,11 @@ RSpec.describe ButtonHelper do
expect(element(hide_button_icon: true).to_html).not_to include sprite_icon('duplicate')
end
end
+
+ context 'with `itemprop` attribute provided' do
+ it 'shows copy to clipboard button with `itemprop` attribute' do
+ expect(element(itemprop: "identifier").attr('itemprop')).to eq("identifier")
+ end
+ end
end
end