Lines Matching refs:MyContext
4154 class MyContext(Context): class
4181 d = MyContext()
4187 self.assertRaises(ValueError, MyContext, **{'prec':-1})
4188 c = MyContext(prec=1)
4193 self.assertRaises(TypeError, MyContext, **{'rounding':'XYZ'})
4194 c = MyContext(rounding=ROUND_DOWN, prec=1)
4199 self.assertRaises(ValueError, MyContext, **{'Emin':5})
4200 c = MyContext(Emin=-1, prec=1)
4208 self.assertRaises(ValueError, MyContext, **{'Emax':-1})
4209 c = MyContext(Emax=1, prec=1)
4217 self.assertRaises(ValueError, MyContext, **{'capitals':-1})
4218 c = MyContext(capitals=0)
4224 self.assertRaises(ValueError, MyContext, **{'clamp':2})
4225 c = MyContext(clamp=1, Emax=99)
4231 self.assertRaises(TypeError, MyContext, **{'flags':'XYZ'})
4232 c = MyContext(flags=[Rounded, DivisionByZero])
4240 self.assertRaises(TypeError, MyContext, **{'traps':'XYZ'})
4241 c = MyContext(traps=[Rounded, DivisionByZero])