defnull / multipart

A fast multipart/form-data parser for python
https://multipart.readthedocs.io/
MIT License
135 stars 33 forks source link

test failure: d;e=f != d #37

Closed 0-wiz-0 closed 2 years ago

0-wiz-0 commented 3 years ago

I see one test failure with 0.2.4:

==================================================================================== test session starts ====================================================================================
platform netbsd9 -- Python 3.9.9, pytest-6.2.5, py-1.10.0, pluggy-0.13.1
rootdir: /scratch/www/py-multipart/work/multipart-0.2.4, configfile: setup.cfg, testpaths: test
collected 37 items                                                                                                                                                                          

test/test_multipart.py ................F....................                                                                                                                          [100%]

========================================================================================= FAILURES ==========================================================================================
______________________________________________________________________________ TestFormParser.test_urlencoded _______________________________________________________________________________

self = <test_multipart.TestFormParser testMethod=test_urlencoded>

    def test_urlencoded(self):
        for ctype in ('application/x-www-form-urlencoded', 'application/x-url-encoded'):
            self.env['CONTENT_TYPE'] = ctype
            forms, files = self.parse('a=b&c=d;e=f')
            self.assertEqual(forms['a'], 'b')
>           self.assertEqual(forms['c'], 'd')
E           AssertionError: 'd;e=f' != 'd'
E           - d;e=f
E           + d

test/test_multipart.py:238: AssertionError
================================================================================== short test summary info ==================================================================================
FAILED test/test_multipart.py::TestFormParser::test_urlencoded - AssertionError: 'd;e=f' != 'd'
=============================================================================== 1 failed, 36 passed in 0.16s ================================================================================
cjwatson commented 2 years ago

Fixed by #33.