Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
gitlab-ce
Commits
a3fbf344
Commit
a3fbf344
authored
Apr 28, 2015
by
Robert Speicher
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix header_should_have_correct_id_and_link for features
parent
fad01576
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
2 deletions
+6
-2
features/steps/shared/markdown.rb
features/steps/shared/markdown.rb
+6
-2
No files found.
features/steps/shared/markdown.rb
View file @
a3fbf344
...
...
@@ -2,8 +2,12 @@ module SharedMarkdown
include
Spinach
::
DSL
def
header_should_have_correct_id_and_link
(
level
,
text
,
id
,
parent
=
".wiki"
)
find
(
:css
,
"
#{
parent
}
h
#{
level
}
#
#{
id
}
"
).
text
.
should
==
text
find
(
:css
,
"
#{
parent
}
h
#{
level
}
#
#{
id
}
> :last-child"
)[
:href
].
should
=~
/#
#{
id
}
$/
node
=
find
(
"
#{
parent
}
h
#{
level
}
a#
#{
id
}
"
)
node
[
:href
].
should
==
"#
#{
id
}
"
# Work around a weird Capybara behavior where calling `parent` on a node
# returns the whole document, not the node's actual parent element
find
(
:xpath
,
"
#{
node
.
path
}
/.."
).
text
.
should
==
text
end
def
create_taskable
(
type
,
title
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment