aboutsummaryrefslogtreecommitdiffstats
path: root/tests/test_section.py
diff options
context:
space:
mode:
authorSean Brant2013-03-13 22:23:50 -0500
committerSean Brant2013-03-13 22:23:50 -0500
commitc7d7aad2913d666a9ad09d74976bb90eff03acd1 (patch)
tree2085154feb77942ef8760f9c4eb4486cc24687f7 /tests/test_section.py
parent083e4dd9ed498ba2ef5133943fadb1fab7e71276 (diff)
downloadpykss-c7d7aad2913d666a9ad09d74976bb90eff03acd1.tar.bz2
Adds support for adding examples inside comments
Diffstat (limited to 'tests/test_section.py')
-rw-r--r--tests/test_section.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/tests/test_section.py b/tests/test_section.py
index 7ba8496..6ece110 100644
--- a/tests/test_section.py
+++ b/tests/test_section.py
@@ -16,6 +16,9 @@ Your standard form button.
.primary - Indicates button is the primary action.
.smaller - A smaller button
+Example:
+ <a href="button$modifier_class">Button</a>
+
Styleguide 2.1.1.
"""
self.section = Section(comment.strip(), 'example.css')
@@ -32,5 +35,8 @@ Styleguide 2.1.1.
def test_parses_modifier_descriptions(self):
self.assertEqual(self.section.modifiers[0].description, 'Highlights when hovering.')
+ def test_parses_the_example(self):
+ self.assertEqual(self.section.example, '<a href="button">Button</a>')
+
def test_parses_the_styleguide_reference(self):
self.assertEqual(self.section.section, '2.1.1')