aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorGuido Günther <agx@sigxcpu.org>2011-12-24 14:16:49 +0100
committerGuido Günther <agx@sigxcpu.org>2011-12-26 14:02:29 +0100
commit4770a06ab765931286bc5ab6105c0d7dd6a86811 (patch)
tree1a99899257091c71b7b1cfd40fe17235a558feac
parent637b87a01a9bdc95c48a6edd85db196f9c4a95a9 (diff)
Rename gbp.pq to gbp.patch_series
since that's what it currently handles.
-rw-r--r--gbp/patch_series.py (renamed from gbp/pq.py)14
-rw-r--r--gbp/scripts/pq.py2
-rw-r--r--tests/08_test_patch.py2
3 files changed, 9 insertions, 9 deletions
diff --git a/gbp/pq.py b/gbp/patch_series.py
index ad9af576..0ab8bba7 100644
--- a/gbp/pq.py
+++ b/gbp/patch_series.py
@@ -46,7 +46,7 @@ class Patch(object):
self.long_desc = None
def __repr__(self):
- repr = "<gbp.pq.Patch path='%s' " % self.path
+ repr = "<gbp.patch_series.Patch path='%s' " % self.path
if self.topic:
repr += "topic='%s' " % self.topic
if self.strip != None:
@@ -183,12 +183,12 @@ class PatchSeries(list):
>>> PatchSeries._read_series(['a/b', \
'a -p1', \
'a/b -p2'], '.') # doctest:+NORMALIZE_WHITESPACE
- [<gbp.pq.Patch path='./a/b' topic='a' >,
- <gbp.pq.Patch path='./a' strip=1 >,
- <gbp.pq.Patch path='./a/b' topic='a' strip=2 >]
+ [<gbp.patch_series.Patch path='./a/b' topic='a' >,
+ <gbp.patch_series.Patch path='./a' strip=1 >,
+ <gbp.patch_series.Patch path='./a/b' topic='a' strip=2 >]
>>> PatchSeries._read_series(['# foo', 'a/b', '', '# bar'], '.')
- [<gbp.pq.Patch path='./a/b' topic='a' >]
+ [<gbp.patch_series.Patch path='./a/b' topic='a' >]
@param series: series of patches in quilt format
@type series: iterable of strings
@@ -251,9 +251,9 @@ class PatchSeries(list):
Parse a single line from a series file
>>> PatchSeries._parse_line("a/b -p1", '/tmp/patches')
- <gbp.pq.Patch path='/tmp/patches/a/b' topic='a' strip=1 >
+ <gbp.patch_series.Patch path='/tmp/patches/a/b' topic='a' strip=1 >
>>> PatchSeries._parse_line("a/b", '.')
- <gbp.pq.Patch path='./a/b' topic='a' >
+ <gbp.patch_series.Patch path='./a/b' topic='a' >
"""
line = line.rstrip()
topic = klass._get_topic(line)
diff --git a/gbp/scripts/pq.py b/gbp/scripts/pq.py
index 9cc2f0b5..78eb6a24 100644
--- a/gbp/scripts/pq.py
+++ b/gbp/scripts/pq.py
@@ -30,7 +30,7 @@ from gbp.command_wrappers import (Command, GitCommand, RunAtCommand,
CommandExecFailed)
from gbp.errors import GbpError
import gbp.log
-from gbp.pq import (PatchSeries, Patch)
+from gbp.patch_series import (PatchSeries, Patch)
PQ_BRANCH_PREFIX = "patch-queue/"
PATCH_DIR = "debian/patches/"
diff --git a/tests/08_test_patch.py b/tests/08_test_patch.py
index 8c25e04e..8735b16c 100644
--- a/tests/08_test_patch.py
+++ b/tests/08_test_patch.py
@@ -1,7 +1,7 @@
import os
import unittest
-from gbp.pq import Patch
+from gbp.patch_series import Patch
class TestPatch(unittest.TestCase):
data_dir = "tests/%s_data" % __module__