Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nodejs/node.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/tools
diff options
context:
space:
mode:
authorisaacs <i@izs.me>2010-09-09 05:42:32 +0400
committerRyan Dahl <ry@tinyclouds.org>2010-09-10 03:43:18 +0400
commit85fb47c11cc985889be9c1a802cfc0331d8ad7a8 (patch)
tree93c042b2676765239a43c1bdf574962ef9f44c83 /tools
parent7628905a9b9bb775cbcea91c1f6521bbd37549e7 (diff)
Better temporary directory handling for tests.
Add a setUp and tearDown function to the test case class, and use it to create and remove the test/tmp directory for each test. TODO: amend other tests.
Diffstat (limited to 'tools')
-rwxr-xr-xtools/test.py11
1 files changed, 10 insertions, 1 deletions
diff --git a/tools/test.py b/tools/test.py
index d05dac47327..518ecb7d491 100755
--- a/tools/test.py
+++ b/tools/test.py
@@ -359,7 +359,16 @@ class TestCase(object):
return TestOutput(self, full_command, output)
def Run(self):
- return self.RunCommand(self.GetCommand())
+ self.setUp()
+ result = self.RunCommand(self.GetCommand())
+ self.tearDown()
+ return result
+
+ def setUp(self):
+ return
+
+ def tearDown(self):
+ return
class TestOutput(object):