launchpad-reviewers team mailing list archive
-
launchpad-reviewers team
-
Mailing list archive
-
Message #23514
[Merge] lp:~cjwatson/launchpad/fix-test-db-assumptions into lp:launchpad
Colin Watson has proposed merging lp:~cjwatson/launchpad/fix-test-db-assumptions into lp:launchpad.
Commit message:
Weaken some test assertions that failed on PostgreSQL 10.
Requested reviews:
Launchpad code reviewers (launchpad-reviewers)
For more details, see:
https://code.launchpad.net/~cjwatson/launchpad/fix-test-db-assumptions/+merge/366100
For some reason I see these locally but not on buildbot. However, they do look like incorrect test code.
I'm not wholly convinced by the xx-private-builds.txt change, since the "5 of 3 results" I see locally is clearly dodgy; but on the other hand the exact number of rows in EXPLAIN output doesn't seem like something we should be asserting in tests.
--
Your team Launchpad code reviewers is requested to review the proposed merge of lp:~cjwatson/launchpad/fix-test-db-assumptions into lp:launchpad.
=== modified file 'lib/lp/code/stories/webservice/xx-branch.txt'
--- lib/lp/code/stories/webservice/xx-branch.txt 2018-05-13 10:35:52 +0000
+++ lib/lp/code/stories/webservice/xx-branch.txt 2019-04-16 11:00:11 +0000
@@ -186,18 +186,21 @@
The branches of a project are also available.
+ >>> from operator import itemgetter
+
>>> def print_branch(branch):
... print(branch['unique_name'] + ' - ' + branch['lifecycle_status'])
>>> def print_branches(webservice, url, status=None, modified_since=None):
... branches = webservice.named_get(
... url, 'getBranches',
... status=status, modified_since=modified_since).jsonBody()
- ... for branch in branches['entries']:
+ ... for branch in sorted(
+ ... branches['entries'], key=itemgetter('unique_name')):
... print_branch(branch)
>>> print_branches(webservice, '/fooix')
+ ~eric/fooix/feature-branch - Experimental
~eric/fooix/trunk - Development
- ~eric/fooix/feature-branch - Experimental
The branches can be limited to those that have been modified since a specified
time.
@@ -217,8 +220,8 @@
The branches owned by a person are available from the person object.
>>> print_branches(webservice, '/~eric')
+ ~eric/fooix/feature-branch - Experimental
~eric/fooix/trunk - Development
- ~eric/fooix/feature-branch - Experimental
As with projects, these can be filtered by the branch status.
@@ -239,8 +242,8 @@
>>> logout()
>>> print_branches(webservice, '/widgets')
+ ~eric/fooix/feature-branch - Experimental
~eric/fooix/trunk - Development
- ~eric/fooix/feature-branch - Experimental
~mary/blob/bar - Development
As with projects, these can be filtered by the branch status.
=== modified file 'lib/lp/soyuz/stories/soyuz/xx-private-builds.txt'
--- lib/lp/soyuz/stories/soyuz/xx-private-builds.txt 2018-06-30 21:31:02 +0000
+++ lib/lp/soyuz/stories/soyuz/xx-private-builds.txt 2019-04-16 11:00:11 +0000
@@ -152,7 +152,7 @@
...
i386 build of cdrkit 1.0 in ubuntu warty RELEASE
...
- 5 of 17 results
+ 5 of ... results
...
Follow ups