@@ -19,9 +19,9 @@ def get_tag_content(tags, tag_type, kind='property', prefix='og'):
19
19
return get_tag (tags , tag_type , kind , prefix ).get ('content' , '' )
20
20
21
21
22
- def get_tag_content_text (tags , tag_type , kind = " property" , prefix = "og" ):
22
+ def get_tag_content_text (tags , tag_type , kind = ' property' , prefix = 'og' ):
23
23
# Gets the content of a specific ogp tag
24
- return get_tag (tags , tag_type , kind , prefix ).get_text (" content" , "" )
24
+ return get_tag (tags , tag_type , kind , prefix ).get_text (' content' , '' )
25
25
26
26
27
27
def get_meta_description (tags ):
@@ -50,10 +50,10 @@ def test_meta_name_description(meta_tags):
50
50
assert description == og_description
51
51
52
52
53
- @pytest .mark .sphinx (" html" , testroot = " meta-name-description-escape" )
54
- def test_meta_name_description (meta_tags ):
55
- og_description = get_tag_content (meta_tags , " description" )
56
- og_description_text = get_tag_content_text (meta_tags , " description" )
53
+ @pytest .mark .sphinx (' html' , testroot = ' meta-name-description-escape' )
54
+ def test_meta_name_description_escape (meta_tags ):
55
+ og_description = get_tag_content (meta_tags , ' description' )
56
+ og_description_text = get_tag_content_text (meta_tags , ' description' )
57
57
58
58
assert '<' in og_description
59
59
assert '<' not in og_description_text
0 commit comments