Exemple #1
0
 def test_10_match_with_versioned_list_major_version(self):
     list_name, list_ver = match_with_versioned_list(
         '71.1', ['70.0', '71.0'], 'mozpub-track-digest256')
     self.assertEqual(
         (list_name, list_ver),
         ('71.0-mozpub-track-digest256', '71.0')
     )
Exemple #2
0
 def test_7_match_with_versioned_list_version_fuzzy_match(self):
     list_name, list_ver = match_with_versioned_list(
         '72.0a1', ['70.0', '71.0'], 'mozpub-track-digest256')
     self.assertEqual(
         (list_name, list_ver),
         ('mozpub-track-digest256', None)
     )
Exemple #3
0
 def test_3_match_with_versioned_list_version_not_specified(self):
     list_name, list_ver = match_with_versioned_list(
         'none', ['70.0', '71.0'], 'mozpub-track-digest256')
     self.assertEqual(
         (list_name, list_ver),
         ('mozpub-track-digest256', None)
     )
Exemple #4
0
 def test_4_match_with_versioned_list_version_lower_than_supported(self):
     list_name, list_ver = match_with_versioned_list(
         '68.0', ['70.0', '71.0'], 'mozpub-track-digest256')
     self.assertEqual(
         (list_name, list_ver),
         ('69.0-mozpub-track-digest256', '69.0')
     )
Exemple #5
0
 def test_5_match_with_versioned_list_version_exact_match(self):
     list_name, list_ver = match_with_versioned_list(
         '70.0', ['70.0', '71.0'], 'mozpub-track-digest256')
     self.assertEquals((list_name, list_ver),
                       ('70.0-mozpub-track-digest256', '70.0'))