8000 Rename supports to classifiers_support · hugovk/drop-python@73cced2 · GitHub
[go: up one dir, main page]

Skip to content

Commit 73cced2

Browse files
committed
Rename supports to classifiers_support
1 parent bd55351 commit 73cced2

File tree

2 files changed

+8
-8
lines changed

2 files changed

+8
-8
lines changed

test_utils.py

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ def test_supports_has_support(self):
2626
]
2727

2828
# Act
29-
has_support = utils.supports(classifiers, "2.6")
29+
has_support = utils.classifiers_support(classifiers, "2.6")
3030

3131
# Assert
3232
self.assertEqual(has_support, "yes")
@@ -44,7 +44,7 @@ def test_supports_no_support_but_others_are(self):
4444
]
4545

4646
# Act
47-
has_support = utils.supports(classifiers, "2.6")
47+
has_support = utils.classifiers_support(classifiers, "2.6")
4848

4949
# Assert
5050
self.assertEqual(has_support, "no")
@@ -58,7 +58,7 @@ def test_supports_no_support_but_other_2x_are(self):
5858
]
5959

6060
# Act
61-
has_support = utils.supports(classifiers, "2.6")
61+
has_support = utils.classifiers_support(classifiers, "2.6")
6262

6363
# Assert
6464
self.assertEqual(has_support, "no")
@@ -74,7 +74,7 @@ def test_supports_no_support_but_other_3x_are(self):
7474
]
7575

7676
# Act
77-
has_support = utils.supports(classifiers, "2.6")
77+
has_support = utils.classifiers_support(classifiers, "2.6")
7878

7979
# Assert
8080
self.assertEqual(has_support, "no")
@@ -89,7 +89,7 @@ def test_supports_no_support_or_any_major_minor(self):
8989

9090
# Act
9191
# Classifiers are not explicit: we want to assume support
92-
has_support = utils.supports(classifiers, "2.6")
92+
has_support = utils.classifiers_support(classifiers, "2.6")
9393

9494
# Assert
9595
self.assertEqual(has_support, "maybe")
@@ -101,7 +101,7 @@ def test_supports_no_support_for_empty(self):
101101

102102
# Act
103103
# Classifiers are not explicit: we want to assume support
104-
has_support = utils.supports(classifiers, "2.6")
104+
has_support = utils.classifiers_support(classifiers, "2.6")
105105

106106
# Assert
107107
self.assertEqual(has_support, "maybe")

utils.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ def get_json_url(package_name):
4242
return BASE_URL + '/' + package_name + '/json'
4343

4444

45-
def supports(classifiers, version):
45+
def classi 7F79 fiers_support(classifiers, version):
4646
"""Do these classifiers support this Python version?"""
4747
desired_classifier = CLASSIFIER.format(version)
4848

@@ -80,7 +80,7 @@ def annotate_support(packages, versions=['2.6']):
8080
# Init
8181
package[version] = {}
8282

83-
has_support = supports(data['info']['classifiers'], version)
83+
has_support = classifiers_support(data['info']['classifiers'], version)
8484
if has_support == "yes":
8585
package[version]['dropped_support'] = "no"
8686
if has_support == "no":

0 commit comments

Comments
 (0)
0