~launchpad-pqm/launchpad/devel

« back to all changes in this revision

Viewing changes to lib/lp/testing/matchers.py

  • Committer: Launchpad Patch Queue Manager
  • Date: 2010-08-25 12:36:38 UTC
  • mfrom: (11407.3.2 testtools-0.9.6)
  • Revision ID: launchpad@pqm.canonical.com-20100825123638-gsbyehsy7nnk2d7y
[r=thumper][ui=none][no-qa] Upgrade to testtools 0.9.6.

Show diffs side-by-side

added added

removed removed

Lines of Context:
15
15
    ]
16
16
 
17
17
from testtools.content import Content
18
 
from testtools.content_type import ContentType
 
18
from testtools.content_type import UTF8_TEXT
19
19
from testtools.matchers import (
20
20
    Matcher,
21
21
    Mismatch,
137
137
        result = []
138
138
        for query in self.query_collector.queries:
139
139
            result.append(unicode(query).encode('utf8'))
140
 
        return {'queries': Content(ContentType('text', 'plain',
141
 
            {'charset': 'utf8'}), lambda:['\n'.join(result)])}
 
140
        return {'queries': Content(UTF8_TEXT, lambda:['\n'.join(result)])}
142
141
 
143
142
 
144
143
class IsNotProxied(Mismatch):