Lines Matching refs:spam
1131 ('a', NS(spam='a')),
1132 ('g', NS(spam='g')),
1142 ('4', NS(spam=4)),
1143 ('15', NS(spam=15)),
1156 ('a b c', NS(spam=['a', ['b', 'c']])),
1466 ('foo', NS(x=None, spam=RFile('foo'))),
1467 ('-x foo bar', NS(x=RFile('foo'), spam=RFile('bar'))),
1468 ('bar -x foo', NS(x=RFile('foo'), spam=RFile('bar'))),
1469 ('-x - -', NS(x=sys.stdin, spam=sys.stdin)),
1470 ('readonly', NS(x=None, spam=RFile('readonly'))),
1506 ('foo', NS(x=None, spam=RFile('foo'))),
1507 ('-x foo bar', NS(x=RFile('foo'), spam=RFile('bar'))),
1508 ('bar -x foo', NS(x=RFile('foo'), spam=RFile('bar'))),
1509 ('-x - -', NS(x=sys.stdin, spam=sys.stdin)),
1548 ('foo', NS(x=None, spam=WFile('foo'))),
1549 ('-x foo bar', NS(x=WFile('foo'), spam=WFile('bar'))),
1550 ('bar -x foo', NS(x=WFile('foo'), spam=WFile('bar'))),
1551 ('-x - -', NS(x=sys.stdout, spam=sys.stdout)),
1563 ('foo', NS(x=None, spam=WFile('foo'))),
1564 ('-x foo bar', NS(x=WFile('foo'), spam=WFile('bar'))),
1565 ('bar -x foo', NS(x=WFile('foo'), spam=WFile('bar'))),
1566 ('-x - -', NS(x=sys.stdout, spam=sys.stdout)),
1579 ('--eggs=42 42', NS(eggs=42, spam=42.0)),
1580 ('--eggs 2j -- -1.5', NS(eggs=2j, spam=-1.5)),
1581 ('1024.675', NS(eggs=None, spam=1024.675)),
1604 ('a -x b', NS(x=MyType('b'), spam=MyType('a'))),
1605 ('-xf g', NS(x=MyType('f'), spam=MyType('g'))),
1628 ('a -x b', NS(x=C('b'), spam=C('a'))),
1629 ('-xf g', NS(x=C('f'), spam=C('g'))),
1668 expected_ns = NS(spam=0.25)
1694 expected_ns.spam = 0.25
1696 expected_ns.spam = 0.625
1698 expected_ns.spam = 0.125
1716 ('-s0.125', NS(spam=0.125, badger=2)),
1717 ('42', NS(spam=0.25, badger=42)),
1718 ('-s 0.625 1', NS(spam=0.625, badger=1)),
1719 ('84 -s2', NS(spam=2.0, badger=84)),
2439 ('--spam', NS(spam=True, badger=True, bladder=None)),
2440 ('--badger', NS(spam=False, badger=False, bladder=None)),
2441 ('--bladder B', NS(spam=False, badger=True, bladder='B')),
2442 ('--spam --spam', NS(spam=True, badger=True, bladder=None)),
2445 ('', NS(spam=False, badger=True, bladder=None)),
2476 ('--foo', NS(foo=True, spam=None, badger='X')),
2477 ('--spam S', NS(foo=False, spam='S', badger='X')),
2478 ('X', NS(foo=False, spam=None, badger=['X'])),
2479 ('X Y Z', NS(foo=False, spam=None, badger=['X', 'Y', 'Z'])),
2482 ('', NS(foo=False, spam=None, badger='X')),
4507 def spam(string): function
4511 parser.add_argument('x', type=spam)
4528 def spam(string_to_convert): function
4533 parser.add_argument('--foo', type=spam, default='bar')
4544 def spam(int_to_convert): function
4549 parser.add_argument('--foo', type=spam, default=0)
4555 def spam(int_to_convert): function
4559 parser.add_argument('--foo', type=spam, default='0')
4625 self.assertEqual(NS(v=3, spam=True, badger="B"), args)