From cc55a1ba1479e2897a819916c28fd050f7a9fea2 Mon Sep 17 00:00:00 2001 From: Stefan Wojcik Date: Wed, 28 Sep 2016 18:19:49 -0400 Subject: extra test based on RFC 7231 page 38 --- mimeparse.py | 1 - testdata.json | 8 ++++++++ 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/mimeparse.py b/mimeparse.py index 0c09729..897b2df 100644 --- a/mimeparse.py +++ b/mimeparse.py @@ -1,5 +1,4 @@ import cgi -from functools import reduce __version__ = '1.5.2' __author__ = 'Joe Gregorio' diff --git a/testdata.json b/testdata.json index 7e591be..cd655c8 100644 --- a/testdata.json +++ b/testdata.json @@ -149,6 +149,14 @@ "application/rdf+xml", "match should use highest order of supported when there is a tie" ], + [ + [ + ["text/plain", "text/plain;format=flowed", "text/html"], + "text/*, text/plain, text/plain;format=flowed, */*" + ], + "text/plain;format=flowed", + "most specific reference has precedence" + ], [ [ ["application/rdf+xml", "text/html"], -- cgit v1.2.1