Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

test_messages, maybe a mistake, maybe my error #82

Open
barendburger opened this issue Nov 10, 2023 · 0 comments
Open

test_messages, maybe a mistake, maybe my error #82

barendburger opened this issue Nov 10, 2023 · 0 comments

Comments

@barendburger
Copy link

Current block is:

def test_messages(client):
    """Ensure that user can post messages"""
    login(client, app.config["USERNAME"], app.config["PASSWORD"])
    rv = client.post(
        "/add",
        data=dict(title="<Hello>", text="<strong>HTML</strong> allowed here"),
        follow_redirects=True,
    )
    assert b"No entries here so far" not in rv.data
    assert b"&lt;Hello&gt;" in rv.data
    assert b"<strong>HTML</strong> allowed here" in rv.data

But this never passes the final test.

I replaced the first of the 3 asserts with
assert b"New entry was successfully posted" in rv.data

Which then passes

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant