← Back to team overview

launchpad-reviewers team mailing list archive

[Merge] ~lgp171188/launchpad:vulnerability-api-tests-fix into launchpad:master

 

Guruprasad has proposed merging ~lgp171188/launchpad:vulnerability-api-tests-fix into launchpad:master.

Commit message:
Fix the test errors caused by the vulnerability API changes

Requested reviews:
  Launchpad code reviewers (launchpad-reviewers)

For more details, see:
https://code.launchpad.net/~lgp171188/launchpad/+git/launchpad/+merge/422016
-- 
Your team Launchpad code reviewers is requested to review the proposed merge of ~lgp171188/launchpad:vulnerability-api-tests-fix into launchpad:master.
diff --git a/lib/lp/registry/stories/webservice/xx-distribution.txt b/lib/lp/registry/stories/webservice/xx-distribution.txt
index 2d8236e..51eeff6 100644
--- a/lib/lp/registry/stories/webservice/xx-distribution.txt
+++ b/lib/lp/registry/stories/webservice/xx-distribution.txt
@@ -68,6 +68,7 @@ And for every distribution we publish most of its attributes.
     supports_ppas: True
     title: 'Ubuntu'
     vcs: None
+    vulnerabilities_collection_link: 'http://.../ubuntu/vulnerabilities'
     web_link: 'http://launchpad.../ubuntu'
 
 
diff --git a/lib/lp/registry/tests/test_distribution.py b/lib/lp/registry/tests/test_distribution.py
index 8826261..b6d6ad6 100644
--- a/lib/lp/registry/tests/test_distribution.py
+++ b/lib/lp/registry/tests/test_distribution.py
@@ -2114,10 +2114,12 @@ class TestDistributionVulnerabilitiesWebService(TestCaseWithFactory):
         )
         self.assertEqual(400, response.status)
         self.assertEqual(
-            b'status: Required input is missing.\n'
-            b'creator: Required input is missing.\n'
-            b'information_type: Required input is missing.',
-            response.body
+            {
+                'status: Required input is missing.',
+                'creator: Required input is missing.',
+                'information_type: Required input is missing.'
+            },
+            set(response.body.decode().split('\n'))
         )
 
     def test_newVulnerability_default_arguments(self):