def setUp(self): self.config = PackageInstallOptions() self.capture = StringIO() self.stdout = sys.stdout sys.stdout = self.capture