• Home
  • Raw
  • Download

Lines Matching refs:ValueError

40         self.assertRaises(ValueError, float, "  0x3.1  ")
41 self.assertRaises(ValueError, float, " -0x3.p-1 ")
42 self.assertRaises(ValueError, float, " +0x3.p-1 ")
43 self.assertRaises(ValueError, float, "++3.14")
44 self.assertRaises(ValueError, float, "+-3.14")
45 self.assertRaises(ValueError, float, "-+3.14")
46 self.assertRaises(ValueError, float, "--3.14")
47 self.assertRaises(ValueError, float, ".nan")
48 self.assertRaises(ValueError, float, "+.inf")
49 self.assertRaises(ValueError, float, ".")
50 self.assertRaises(ValueError, float, "-.")
54 self.assertRaises(ValueError, float, '\uD8F0')
56 self.assertRaises(ValueError, float, "-1.7d29")
57 self.assertRaises(ValueError, float, "3D-14")
65 self.assertRaises(ValueError, float, '\u3053\u3093\u306b\u3061\u306f')
79 self.assertRaises(ValueError, float, lit)
83 self.assertRaises(ValueError, float, '_NaN')
84 self.assertRaises(ValueError, float, 'Na_N')
85 self.assertRaises(ValueError, float, 'IN_F')
86 self.assertRaises(ValueError, float, '-_INF')
87 self.assertRaises(ValueError, float, '-INF_')
89 self.assertRaises(ValueError, float, b'0_.\xff9')
117 with self.assertRaisesRegex(ValueError, "could not convert"):
129 with self.assertRaises(ValueError, msg='float(%r)' % (s,)) as cm:
168 self.assertRaises(ValueError, float, " 3,14 ")
169 self.assertRaises(ValueError, float, " +3,14 ")
170 self.assertRaises(ValueError, float, " -3,14 ")
171 self.assertRaises(ValueError, float, " 0x3.1 ")
172 self.assertRaises(ValueError, float, " -0x3.p-1 ")
173 self.assertRaises(ValueError, float, " +0x3.p-1 ")
285 self.assertRaises(ValueError, float('nan').as_integer_ratio)
328 self.assertRaises(ValueError, float("nan").__floor__)
342 self.assertRaises(ValueError, float("nan").__ceil__)
603 self.assertRaises(ValueError, float.__getformat__, 'chicken')
610 self.assertRaises(ValueError, float.__setformat__,
613 self.assertRaises(ValueError, float.__setformat__,
616 self.assertRaises(ValueError, float.__setformat__,
618 self.assertRaises(ValueError, float.__setformat__,
620 self.assertRaises(ValueError, float.__setformat__,
622 self.assertRaises(ValueError, float.__setformat__,
655 self.assertRaises(ValueError, struct.unpack, fmt, data)
662 self.assertRaises(ValueError, struct.unpack, fmt, data)
728 self.assertRaises(ValueError, format, 3.0, "s")
735 self.assertRaises(ValueError, format, 0.0, format_spec)
736 self.assertRaises(ValueError, format, 1.0, format_spec)
737 self.assertRaises(ValueError, format, -1.0, format_spec)
738 self.assertRaises(ValueError, format, 1e100, format_spec)
739 self.assertRaises(ValueError, format, -1e100, format_spec)
740 self.assertRaises(ValueError, format, 1e-100, format_spec)
741 self.assertRaises(ValueError, format, -1e-100, format_spec)
857 self.assertRaises(ValueError, round, NAN)
1000 self.assertRaises(ValueError, float, "info")
1001 self.assertRaises(ValueError, float, "+info")
1002 self.assertRaises(ValueError, float, "-info")
1003 self.assertRaises(ValueError, float, "in")
1004 self.assertRaises(ValueError, float, "+in")
1005 self.assertRaises(ValueError, float, "-in")
1006 self.assertRaises(ValueError, float, "infinit")
1007 self.assertRaises(ValueError, float, "+Infin")
1008 self.assertRaises(ValueError, float, "-INFI")
1009 self.assertRaises(ValueError, float, "infinitys")
1011 self.assertRaises(ValueError, float, "++Inf")
1012 self.assertRaises(ValueError, float, "-+inf")
1013 self.assertRaises(ValueError, float, "+-infinity")
1014 self.assertRaises(ValueError, float, "--Infinity")
1040 self.assertRaises(ValueError, float, "nana")
1041 self.assertRaises(ValueError, float, "+nana")
1042 self.assertRaises(ValueError, float, "-nana")
1043 self.assertRaises(ValueError, float, "na")
1044 self.assertRaises(ValueError, float, "+na")
1045 self.assertRaises(ValueError, float, "-na")
1047 self.assertRaises(ValueError, float, "++nan")
1048 self.assertRaises(ValueError, float, "-+NAN")
1049 self.assertRaises(ValueError, float, "+-NaN")
1050 self.assertRaises(ValueError, float, "--nAn")
1153 except ValueError: