Skip to content

Commit

Permalink
Fix test
Browse files Browse the repository at this point in the history
  • Loading branch information
dgarcia360 committed Jan 5, 2024
1 parent aea9f33 commit f16ab58
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions tests/extensions/test_extensions_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,20 +19,23 @@ def test_generate_content():

def test_build_redirect_body():
path = "/redirect"
assert "url=/redirect" in build_redirect_body(path)
result = build_redirect_body(path)
assert "url=/redirect" in result
assert "zendesk" not in result


def test_build_redirect_body_with_zendesk_tag():
path = "/redirect"
zendesk_tag = "test-zendesk-tag"

# Call the function with a Zendesk tag
result = build_redirect_body(path, zendesk_tag)

# Check if the Zendesk meta tag is in the result
assert expected_zendesk_meta in result
assert zendesk_tag in result
assert "url=/redirect" in result


def test_is_url_external():
path = "https://scylladb.com"
assert is_url(path)
Expand Down

0 comments on commit f16ab58

Please sign in to comment.