aboutsummaryrefslogtreecommitdiff
path: root/tests/test_publish_to_snapshots.py
diff options
context:
space:
mode:
authorDanilo Segan <danilo@canonical.com>2012-08-22 21:07:48 +0200
committerDanilo Segan <danilo@canonical.com>2012-08-22 21:07:48 +0200
commit31f0d63d53a55f71e62de5d77117a37db497bd69 (patch)
treec949e42cc70283161ea066c9baf853c1519ab540 /tests/test_publish_to_snapshots.py
parent7c145cbced0e75c307fe0031dd1bc737f00f1a9d (diff)
Simplify the test as well.
Diffstat (limited to 'tests/test_publish_to_snapshots.py')
-rw-r--r--tests/test_publish_to_snapshots.py10
1 files changed, 3 insertions, 7 deletions
diff --git a/tests/test_publish_to_snapshots.py b/tests/test_publish_to_snapshots.py
index f6a23cb..82ffcfc 100644
--- a/tests/test_publish_to_snapshots.py
+++ b/tests/test_publish_to_snapshots.py
@@ -10,6 +10,7 @@ from testtools import TestCase
from scripts.publish_to_snapshots import (
PublisherArgumentException,
SnapshotsPublisher,
+ setup_parser,
)
@@ -21,13 +22,8 @@ class TestSnapshotsPublisher(TestCase):
orig_dir = os.getcwd()
def setUp(self):
- self.parser = argparse.ArgumentParser()
- self.parser.add_argument("-t", "--job-type", dest="job_type")
- self.parser.add_argument("-j", "--job-name", dest="job_name")
- self.parser.add_argument("-n", "--build-num", dest="build_num",
- type=int)
- self.parser.add_argument("-m", "--manifest", dest="manifest",
- action='store_true')
+ self.parser = setup_parser()
+
if not os.path.isdir(self.uploads_path):
os.mkdir(self.uploads_path)