Browse Source

SUSE: Update openSUSE Tumbleweed references for lsb-release-3.X.X

lsb-release-3.X.X doesn't report 'openSUSE Tumbleweed' anymore but it
simply returns 'openSUSE' so update the references for Tumbleweed.

Change-Id: I3e99948167655a8a94c76a1a90d7ddefa6d5bb5b
Link: http://bugzilla.suse.com/show_bug.cgi?id=1059374
Markos Chandras 1 year ago
parent
commit
52eb3db1ce
2 changed files with 6 additions and 8 deletions
  1. 2
    2
      bindep/depends.py
  2. 4
    6
      bindep/tests/test_depends.py

+ 2
- 2
bindep/depends.py View File

@@ -307,13 +307,13 @@ class Depends(object):
307 307
             self.platform = Dpkg()
308 308
         elif distro in ["amazonami", "centos", "redhatenterpriseserver",
309 309
                         "redhatenterpriseworkstation",
310
-                        "fedora", "opensuseproject", "opensusetumbleweed",
310
+                        "fedora", "opensuseproject", "opensuse",
311 311
                         "suselinux"]:
312 312
             if distro in ["redhatenterpriseserver",
313 313
                           "redhatenterpriseworkstation"]:
314 314
                 # just short alias
315 315
                 atoms.add("rhel")
316
-            elif distro in ["opensuseproject", "opensusetumbleweed"]:
316
+            elif distro == "opensuseproject":
317 317
                 # just short alias
318 318
                 atoms.add("opensuse")
319 319
             # Family aliases

+ 4
- 6
bindep/tests/test_depends.py View File

@@ -142,12 +142,10 @@ class TestDepends(TestCase):
142 142
             self.assertThat(platform_profiles,
143 143
                             Contains("platform:suse"))
144 144
 
145
-    def test_detects_opensuse_tumbleweed(self):
146
-        with self._mock_lsb("openSUSE Tumbleweed"):
145
+    def test_detects_opensuse(self):
146
+        with self._mock_lsb("openSUSE"):
147 147
             depends = Depends("")
148 148
             platform_profiles = depends.platform_profiles()
149
-            self.assertThat(platform_profiles,
150
-                            Contains("platform:opensusetumbleweed"))
151 149
             self.assertThat(platform_profiles,
152 150
                             Contains("platform:opensuse"))
153 151
             self.assertThat(platform_profiles,
@@ -213,8 +211,8 @@ class TestDepends(TestCase):
213 211
                 depends.platform_profiles(), Contains("platform:rpm"))
214 212
             self.assertIsInstance(depends.platform, Rpm)
215 213
 
216
-    def test_opensuse_tumbleweed_implies_rpm(self):
217
-        with self._mock_lsb("openSUSE Tumbleweed"):
214
+    def test_opensuse_implies_rpm(self):
215
+        with self._mock_lsb("openSUSE"):
218 216
             depends = Depends("")
219 217
             self.assertThat(
220 218
                 depends.platform_profiles(), Contains("platform:rpm"))

Loading…
Cancel
Save