File: test_misc.pyc

package info (click to toggle)
python-webob 1.4-2
  • links: PTS, VCS
  • area: main
  • in suites: jessie, jessie-kfreebsd
  • size: 3,340 kB
  • ctags: 2,468
  • sloc: python: 13,433; makefile: 12
file content (53 lines) | stat: -rw-r--r-- 4,946 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53

bMQc@sddkZddklZddklZddklZlZddk	l
Z
lZdZde
fdYZd	e
fd
YZde
fdYZd
e
fdYZdZdZdS(iN(thtml_escape(t	MultiDict(teq_t
assert_raises(ttext_tPY3c
Csto
d}nd}xdddtdd	ftd
dfdtd
fdtd|ftdftdftdfgD]\}}tt	||qWdS(Nsexpected a &#x27;&lt;&#x27;.sexpected a '&lt;'.sthese chars: < > & "s#these chars: &lt; &gt; &amp; &quot;t s&egrave;s&amp;egrave;sthe majestic mosesthe majestic m&#248;osess&#233;ts<div>hello</div>i*t42sexpected a '<'.s
m&#248;oses&lt;UnsafeAttrs&gt;(sthese chars: < > & "s#these chars: &lt; &gt; &amp; &quot;(RR(s&egrave;s&amp;egrave;(NR(i*s42(
RRtNonet
t_esc_HTMLt	Exceptiontt_esc_SuperMooset
t_esc_Unicodett_esc_UnsafeAttrsteqR(tEXPECTED_LTtvts((s./home/chrism/projects/webob/tests/test_misc.pyttest_html_escape
s$
R
cBseZdZRS(cCsdS(Ns<div>hello</div>((tself((s./home/chrism/projects/webob/tests/test_misc.pyt__html__1s(t__name__t
__module__R(((s./home/chrism/projects/webob/tests/test_misc.pyR
0sR
cBseZdZRS(cCs
tdS(Ns(R(R((s./home/chrism/projects/webob/tests/test_misc.pyt__unicode__6s(RRR(((s./home/chrism/projects/webob/tests/test_misc.pyR
5sRcBs eZdZdZdZRS(tvaluecCs|iS(N(tattr(Rtk((s./home/chrism/projects/webob/tests/test_misc.pyt__getattr__;scCsdS(Ns
<UnsafeAttrs>((R((s./home/chrism/projects/webob/tests/test_misc.pyt__repr__=s(RRRRR(((s./home/chrism/projects/webob/tests/test_misc.pyR9s	RcBseZdZdZRS(cCstdidS(Nsmosesutf-8(Rtencode(R((s./home/chrism/projects/webob/tests/test_misc.pyt__str__AscCs
tdS(Nsmose(R(R((s./home/chrism/projects/webob/tests/test_misc.pyRCs(RRRR(((s./home/chrism/projects/webob/tests/test_misc.pyR@s	cCstdddd}t|ddt|idg|iddt|ddt|idddgd|d<t|iddgtt|idddgtt|idddgt|ihddgd6dd6tt	|i
dt|i
ddtt	|i
dt|ihddgd6dgd6d|jptd|jpt|i
d|jptd|d<|idd	|i}d|jpt|i
d
|d<|i|t|tdddg|id}t|dt|dd	t|idd
d
tt	|idtt|iddd
|idgidt|tddddgfgdS(Ntaitbitcitgteii*tftni(R i(R i(R!i(R i(R i(R%i*(R i(R%i*(RRtgetalltaddtlisttkeystitemstmixedRtKeyErrortgetonet
dict_of_liststAssertionErrortcleartcopytupdatetpopt	TypeErrort
setdefaulttappend(tdR$R%((s./home/chrism/projects/webob/tests/test_misc.pyttest_multidictKsF
""'*





cCsqtdgdd}tt|dt|td	gddtttdddtttiddS(
NR R!R"is!MultiDict([('a', 'b'), ('c', 2)])ii(R R!(R R!(RRtreprRR5t	view_listR	(R8((s./home/chrism/projects/webob/tests/test_misc.pyttest_multidict_init}s
(tcgit
webob.utilRtwebob.multidictRt
nose.toolsRRRtwebob.compatRRRtobjectR
R
RRR9R<(((s./home/chrism/projects/webob/tests/test_misc.pyt<module>s	&	2