Ejemplo n.º 1
0
 def test_map_arrays(self) -> None:
     a = {
         "desktop app 1.0": [1, 2, 3],
         "desktop app 2.0": [10, 12, 13],
         "desktop app 3.0": [21, 22, 23],
         "website": [1, 2, 3],
         "ZulipiOS": [1, 2, 3],
         "ZulipElectron": [2, 5, 7],
         "ZulipMobile": [1, 5, 7],
         "ZulipPython": [1, 2, 3],
         "API: Python": [1, 2, 3],
         "SomethingRandom": [4, 5, 6],
         "ZulipGitHubWebhook": [7, 7, 9],
         "ZulipAndroid": [64, 63, 65],
     }
     result = rewrite_client_arrays(a)
     self.assertEqual(
         result,
         {
             "Old desktop app": [32, 36, 39],
             "Old iOS app": [1, 2, 3],
             "Desktop app": [2, 5, 7],
             "Mobile app": [1, 5, 7],
             "Website": [1, 2, 3],
             "Python API": [2, 4, 6],
             "SomethingRandom": [4, 5, 6],
             "GitHub webhook": [7, 7, 9],
             "Old Android app": [64, 63, 65],
         },
     )
Ejemplo n.º 2
0
 def test_map_arrays(self):
     # type: () -> None
     a = {
         'desktop app 1.0': [1, 2, 3],
         'desktop app 2.0': [10, 12, 13],
         'desktop app 3.0': [21, 22, 23],
         'website': [1, 2, 3],
         'ZulipiOS': [1, 2, 3],
         'ZulipElectron': [2, 5, 7],
         'ZulipMobile': [1, 5, 7],
         'ZulipPython': [1, 2, 3],
         'API: Python': [1, 2, 3],
         'SomethingRandom': [4, 5, 6],
         'ZulipGitHubWebhook': [7, 7, 9],
         'ZulipAndroid': [64, 63, 65]
     }
     result = rewrite_client_arrays(a)
     self.assertEqual(
         result, {
             'Old desktop app': [32, 36, 39],
             'Old iOS app': [1, 2, 3],
             'Desktop app': [2, 5, 7],
             'Mobile app': [1, 5, 7],
             'Website': [1, 2, 3],
             'Python API': [2, 4, 6],
             'SomethingRandom': [4, 5, 6],
             'GitHub webhook': [7, 7, 9],
             'Old Android app': [64, 63, 65]
         })
Ejemplo n.º 3
0
 def test_map_arrays(self):
     # type: () -> None
     a = {'desktop app 1.0': [1, 2, 3],
          'desktop app 2.0': [10, 12, 13],
          'desktop app 3.0': [21, 22, 23],
          'website': [1, 2, 3],
          'ZulipiOS': [1, 2, 3],
          'ZulipElectron': [2, 5, 7],
          'ZulipMobile': [1, 5, 7],
          'ZulipPython': [1, 2, 3],
          'API: Python': [1, 2, 3],
          'SomethingRandom': [4, 5, 6],
          'ZulipGitHubWebhook': [7, 7, 9],
          'ZulipAndroid': [64, 63, 65]}
     result = rewrite_client_arrays(a)
     self.assertEqual(result,
                      {'Old desktop app': [32, 36, 39],
                       'Old iOS app': [1, 2, 3],
                       'Desktop app': [2, 5, 7],
                       'Mobile app': [1, 5, 7],
                       'Website': [1, 2, 3],
                       'Python API': [2, 4, 6],
                       'SomethingRandom': [4, 5, 6],
                       'GitHub webhook': [7, 7, 9],
                       'Android app': [64, 63, 65]})