Merge lp:~stevenk/launchpad/drop-populate-branch-aag into lp:launchpad
- drop-populate-branch-aag
- Merge into devel
Proposed by
Steve Kowalik
Status: | Merged |
---|---|
Approved by: | William Grant |
Approved revision: | no longer in the source branch. |
Merged at revision: | 15557 |
Proposed branch: | lp:~stevenk/launchpad/drop-populate-branch-aag |
Merge into: | lp:launchpad |
Diff against target: |
221 lines (+13/-91) 5 files modified
database/sampledata/current-dev.sql (+6/-2) database/sampledata/current.sql (+6/-2) database/schema/security.cfg (+0/-2) lib/lp/scripts/garbo.py (+0/-47) lib/lp/scripts/tests/test_garbo.py (+1/-38) |
To merge this branch: | bzr merge lp:~stevenk/launchpad/drop-populate-branch-aag |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
William Grant | code | Approve | |
Review via email: mp+113467@code.launchpad.net |
Commit message
Delete the PopulateBranchA
Description of the change
Thank PopulateBranchA
To post a comment you must log in.
Revision history for this message
William Grant (wgrant) : | # |
review:
Approve
(code)
Preview Diff
[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1 | === modified file 'database/sampledata/current-dev.sql' | |||
2 | --- database/sampledata/current-dev.sql 2012-06-27 09:45:26 +0000 | |||
3 | +++ database/sampledata/current-dev.sql 2012-07-04 22:47:20 +0000 | |||
4 | @@ -1787,6 +1787,8 @@ | |||
5 | 1787 | 1787 | ||
6 | 1788 | INSERT INTO accessartifactgrant (artifact, grantee, grantor, date_created) VALUES (1, 14, 65, '2007-08-09 11:39:16.836856'); | 1788 | INSERT INTO accessartifactgrant (artifact, grantee, grantor, date_created) VALUES (1, 14, 65, '2007-08-09 11:39:16.836856'); |
7 | 1789 | INSERT INTO accessartifactgrant (artifact, grantee, grantor, date_created) VALUES (1, 63, 65, '2007-08-09 11:39:16.836856'); | 1789 | INSERT INTO accessartifactgrant (artifact, grantee, grantor, date_created) VALUES (1, 63, 65, '2007-08-09 11:39:16.836856'); |
8 | 1790 | INSERT INTO accessartifactgrant (artifact, grantee, grantor, date_created) VALUES (2, 64, 64, '2012-07-04 22:24:56.051574'); | ||
9 | 1791 | INSERT INTO accessartifactgrant (artifact, grantee, grantor, date_created) VALUES (3, 64, 64, '2012-07-04 22:24:56.615768'); | ||
10 | 1790 | 1792 | ||
11 | 1791 | 1793 | ||
12 | 1792 | ALTER TABLE accessartifactgrant ENABLE TRIGGER ALL; | 1794 | ALTER TABLE accessartifactgrant ENABLE TRIGGER ALL; |
13 | @@ -2062,6 +2064,8 @@ | |||
14 | 2062 | 2064 | ||
15 | 2063 | INSERT INTO accesspolicygrantflat (id, policy, artifact, grantee) VALUES (1, 2, 1, 14); | 2065 | INSERT INTO accesspolicygrantflat (id, policy, artifact, grantee) VALUES (1, 2, 1, 14); |
16 | 2064 | INSERT INTO accesspolicygrantflat (id, policy, artifact, grantee) VALUES (2, 2, 1, 63); | 2066 | INSERT INTO accesspolicygrantflat (id, policy, artifact, grantee) VALUES (2, 2, 1, 63); |
17 | 2067 | INSERT INTO accesspolicygrantflat (id, policy, artifact, grantee) VALUES (3, 48, 2, 64); | ||
18 | 2068 | INSERT INTO accesspolicygrantflat (id, policy, artifact, grantee) VALUES (4, 48, 3, 64); | ||
19 | 2065 | 2069 | ||
20 | 2066 | 2070 | ||
21 | 2067 | ALTER TABLE accesspolicygrantflat ENABLE TRIGGER ALL; | 2071 | ALTER TABLE accesspolicygrantflat ENABLE TRIGGER ALL; |
22 | @@ -3013,8 +3017,8 @@ | |||
23 | 3013 | INSERT INTO branch (id, title, summary, owner, product, author, name, home_page, url, whiteboard, lifecycle_status, last_mirrored, last_mirror_attempt, mirror_failures, mirror_status_message, last_scanned, last_scanned_id, last_mirrored_id, date_created, revision_count, next_mirror_time, branch_type, reviewer, date_last_modified, registrant, branch_format, repository_format, metadir_format, stacked_on, distroseries, sourcepackagename, owner_name, target_suffix, unique_name, size_on_disk, merge_queue, merge_queue_config, information_type, access_policy, access_grants) VALUES (26, NULL, NULL, 12, 6, NULL, 'mirrored', NULL, NULL, NULL, 30, '2007-03-16 14:12:49.050332', NULL, 0, NULL, NULL, NULL, NULL, '2007-03-16 03:12:49.050332', 0, NULL, 1, NULL, '2007-12-06 19:58:26.858547', 12, NULL, NULL, NULL, NULL, NULL, NULL, 'name12', 'gnome-terminal', '~name12/gnome-terminal/mirrored', NULL, NULL, NULL, 1, NULL, NULL); | 3017 | INSERT INTO branch (id, title, summary, owner, product, author, name, home_page, url, whiteboard, lifecycle_status, last_mirrored, last_mirror_attempt, mirror_failures, mirror_status_message, last_scanned, last_scanned_id, last_mirrored_id, date_created, revision_count, next_mirror_time, branch_type, reviewer, date_last_modified, registrant, branch_format, repository_format, metadir_format, stacked_on, distroseries, sourcepackagename, owner_name, target_suffix, unique_name, size_on_disk, merge_queue, merge_queue_config, information_type, access_policy, access_grants) VALUES (26, NULL, NULL, 12, 6, NULL, 'mirrored', NULL, NULL, NULL, 30, '2007-03-16 14:12:49.050332', NULL, 0, NULL, NULL, NULL, NULL, '2007-03-16 03:12:49.050332', 0, NULL, 1, NULL, '2007-12-06 19:58:26.858547', 12, NULL, NULL, NULL, NULL, NULL, NULL, 'name12', 'gnome-terminal', '~name12/gnome-terminal/mirrored', NULL, NULL, NULL, 1, NULL, NULL); |
24 | 3014 | INSERT INTO branch (id, title, summary, owner, product, author, name, home_page, url, whiteboard, lifecycle_status, last_mirrored, last_mirror_attempt, mirror_failures, mirror_status_message, last_scanned, last_scanned_id, last_mirrored_id, date_created, revision_count, next_mirror_time, branch_type, reviewer, date_last_modified, registrant, branch_format, repository_format, metadir_format, stacked_on, distroseries, sourcepackagename, owner_name, target_suffix, unique_name, size_on_disk, merge_queue, merge_queue_config, information_type, access_policy, access_grants) VALUES (27, NULL, NULL, 12, 6, NULL, 'scanned', NULL, NULL, NULL, 30, '2007-03-16 14:14:29.935752', NULL, 0, NULL, '2007-03-16 14:14:29.935752', NULL, NULL, '2007-03-16 03:14:29.935752', 0, NULL, 1, NULL, '2007-12-06 19:58:26.85913', 12, NULL, NULL, NULL, NULL, NULL, NULL, 'name12', 'gnome-terminal', '~name12/gnome-terminal/scanned', NULL, NULL, NULL, 1, NULL, NULL); | 3018 | INSERT INTO branch (id, title, summary, owner, product, author, name, home_page, url, whiteboard, lifecycle_status, last_mirrored, last_mirror_attempt, mirror_failures, mirror_status_message, last_scanned, last_scanned_id, last_mirrored_id, date_created, revision_count, next_mirror_time, branch_type, reviewer, date_last_modified, registrant, branch_format, repository_format, metadir_format, stacked_on, distroseries, sourcepackagename, owner_name, target_suffix, unique_name, size_on_disk, merge_queue, merge_queue_config, information_type, access_policy, access_grants) VALUES (27, NULL, NULL, 12, 6, NULL, 'scanned', NULL, NULL, NULL, 30, '2007-03-16 14:14:29.935752', NULL, 0, NULL, '2007-03-16 14:14:29.935752', NULL, NULL, '2007-03-16 03:14:29.935752', 0, NULL, 1, NULL, '2007-12-06 19:58:26.85913', 12, NULL, NULL, NULL, NULL, NULL, NULL, 'name12', 'gnome-terminal', '~name12/gnome-terminal/scanned', NULL, NULL, NULL, 1, NULL, NULL); |
25 | 3015 | INSERT INTO branch (id, title, summary, owner, product, author, name, home_page, url, whiteboard, lifecycle_status, last_mirrored, last_mirror_attempt, mirror_failures, mirror_status_message, last_scanned, last_scanned_id, last_mirrored_id, date_created, revision_count, next_mirror_time, branch_type, reviewer, date_last_modified, registrant, branch_format, repository_format, metadir_format, stacked_on, distroseries, sourcepackagename, owner_name, target_suffix, unique_name, size_on_disk, merge_queue, merge_queue_config, information_type, access_policy, access_grants) VALUES (28, NULL, NULL, 1, NULL, 1, 'testdoc', NULL, NULL, NULL, 30, NULL, NULL, 1, 'Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum', NULL, NULL, NULL, '2007-05-04 01:16:03.75446', 0, NULL, 1, NULL, '2007-12-06 19:58:26.859847', 1, NULL, NULL, NULL, NULL, NULL, NULL, 'mark', NULL, '~mark/+junk/testdoc', NULL, NULL, NULL, 1, NULL, NULL); | 3019 | INSERT INTO branch (id, title, summary, owner, product, author, name, home_page, url, whiteboard, lifecycle_status, last_mirrored, last_mirror_attempt, mirror_failures, mirror_status_message, last_scanned, last_scanned_id, last_mirrored_id, date_created, revision_count, next_mirror_time, branch_type, reviewer, date_last_modified, registrant, branch_format, repository_format, metadir_format, stacked_on, distroseries, sourcepackagename, owner_name, target_suffix, unique_name, size_on_disk, merge_queue, merge_queue_config, information_type, access_policy, access_grants) VALUES (28, NULL, NULL, 1, NULL, 1, 'testdoc', NULL, NULL, NULL, 30, NULL, NULL, 1, 'Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum', NULL, NULL, NULL, '2007-05-04 01:16:03.75446', 0, NULL, 1, NULL, '2007-12-06 19:58:26.859847', 1, NULL, NULL, NULL, NULL, NULL, NULL, 'mark', NULL, '~mark/+junk/testdoc', NULL, NULL, NULL, 1, NULL, NULL); |
28 | 3016 | INSERT INTO branch (id, title, summary, owner, product, author, name, home_page, url, whiteboard, lifecycle_status, last_mirrored, last_mirror_attempt, mirror_failures, mirror_status_message, last_scanned, last_scanned_id, last_mirrored_id, date_created, revision_count, next_mirror_time, branch_type, reviewer, date_last_modified, registrant, branch_format, repository_format, metadir_format, stacked_on, distroseries, sourcepackagename, owner_name, target_suffix, unique_name, size_on_disk, merge_queue, merge_queue_config, information_type, access_policy, access_grants) VALUES (29, 'Landscape trunk', NULL, 64, 16, 12, 'trunk', NULL, NULL, NULL, 30, NULL, NULL, 0, NULL, NULL, NULL, NULL, '2007-05-28 02:37:07.814303', 0, NULL, 1, NULL, '2007-12-06 19:58:26.860757', 12, NULL, NULL, NULL, NULL, NULL, NULL, 'landscape-developers', 'landscape', '~landscape-developers/landscape/trunk', NULL, NULL, NULL, 4, 48, '{}'); | 3020 | INSERT INTO branch (id, title, summary, owner, product, author, name, home_page, url, whiteboard, lifecycle_status, last_mirrored, last_mirror_attempt, mirror_failures, mirror_status_message, last_scanned, last_scanned_id, last_mirrored_id, date_created, revision_count, next_mirror_time, branch_type, reviewer, date_last_modified, registrant, branch_format, repository_format, metadir_format, stacked_on, distroseries, sourcepackagename, owner_name, target_suffix, unique_name, size_on_disk, merge_queue, merge_queue_config, information_type, access_policy, access_grants) VALUES (29, 'Landscape trunk', NULL, 64, 16, 12, 'trunk', NULL, NULL, NULL, 30, NULL, NULL, 0, NULL, NULL, NULL, NULL, '2007-05-28 02:37:07.814303', 0, NULL, 1, NULL, '2007-12-06 19:58:26.860757', 12, NULL, NULL, NULL, NULL, NULL, NULL, 'landscape-developers', 'landscape', '~landscape-developers/landscape/trunk', NULL, NULL, NULL, 4, 48, '{64}'); |
29 | 3017 | INSERT INTO branch (id, title, summary, owner, product, author, name, home_page, url, whiteboard, lifecycle_status, last_mirrored, last_mirror_attempt, mirror_failures, mirror_status_message, last_scanned, last_scanned_id, last_mirrored_id, date_created, revision_count, next_mirror_time, branch_type, reviewer, date_last_modified, registrant, branch_format, repository_format, metadir_format, stacked_on, distroseries, sourcepackagename, owner_name, target_suffix, unique_name, size_on_disk, merge_queue, merge_queue_config, information_type, access_policy, access_grants) VALUES (30, NULL, NULL, 12, 16, 12, 'feature-x', NULL, NULL, NULL, 30, NULL, NULL, 0, NULL, NULL, NULL, NULL, '2007-05-28 02:37:07.814303', 0, NULL, 1, NULL, '2007-12-06 19:58:26.861424', 12, NULL, NULL, NULL, NULL, NULL, NULL, 'name12', 'landscape', '~name12/landscape/feature-x', NULL, NULL, NULL, 4, 48, '{}'); | 3021 | INSERT INTO branch (id, title, summary, owner, product, author, name, home_page, url, whiteboard, lifecycle_status, last_mirrored, last_mirror_attempt, mirror_failures, mirror_status_message, last_scanned, last_scanned_id, last_mirrored_id, date_created, revision_count, next_mirror_time, branch_type, reviewer, date_last_modified, registrant, branch_format, repository_format, metadir_format, stacked_on, distroseries, sourcepackagename, owner_name, target_suffix, unique_name, size_on_disk, merge_queue, merge_queue_config, information_type, access_policy, access_grants) VALUES (30, NULL, NULL, 12, 16, 12, 'feature-x', NULL, NULL, NULL, 30, NULL, NULL, 0, NULL, NULL, NULL, NULL, '2007-05-28 02:37:07.814303', 0, NULL, 1, NULL, '2007-12-06 19:58:26.861424', 12, NULL, NULL, NULL, NULL, NULL, NULL, 'name12', 'landscape', '~name12/landscape/feature-x', NULL, NULL, NULL, 4, 48, '{64}'); |
30 | 3018 | INSERT INTO branch (id, title, summary, owner, product, author, name, home_page, url, whiteboard, lifecycle_status, last_mirrored, last_mirror_attempt, mirror_failures, mirror_status_message, last_scanned, last_scanned_id, last_mirrored_id, date_created, revision_count, next_mirror_time, branch_type, reviewer, date_last_modified, registrant, branch_format, repository_format, metadir_format, stacked_on, distroseries, sourcepackagename, owner_name, target_suffix, unique_name, size_on_disk, merge_queue, merge_queue_config, information_type, access_policy, access_grants) VALUES (75, 'GNOME Terminal Import Branch', NULL, 24, 6, NULL, 'import', NULL, NULL, NULL, 30, NULL, NULL, 0, NULL, NULL, NULL, NULL, '2006-06-25 20:04:03.9465', 0, NULL, 3, NULL, '2007-12-06 19:58:26.862009', 24, NULL, NULL, NULL, NULL, NULL, NULL, 'vcs-imports', 'gnome-terminal', '~vcs-imports/gnome-terminal/import', NULL, NULL, NULL, 1, NULL, NULL); | 3022 | INSERT INTO branch (id, title, summary, owner, product, author, name, home_page, url, whiteboard, lifecycle_status, last_mirrored, last_mirror_attempt, mirror_failures, mirror_status_message, last_scanned, last_scanned_id, last_mirrored_id, date_created, revision_count, next_mirror_time, branch_type, reviewer, date_last_modified, registrant, branch_format, repository_format, metadir_format, stacked_on, distroseries, sourcepackagename, owner_name, target_suffix, unique_name, size_on_disk, merge_queue, merge_queue_config, information_type, access_policy, access_grants) VALUES (75, 'GNOME Terminal Import Branch', NULL, 24, 6, NULL, 'import', NULL, NULL, NULL, 30, NULL, NULL, 0, NULL, NULL, NULL, NULL, '2006-06-25 20:04:03.9465', 0, NULL, 3, NULL, '2007-12-06 19:58:26.862009', 24, NULL, NULL, NULL, NULL, NULL, NULL, 'vcs-imports', 'gnome-terminal', '~vcs-imports/gnome-terminal/import', NULL, NULL, NULL, 1, NULL, NULL); |
31 | 3019 | INSERT INTO branch (id, title, summary, owner, product, author, name, home_page, url, whiteboard, lifecycle_status, last_mirrored, last_mirror_attempt, mirror_failures, mirror_status_message, last_scanned, last_scanned_id, last_mirrored_id, date_created, revision_count, next_mirror_time, branch_type, reviewer, date_last_modified, registrant, branch_format, repository_format, metadir_format, stacked_on, distroseries, sourcepackagename, owner_name, target_suffix, unique_name, size_on_disk, merge_queue, merge_queue_config, information_type, access_policy, access_grants) VALUES (76, 'Evolution Import Branch', NULL, 24, 5, NULL, 'import', NULL, NULL, NULL, 30, NULL, NULL, 0, NULL, NULL, NULL, NULL, '2006-06-25 20:04:04.218451', 0, NULL, 3, NULL, '2007-12-06 19:58:26.862857', 24, NULL, NULL, NULL, NULL, NULL, NULL, 'vcs-imports', 'evolution', '~vcs-imports/evolution/import', NULL, NULL, NULL, 1, NULL, NULL); | 3023 | INSERT INTO branch (id, title, summary, owner, product, author, name, home_page, url, whiteboard, lifecycle_status, last_mirrored, last_mirror_attempt, mirror_failures, mirror_status_message, last_scanned, last_scanned_id, last_mirrored_id, date_created, revision_count, next_mirror_time, branch_type, reviewer, date_last_modified, registrant, branch_format, repository_format, metadir_format, stacked_on, distroseries, sourcepackagename, owner_name, target_suffix, unique_name, size_on_disk, merge_queue, merge_queue_config, information_type, access_policy, access_grants) VALUES (76, 'Evolution Import Branch', NULL, 24, 5, NULL, 'import', NULL, NULL, NULL, 30, NULL, NULL, 0, NULL, NULL, NULL, NULL, '2006-06-25 20:04:04.218451', 0, NULL, 3, NULL, '2007-12-06 19:58:26.862857', 24, NULL, NULL, NULL, NULL, NULL, NULL, 'vcs-imports', 'evolution', '~vcs-imports/evolution/import', NULL, NULL, NULL, 1, NULL, NULL); |
32 | 3020 | 3024 | ||
33 | 3021 | 3025 | ||
34 | === modified file 'database/sampledata/current.sql' | |||
35 | --- database/sampledata/current.sql 2012-06-27 09:45:26 +0000 | |||
36 | +++ database/sampledata/current.sql 2012-07-04 22:47:20 +0000 | |||
37 | @@ -1787,6 +1787,8 @@ | |||
38 | 1787 | 1787 | ||
39 | 1788 | INSERT INTO accessartifactgrant (artifact, grantee, grantor, date_created) VALUES (1, 14, 65, '2007-08-09 11:39:16.836856'); | 1788 | INSERT INTO accessartifactgrant (artifact, grantee, grantor, date_created) VALUES (1, 14, 65, '2007-08-09 11:39:16.836856'); |
40 | 1789 | INSERT INTO accessartifactgrant (artifact, grantee, grantor, date_created) VALUES (1, 63, 65, '2007-08-09 11:39:16.836856'); | 1789 | INSERT INTO accessartifactgrant (artifact, grantee, grantor, date_created) VALUES (1, 63, 65, '2007-08-09 11:39:16.836856'); |
41 | 1790 | INSERT INTO accessartifactgrant (artifact, grantee, grantor, date_created) VALUES (2, 64, 64, '2012-07-04 22:28:18.743063'); | ||
42 | 1791 | INSERT INTO accessartifactgrant (artifact, grantee, grantor, date_created) VALUES (3, 64, 64, '2012-07-04 22:28:19.249475'); | ||
43 | 1790 | 1792 | ||
44 | 1791 | 1793 | ||
45 | 1792 | ALTER TABLE accessartifactgrant ENABLE TRIGGER ALL; | 1794 | ALTER TABLE accessartifactgrant ENABLE TRIGGER ALL; |
46 | @@ -2058,6 +2060,8 @@ | |||
47 | 2058 | 2060 | ||
48 | 2059 | INSERT INTO accesspolicygrantflat (id, policy, artifact, grantee) VALUES (1, 2, 1, 14); | 2061 | INSERT INTO accesspolicygrantflat (id, policy, artifact, grantee) VALUES (1, 2, 1, 14); |
49 | 2060 | INSERT INTO accesspolicygrantflat (id, policy, artifact, grantee) VALUES (2, 2, 1, 63); | 2062 | INSERT INTO accesspolicygrantflat (id, policy, artifact, grantee) VALUES (2, 2, 1, 63); |
50 | 2063 | INSERT INTO accesspolicygrantflat (id, policy, artifact, grantee) VALUES (3, 48, 2, 64); | ||
51 | 2064 | INSERT INTO accesspolicygrantflat (id, policy, artifact, grantee) VALUES (4, 48, 3, 64); | ||
52 | 2061 | 2065 | ||
53 | 2062 | 2066 | ||
54 | 2063 | ALTER TABLE accesspolicygrantflat ENABLE TRIGGER ALL; | 2067 | ALTER TABLE accesspolicygrantflat ENABLE TRIGGER ALL; |
55 | @@ -2950,8 +2954,8 @@ | |||
56 | 2950 | INSERT INTO branch (id, title, summary, owner, product, author, name, home_page, url, whiteboard, lifecycle_status, last_mirrored, last_mirror_attempt, mirror_failures, mirror_status_message, last_scanned, last_scanned_id, last_mirrored_id, date_created, revision_count, next_mirror_time, branch_type, reviewer, date_last_modified, registrant, branch_format, repository_format, metadir_format, stacked_on, distroseries, sourcepackagename, owner_name, target_suffix, unique_name, size_on_disk, merge_queue, merge_queue_config, information_type, access_policy, access_grants) VALUES (26, NULL, NULL, 12, 6, NULL, 'mirrored', NULL, NULL, NULL, 30, '2007-03-16 14:12:49.050332', NULL, 0, NULL, NULL, NULL, NULL, '2007-03-16 03:12:49.050332', 0, NULL, 1, NULL, '2007-12-06 19:58:26.858547', 12, NULL, NULL, NULL, NULL, NULL, NULL, 'name12', 'gnome-terminal', '~name12/gnome-terminal/mirrored', NULL, NULL, NULL, 1, NULL, NULL); | 2954 | INSERT INTO branch (id, title, summary, owner, product, author, name, home_page, url, whiteboard, lifecycle_status, last_mirrored, last_mirror_attempt, mirror_failures, mirror_status_message, last_scanned, last_scanned_id, last_mirrored_id, date_created, revision_count, next_mirror_time, branch_type, reviewer, date_last_modified, registrant, branch_format, repository_format, metadir_format, stacked_on, distroseries, sourcepackagename, owner_name, target_suffix, unique_name, size_on_disk, merge_queue, merge_queue_config, information_type, access_policy, access_grants) VALUES (26, NULL, NULL, 12, 6, NULL, 'mirrored', NULL, NULL, NULL, 30, '2007-03-16 14:12:49.050332', NULL, 0, NULL, NULL, NULL, NULL, '2007-03-16 03:12:49.050332', 0, NULL, 1, NULL, '2007-12-06 19:58:26.858547', 12, NULL, NULL, NULL, NULL, NULL, NULL, 'name12', 'gnome-terminal', '~name12/gnome-terminal/mirrored', NULL, NULL, NULL, 1, NULL, NULL); |
57 | 2951 | INSERT INTO branch (id, title, summary, owner, product, author, name, home_page, url, whiteboard, lifecycle_status, last_mirrored, last_mirror_attempt, mirror_failures, mirror_status_message, last_scanned, last_scanned_id, last_mirrored_id, date_created, revision_count, next_mirror_time, branch_type, reviewer, date_last_modified, registrant, branch_format, repository_format, metadir_format, stacked_on, distroseries, sourcepackagename, owner_name, target_suffix, unique_name, size_on_disk, merge_queue, merge_queue_config, information_type, access_policy, access_grants) VALUES (27, NULL, NULL, 12, 6, NULL, 'scanned', NULL, NULL, NULL, 30, '2007-03-16 14:14:29.935752', NULL, 0, NULL, '2007-03-16 14:14:29.935752', NULL, NULL, '2007-03-16 03:14:29.935752', 0, NULL, 1, NULL, '2007-12-06 19:58:26.85913', 12, NULL, NULL, NULL, NULL, NULL, NULL, 'name12', 'gnome-terminal', '~name12/gnome-terminal/scanned', NULL, NULL, NULL, 1, NULL, NULL); | 2955 | INSERT INTO branch (id, title, summary, owner, product, author, name, home_page, url, whiteboard, lifecycle_status, last_mirrored, last_mirror_attempt, mirror_failures, mirror_status_message, last_scanned, last_scanned_id, last_mirrored_id, date_created, revision_count, next_mirror_time, branch_type, reviewer, date_last_modified, registrant, branch_format, repository_format, metadir_format, stacked_on, distroseries, sourcepackagename, owner_name, target_suffix, unique_name, size_on_disk, merge_queue, merge_queue_config, information_type, access_policy, access_grants) VALUES (27, NULL, NULL, 12, 6, NULL, 'scanned', NULL, NULL, NULL, 30, '2007-03-16 14:14:29.935752', NULL, 0, NULL, '2007-03-16 14:14:29.935752', NULL, NULL, '2007-03-16 03:14:29.935752', 0, NULL, 1, NULL, '2007-12-06 19:58:26.85913', 12, NULL, NULL, NULL, NULL, NULL, NULL, 'name12', 'gnome-terminal', '~name12/gnome-terminal/scanned', NULL, NULL, NULL, 1, NULL, NULL); |
58 | 2952 | INSERT INTO branch (id, title, summary, owner, product, author, name, home_page, url, whiteboard, lifecycle_status, last_mirrored, last_mirror_attempt, mirror_failures, mirror_status_message, last_scanned, last_scanned_id, last_mirrored_id, date_created, revision_count, next_mirror_time, branch_type, reviewer, date_last_modified, registrant, branch_format, repository_format, metadir_format, stacked_on, distroseries, sourcepackagename, owner_name, target_suffix, unique_name, size_on_disk, merge_queue, merge_queue_config, information_type, access_policy, access_grants) VALUES (28, NULL, NULL, 1, NULL, 1, 'testdoc', NULL, NULL, NULL, 30, NULL, NULL, 1, 'Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum', NULL, NULL, NULL, '2007-05-04 01:16:03.75446', 0, NULL, 1, NULL, '2007-12-06 19:58:26.859847', 1, NULL, NULL, NULL, NULL, NULL, NULL, 'mark', NULL, '~mark/+junk/testdoc', NULL, NULL, NULL, 1, NULL, NULL); | 2956 | INSERT INTO branch (id, title, summary, owner, product, author, name, home_page, url, whiteboard, lifecycle_status, last_mirrored, last_mirror_attempt, mirror_failures, mirror_status_message, last_scanned, last_scanned_id, last_mirrored_id, date_created, revision_count, next_mirror_time, branch_type, reviewer, date_last_modified, registrant, branch_format, repository_format, metadir_format, stacked_on, distroseries, sourcepackagename, owner_name, target_suffix, unique_name, size_on_disk, merge_queue, merge_queue_config, information_type, access_policy, access_grants) VALUES (28, NULL, NULL, 1, NULL, 1, 'testdoc', NULL, NULL, NULL, 30, NULL, NULL, 1, 'Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum', NULL, NULL, NULL, '2007-05-04 01:16:03.75446', 0, NULL, 1, NULL, '2007-12-06 19:58:26.859847', 1, NULL, NULL, NULL, NULL, NULL, NULL, 'mark', NULL, '~mark/+junk/testdoc', NULL, NULL, NULL, 1, NULL, NULL); |
61 | 2953 | INSERT INTO branch (id, title, summary, owner, product, author, name, home_page, url, whiteboard, lifecycle_status, last_mirrored, last_mirror_attempt, mirror_failures, mirror_status_message, last_scanned, last_scanned_id, last_mirrored_id, date_created, revision_count, next_mirror_time, branch_type, reviewer, date_last_modified, registrant, branch_format, repository_format, metadir_format, stacked_on, distroseries, sourcepackagename, owner_name, target_suffix, unique_name, size_on_disk, merge_queue, merge_queue_config, information_type, access_policy, access_grants) VALUES (29, 'Landscape trunk', NULL, 64, 16, 12, 'trunk', NULL, NULL, NULL, 30, NULL, NULL, 0, NULL, NULL, NULL, NULL, '2007-05-28 02:37:07.814303', 0, NULL, 1, NULL, '2007-12-06 19:58:26.860757', 12, NULL, NULL, NULL, NULL, NULL, NULL, 'landscape-developers', 'landscape', '~landscape-developers/landscape/trunk', NULL, NULL, NULL, 4, 48, '{}'); | 2957 | INSERT INTO branch (id, title, summary, owner, product, author, name, home_page, url, whiteboard, lifecycle_status, last_mirrored, last_mirror_attempt, mirror_failures, mirror_status_message, last_scanned, last_scanned_id, last_mirrored_id, date_created, revision_count, next_mirror_time, branch_type, reviewer, date_last_modified, registrant, branch_format, repository_format, metadir_format, stacked_on, distroseries, sourcepackagename, owner_name, target_suffix, unique_name, size_on_disk, merge_queue, merge_queue_config, information_type, access_policy, access_grants) VALUES (29, 'Landscape trunk', NULL, 64, 16, 12, 'trunk', NULL, NULL, NULL, 30, NULL, NULL, 0, NULL, NULL, NULL, NULL, '2007-05-28 02:37:07.814303', 0, NULL, 1, NULL, '2007-12-06 19:58:26.860757', 12, NULL, NULL, NULL, NULL, NULL, NULL, 'landscape-developers', 'landscape', '~landscape-developers/landscape/trunk', NULL, NULL, NULL, 4, 48, '{64}'); |
62 | 2954 | INSERT INTO branch (id, title, summary, owner, product, author, name, home_page, url, whiteboard, lifecycle_status, last_mirrored, last_mirror_attempt, mirror_failures, mirror_status_message, last_scanned, last_scanned_id, last_mirrored_id, date_created, revision_count, next_mirror_time, branch_type, reviewer, date_last_modified, registrant, branch_format, repository_format, metadir_format, stacked_on, distroseries, sourcepackagename, owner_name, target_suffix, unique_name, size_on_disk, merge_queue, merge_queue_config, information_type, access_policy, access_grants) VALUES (30, NULL, NULL, 12, 16, 12, 'feature-x', NULL, NULL, NULL, 30, NULL, NULL, 0, NULL, NULL, NULL, NULL, '2007-05-28 02:37:07.814303', 0, NULL, 1, NULL, '2007-12-06 19:58:26.861424', 12, NULL, NULL, NULL, NULL, NULL, NULL, 'name12', 'landscape', '~name12/landscape/feature-x', NULL, NULL, NULL, 4, 48, '{}'); | 2958 | INSERT INTO branch (id, title, summary, owner, product, author, name, home_page, url, whiteboard, lifecycle_status, last_mirrored, last_mirror_attempt, mirror_failures, mirror_status_message, last_scanned, last_scanned_id, last_mirrored_id, date_created, revision_count, next_mirror_time, branch_type, reviewer, date_last_modified, registrant, branch_format, repository_format, metadir_format, stacked_on, distroseries, sourcepackagename, owner_name, target_suffix, unique_name, size_on_disk, merge_queue, merge_queue_config, information_type, access_policy, access_grants) VALUES (30, NULL, NULL, 12, 16, 12, 'feature-x', NULL, NULL, NULL, 30, NULL, NULL, 0, NULL, NULL, NULL, NULL, '2007-05-28 02:37:07.814303', 0, NULL, 1, NULL, '2007-12-06 19:58:26.861424', 12, NULL, NULL, NULL, NULL, NULL, NULL, 'name12', 'landscape', '~name12/landscape/feature-x', NULL, NULL, NULL, 4, 48, '{64}'); |
63 | 2955 | INSERT INTO branch (id, title, summary, owner, product, author, name, home_page, url, whiteboard, lifecycle_status, last_mirrored, last_mirror_attempt, mirror_failures, mirror_status_message, last_scanned, last_scanned_id, last_mirrored_id, date_created, revision_count, next_mirror_time, branch_type, reviewer, date_last_modified, registrant, branch_format, repository_format, metadir_format, stacked_on, distroseries, sourcepackagename, owner_name, target_suffix, unique_name, size_on_disk, merge_queue, merge_queue_config, information_type, access_policy, access_grants) VALUES (75, 'GNOME Terminal Import Branch', NULL, 24, 6, NULL, 'import', NULL, NULL, NULL, 30, NULL, NULL, 0, NULL, NULL, NULL, NULL, '2006-06-25 20:04:03.9465', 0, NULL, 3, NULL, '2007-12-06 19:58:26.862009', 24, NULL, NULL, NULL, NULL, NULL, NULL, 'vcs-imports', 'gnome-terminal', '~vcs-imports/gnome-terminal/import', NULL, NULL, NULL, 1, NULL, NULL); | 2959 | INSERT INTO branch (id, title, summary, owner, product, author, name, home_page, url, whiteboard, lifecycle_status, last_mirrored, last_mirror_attempt, mirror_failures, mirror_status_message, last_scanned, last_scanned_id, last_mirrored_id, date_created, revision_count, next_mirror_time, branch_type, reviewer, date_last_modified, registrant, branch_format, repository_format, metadir_format, stacked_on, distroseries, sourcepackagename, owner_name, target_suffix, unique_name, size_on_disk, merge_queue, merge_queue_config, information_type, access_policy, access_grants) VALUES (75, 'GNOME Terminal Import Branch', NULL, 24, 6, NULL, 'import', NULL, NULL, NULL, 30, NULL, NULL, 0, NULL, NULL, NULL, NULL, '2006-06-25 20:04:03.9465', 0, NULL, 3, NULL, '2007-12-06 19:58:26.862009', 24, NULL, NULL, NULL, NULL, NULL, NULL, 'vcs-imports', 'gnome-terminal', '~vcs-imports/gnome-terminal/import', NULL, NULL, NULL, 1, NULL, NULL); |
64 | 2956 | INSERT INTO branch (id, title, summary, owner, product, author, name, home_page, url, whiteboard, lifecycle_status, last_mirrored, last_mirror_attempt, mirror_failures, mirror_status_message, last_scanned, last_scanned_id, last_mirrored_id, date_created, revision_count, next_mirror_time, branch_type, reviewer, date_last_modified, registrant, branch_format, repository_format, metadir_format, stacked_on, distroseries, sourcepackagename, owner_name, target_suffix, unique_name, size_on_disk, merge_queue, merge_queue_config, information_type, access_policy, access_grants) VALUES (76, 'Evolution Import Branch', NULL, 24, 5, NULL, 'import', NULL, NULL, NULL, 30, NULL, NULL, 0, NULL, NULL, NULL, NULL, '2006-06-25 20:04:04.218451', 0, NULL, 3, NULL, '2007-12-06 19:58:26.862857', 24, NULL, NULL, NULL, NULL, NULL, NULL, 'vcs-imports', 'evolution', '~vcs-imports/evolution/import', NULL, NULL, NULL, 1, NULL, NULL); | 2960 | INSERT INTO branch (id, title, summary, owner, product, author, name, home_page, url, whiteboard, lifecycle_status, last_mirrored, last_mirror_attempt, mirror_failures, mirror_status_message, last_scanned, last_scanned_id, last_mirrored_id, date_created, revision_count, next_mirror_time, branch_type, reviewer, date_last_modified, registrant, branch_format, repository_format, metadir_format, stacked_on, distroseries, sourcepackagename, owner_name, target_suffix, unique_name, size_on_disk, merge_queue, merge_queue_config, information_type, access_policy, access_grants) VALUES (76, 'Evolution Import Branch', NULL, 24, 5, NULL, 'import', NULL, NULL, NULL, 30, NULL, NULL, 0, NULL, NULL, NULL, NULL, '2006-06-25 20:04:04.218451', 0, NULL, 3, NULL, '2007-12-06 19:58:26.862857', 24, NULL, NULL, NULL, NULL, NULL, NULL, 'vcs-imports', 'evolution', '~vcs-imports/evolution/import', NULL, NULL, NULL, 1, NULL, NULL); |
65 | 2957 | 2961 | ||
66 | 2958 | 2962 | ||
67 | === modified file 'database/schema/security.cfg' | |||
68 | --- database/schema/security.cfg 2012-07-02 14:45:56 +0000 | |||
69 | +++ database/schema/security.cfg 2012-07-04 22:47:20 +0000 | |||
70 | @@ -2198,8 +2198,6 @@ | |||
71 | 2198 | 2198 | ||
72 | 2199 | [garbo] | 2199 | [garbo] |
73 | 2200 | groups=script,read | 2200 | groups=script,read |
74 | 2201 | public.accessartifact = SELECT, INSERT | ||
75 | 2202 | public.accessartifactgrant = SELECT, INSERT | ||
76 | 2203 | public.account = SELECT, DELETE | 2201 | public.account = SELECT, DELETE |
77 | 2204 | public.answercontact = SELECT, DELETE | 2202 | public.answercontact = SELECT, DELETE |
78 | 2205 | public.branch = SELECT, UPDATE | 2203 | public.branch = SELECT, UPDATE |
79 | 2206 | 2204 | ||
80 | === modified file 'lib/lp/scripts/garbo.py' | |||
81 | --- lib/lp/scripts/garbo.py 2012-07-03 08:04:35 +0000 | |||
82 | +++ lib/lp/scripts/garbo.py 2012-07-04 22:47:20 +0000 | |||
83 | @@ -51,7 +51,6 @@ | |||
84 | 51 | MAX_SAMPLE_SIZE, | 51 | MAX_SAMPLE_SIZE, |
85 | 52 | ) | 52 | ) |
86 | 53 | from lp.code.interfaces.revision import IRevisionSet | 53 | from lp.code.interfaces.revision import IRevisionSet |
87 | 54 | from lp.code.model.branch import Branch | ||
88 | 55 | from lp.code.model.codeimportevent import CodeImportEvent | 54 | from lp.code.model.codeimportevent import CodeImportEvent |
89 | 56 | from lp.code.model.codeimportresult import CodeImportResult | 55 | from lp.code.model.codeimportresult import CodeImportResult |
90 | 57 | from lp.code.model.revision import ( | 56 | from lp.code.model.revision import ( |
91 | @@ -59,11 +58,6 @@ | |||
92 | 59 | RevisionCache, | 58 | RevisionCache, |
93 | 60 | ) | 59 | ) |
94 | 61 | from lp.hardwaredb.model.hwdb import HWSubmission | 60 | from lp.hardwaredb.model.hwdb import HWSubmission |
95 | 62 | from lp.registry.enums import PRIVATE_INFORMATION_TYPES | ||
96 | 63 | from lp.registry.interfaces.accesspolicy import ( | ||
97 | 64 | IAccessArtifactGrantSource, | ||
98 | 65 | IAccessArtifactSource, | ||
99 | 66 | ) | ||
100 | 67 | from lp.registry.model.person import Person | 61 | from lp.registry.model.person import Person |
101 | 68 | from lp.services.config import config | 62 | from lp.services.config import config |
102 | 69 | from lp.services.database import postgresql | 63 | from lp.services.database import postgresql |
103 | @@ -1143,46 +1137,6 @@ | |||
104 | 1143 | transaction.commit() | 1137 | transaction.commit() |
105 | 1144 | 1138 | ||
106 | 1145 | 1139 | ||
107 | 1146 | class PopulateBranchAccessArtifactGrant(TunableLoop): | ||
108 | 1147 | |||
109 | 1148 | maximum_chunk_size = 5000 | ||
110 | 1149 | |||
111 | 1150 | def __init__(self, log, abort_time=None): | ||
112 | 1151 | super(PopulateBranchAccessArtifactGrant, self).__init__( | ||
113 | 1152 | log, abort_time) | ||
114 | 1153 | self.memcache_key = '%s:branch-populate-aag' % config.instance_name | ||
115 | 1154 | watermark = getUtility(IMemcacheClient).get(self.memcache_key) | ||
116 | 1155 | self.start_at = watermark or 0 | ||
117 | 1156 | |||
118 | 1157 | def findBranches(self): | ||
119 | 1158 | return IMasterStore(Branch).find( | ||
120 | 1159 | Branch, | ||
121 | 1160 | Branch.information_type.is_in(PRIVATE_INFORMATION_TYPES), | ||
122 | 1161 | Branch.id >= self.start_at).order_by(Branch.id) | ||
123 | 1162 | |||
124 | 1163 | def isDone(self): | ||
125 | 1164 | return self.findBranches().is_empty() | ||
126 | 1165 | |||
127 | 1166 | def __call__(self, chunk_size): | ||
128 | 1167 | branches = list(self.findBranches()[:chunk_size]) | ||
129 | 1168 | artifacts = getUtility(IAccessArtifactSource).ensure(branches) | ||
130 | 1169 | branch_to_artifact = dict( | ||
131 | 1170 | (artifact.branch_id, artifact) for artifact in artifacts) | ||
132 | 1171 | grants = [] | ||
133 | 1172 | for branch in branches: | ||
134 | 1173 | artifact = branch_to_artifact[branch.id] | ||
135 | 1174 | grants.extend( | ||
136 | 1175 | [(artifact, branchsub.person, branchsub.subscribed_by) | ||
137 | 1176 | for branchsub in branch.subscriptions]) | ||
138 | 1177 | getUtility(IAccessArtifactGrantSource).grant(grants) | ||
139 | 1178 | self.start_at = branches[-1].id + 1 | ||
140 | 1179 | result = getUtility(IMemcacheClient).set( | ||
141 | 1180 | self.memcache_key, self.start_at) | ||
142 | 1181 | if not result: | ||
143 | 1182 | self.log.warning('Failed to set start_at in memcache.') | ||
144 | 1183 | transaction.commit() | ||
145 | 1184 | |||
146 | 1185 | |||
147 | 1186 | class BaseDatabaseGarbageCollector(LaunchpadCronScript): | 1140 | class BaseDatabaseGarbageCollector(LaunchpadCronScript): |
148 | 1187 | """Abstract base class to run a collection of TunableLoops.""" | 1141 | """Abstract base class to run a collection of TunableLoops.""" |
149 | 1188 | script_name = None # Script name for locking and database user. Override. | 1142 | script_name = None # Script name for locking and database user. Override. |
150 | @@ -1438,7 +1392,6 @@ | |||
151 | 1438 | DuplicateSessionPruner, | 1392 | DuplicateSessionPruner, |
152 | 1439 | BugHeatUpdater, | 1393 | BugHeatUpdater, |
153 | 1440 | BugTaskFlattener, | 1394 | BugTaskFlattener, |
154 | 1441 | PopulateBranchAccessArtifactGrant, | ||
155 | 1442 | ] | 1395 | ] |
156 | 1443 | experimental_tunable_loops = [] | 1396 | experimental_tunable_loops = [] |
157 | 1444 | 1397 | ||
158 | 1445 | 1398 | ||
159 | === modified file 'lib/lp/scripts/tests/test_garbo.py' | |||
160 | --- lib/lp/scripts/tests/test_garbo.py 2012-06-27 03:45:50 +0000 | |||
161 | +++ lib/lp/scripts/tests/test_garbo.py 2012-07-04 22:47:20 +0000 | |||
162 | @@ -47,11 +47,7 @@ | |||
163 | 47 | BranchFormat, | 47 | BranchFormat, |
164 | 48 | RepositoryFormat, | 48 | RepositoryFormat, |
165 | 49 | ) | 49 | ) |
171 | 50 | from lp.code.enums import ( | 50 | from lp.code.enums import CodeImportResultStatus |
167 | 51 | BranchSubscriptionNotificationLevel, | ||
168 | 52 | CodeImportResultStatus, | ||
169 | 53 | CodeReviewNotificationLevel, | ||
170 | 54 | ) | ||
172 | 55 | from lp.code.interfaces.codeimportevent import ICodeImportEventSet | 51 | from lp.code.interfaces.codeimportevent import ICodeImportEventSet |
173 | 56 | from lp.code.model.branchjob import ( | 52 | from lp.code.model.branchjob import ( |
174 | 57 | BranchJob, | 53 | BranchJob, |
175 | @@ -59,7 +55,6 @@ | |||
176 | 59 | ) | 55 | ) |
177 | 60 | from lp.code.model.codeimportevent import CodeImportEvent | 56 | from lp.code.model.codeimportevent import CodeImportEvent |
178 | 61 | from lp.code.model.codeimportresult import CodeImportResult | 57 | from lp.code.model.codeimportresult import CodeImportResult |
179 | 62 | from lp.registry.enums import InformationType | ||
180 | 63 | from lp.registry.interfaces.distribution import IDistributionSet | 58 | from lp.registry.interfaces.distribution import IDistributionSet |
181 | 64 | from lp.registry.interfaces.person import IPersonSet | 59 | from lp.registry.interfaces.person import IPersonSet |
182 | 65 | from lp.scripts.garbo import ( | 60 | from lp.scripts.garbo import ( |
183 | @@ -1154,38 +1149,6 @@ | |||
184 | 1154 | self.runHourly() | 1149 | self.runHourly() |
185 | 1155 | self.assertEqual((task.id,), get_flat()) | 1150 | self.assertEqual((task.id,), get_flat()) |
186 | 1156 | 1151 | ||
187 | 1157 | def test_PopulateBranchAccessArtifactGrant(self): | ||
188 | 1158 | # Branches without a access_policy have one set by the job. | ||
189 | 1159 | with dbuser('testadmin'): | ||
190 | 1160 | branch = self.factory.makeBranch() | ||
191 | 1161 | |||
192 | 1162 | def get_access_grants(): | ||
193 | 1163 | return IMasterStore(BugTask).execute( | ||
194 | 1164 | 'SELECT access_grants FROM branch WHERE id = ?', | ||
195 | 1165 | (branch.id,)).get_one()[0] | ||
196 | 1166 | |||
197 | 1167 | # The branch is public, so running the garbo job will have no effect. | ||
198 | 1168 | self.runHourly() | ||
199 | 1169 | self.assertIs(None, get_access_grants()) | ||
200 | 1170 | |||
201 | 1171 | with dbuser('testadmin'): | ||
202 | 1172 | branch.transitionToInformationType( | ||
203 | 1173 | InformationType.USERDATA, branch.owner, verify_policy=False) | ||
204 | 1174 | |||
205 | 1175 | # Now the branch is USERDATA, it will have no explicit grants. | ||
206 | 1176 | self.assertEqual([], get_access_grants()) | ||
207 | 1177 | |||
208 | 1178 | with dbuser('testadmin'): | ||
209 | 1179 | subscriber = self.factory.makePerson() | ||
210 | 1180 | branch.subscribe( | ||
211 | 1181 | subscriber, BranchSubscriptionNotificationLevel.NOEMAIL, | ||
212 | 1182 | None, CodeReviewNotificationLevel.NOEMAIL, branch.owner) | ||
213 | 1183 | |||
214 | 1184 | # The subscriber has been added. | ||
215 | 1185 | self.runHourly() | ||
216 | 1186 | self.assertContentEqual( | ||
217 | 1187 | [branch.owner.id, subscriber.id], get_access_grants()) | ||
218 | 1188 | |||
219 | 1189 | 1152 | ||
220 | 1190 | class TestGarboTasks(TestCaseWithFactory): | 1153 | class TestGarboTasks(TestCaseWithFactory): |
221 | 1191 | layer = LaunchpadZopelessLayer | 1154 | layer = LaunchpadZopelessLayer |