Skip to content

Instantly share code, notes, and snippets.

@kanzwataru
Last active August 30, 2018 00:03
Show Gist options
  • Select an option

  • Save kanzwataru/ab34b4972ce5403a6c2ac335b764e6d3 to your computer and use it in GitHub Desktop.

Select an option

Save kanzwataru/ab34b4972ce5403a6c2ac335b764e6d3 to your computer and use it in GitHub Desktop.
import unittest
class TestOrder(unittest.TestCase):
def setUp(self):
self.stuff = []
def test_01_create_stuff(self):
for n in xrange(20):
self.stuff.append(n)
self.assertEqual(len(self.stuff), 20)
def test_02_mult_stuff(self):
print(self.stuff)
double_stuff = [x * 2 for x in self.stuff]
self.assertEqual(len(double_stuff), 20)
if __name__ == '__main__':
unittest.main()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment