Skip to content

Negative text return Positive sentiment bug #2

@theOther-Paul

Description

@theOther-Paul

While testing this API, I've encountered an error regarding long negative messages. The sentiment should be Negative, but it returns Positive. Below is the test that fails:

@pytest.mark.xfail(reason="Response should be negative", raises="Assertion Error", run=False)
def test_long_negative():
    text = "It's been a long time since I've had to write one of these, but here goes. I've been a client of this " \
           "particular video game for years now. I've stuck with it through all the changes, good and bad. I've seen " \
           "it grow and change, and I've always been happy with it. But now, I'm not so sure. The last few months have " \
           "been rough for this game. There have been more bugs and glitches than ever before, and the game has been " \
           "crashing constantly. The developers seem to be scrambling to fix things, but it's just not enough. And " \
           "then there are the changes to the gameplay itself. Some of them are good, but some of them are just " \
           "baffling. It feels like the developers are just throwing stuff at the wall to see what sticks, " \
           "and it's really starting to wear thin. I'm not sure how much longer I can keep playing this game. It's " \
           "just not what it used to be, and I'm not sure that it's worth my time anymore. "
    url = "http://127.0.0.1:5000?q={}".format(text)
    response = requests.request("GET", url, data=text)
    assert "Negative" in response.text
[Pytest Report at 2022.12.27_12.06.13.txt](https://github.com/msindev/Sentiment-Analysis-Flask-API/files/10307596/Pytest.Report.at.2022.12.27_12.06.13.txt)

This issue have been marked as an expected failure until the bug is solved.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions