summaryrefslogtreecommitdiff
path: root/features/steps/snippets/public_snippets.rb
diff options
context:
space:
mode:
authorValery Sizov <valery@gitlab.com>2014-10-24 11:52:52 +0300
committerValery Sizov <valery@gitlab.com>2014-10-24 11:52:52 +0300
commit705652d62538ec29d125e0ec62bebc99ddc3af71 (patch)
treed93b9d990862b05eb72e8af73a4f6e7ecad60f89 /features/steps/snippets/public_snippets.rb
parentc6efa56ee7039882625942ce29ea9fdeeffaa6cd (diff)
downloadgitlab-ce-705652d62538ec29d125e0ec62bebc99ddc3af71.tar.gz
fix for public snippet
Diffstat (limited to 'features/steps/snippets/public_snippets.rb')
-rw-r--r--features/steps/snippets/public_snippets.rb17
1 files changed, 17 insertions, 0 deletions
diff --git a/features/steps/snippets/public_snippets.rb b/features/steps/snippets/public_snippets.rb
new file mode 100644
index 00000000000..956aa4a3e7e
--- /dev/null
+++ b/features/steps/snippets/public_snippets.rb
@@ -0,0 +1,17 @@
+class Spinach::Features::PublicSnippets < Spinach::FeatureSteps
+ include SharedAuthentication
+ include SharedPaths
+ include SharedSnippet
+
+ step 'I should see snippet "Personal snippet one"' do
+ page.should have_no_xpath("//i[@class='public-snippet']")
+ end
+
+ step 'I visit snippet page "Personal snippet one"' do
+ visit snippet_path(snippet)
+ end
+
+ def snippet
+ @snippet ||= PersonalSnippet.find_by!(title: "Personal snippet one")
+ end
+end