| 403 | assert obj.say_everything() == "B says hi 1 times 123" |
| 404 | |
| 405 | class DT(m.D_Tpl): |
| 406 | def say_something(self, times): |
| 407 | return "DT says:" + (" quack" * times) |
| 408 | |
| 409 | def unlucky_number(self): |
| 410 | return 1234 |
| 411 | |
| 412 | def lucky_number(self): |
| 413 | return -4.25 |
| 414 | |
| 415 | obj = DT() |
| 416 | assert obj.say_something(3) == "DT says: quack quack quack" |
no outgoing calls