summaryrefslogtreecommitdiff
path: root/subdir
diff options
context:
space:
mode:
authorLars Wirzenius <liw@iki.fi>2007-11-11 04:51:41 +0200
committerLars Wirzenius <liw@iki.fi>2007-11-11 04:51:41 +0200
commit80e2285c030eb53f0f39603c83fa064f52a4ad66 (patch)
tree6cad8bd0ed25d5afd323320944952670bc1a3ae3 /subdir
parentbcf2dd32320a1cfc82c85fcc872215a29fa4ec1c (diff)
downloadcoverage-test-runner-80e2285c030eb53f0f39603c83fa064f52a4ad66.tar.gz
Added sample files.
Diffstat (limited to 'subdir')
-rw-r--r--subdir/foo.py9
-rw-r--r--subdir/foo_tests.py11
2 files changed, 20 insertions, 0 deletions
diff --git a/subdir/foo.py b/subdir/foo.py
new file mode 100644
index 0000000..9059213
--- /dev/null
+++ b/subdir/foo.py
@@ -0,0 +1,9 @@
+class Foo:
+
+ def foo(self, a):
+ if a:
+ return True
+ else:
+ return False
+
+ \ No newline at end of file
diff --git a/subdir/foo_tests.py b/subdir/foo_tests.py
new file mode 100644
index 0000000..a8a9740
--- /dev/null
+++ b/subdir/foo_tests.py
@@ -0,0 +1,11 @@
+import unittest, foo
+
+class FooTests(unittest.TestCase):
+
+ def testTrue(self):
+ f = foo.Foo()
+ self.failUnlessEqual(f.foo(True), True)
+
+ def testFalse(self):
+ f = foo.Foo()
+ self.failUnlessEqual(f.foo(False), False)