Created
October 2, 2011 03:46
-
-
Save torufurukawa/1257008 to your computer and use it in GitHub Desktop.
nonvirtualunittest.py を使う例
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import unittest | |
from nonvirtualunittest import TestCase | |
class BaseTestCase(TestCase): | |
def setUp(self): | |
self.foo = [1] | |
class MyTestCase(BaseTestCase): | |
def setUp(self): | |
self.foo.append(2) | |
def test(self): | |
self.foo.append(9) | |
self.assertEqual(len(self.foo), 3) # pass |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment