本文整理匯總了Python中Infrastructure.MobberManager.MobberManager.get_mobbers方法的典型用法代碼示例。如果您正苦於以下問題:Python MobberManager.get_mobbers方法的具體用法?Python MobberManager.get_mobbers怎麽用?Python MobberManager.get_mobbers使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類Infrastructure.MobberManager.MobberManager
的用法示例。
在下文中一共展示了MobberManager.get_mobbers方法的6個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Python代碼示例。
示例1: test_clear
# 需要導入模塊: from Infrastructure.MobberManager import MobberManager [as 別名]
# 或者: from Infrastructure.MobberManager.MobberManager import get_mobbers [as 別名]
def test_clear(self):
mobber_manager = MobberManager()
mobber_manager.add_mobber("Joe")
mobber_manager.add_mobber("Chris")
mobber_manager.add_mobber("Sam")
mobber_manager.clear()
result = []
self.assertEqual(mobber_manager.get_mobbers(), result)
示例2: test_add_mobber_joe_chris_joe__remove_joe_has_joe_chris
# 需要導入模塊: from Infrastructure.MobberManager import MobberManager [as 別名]
# 或者: from Infrastructure.MobberManager.MobberManager import get_mobbers [as 別名]
def test_add_mobber_joe_chris_joe__remove_joe_has_joe_chris(self):
mobber_manager = MobberManager()
mobber_manager.add_mobber("Joe")
mobber_manager.add_mobber("Chris")
mobber_manager.add_mobber("John")
mobber_manager.remove_mobber(2)
result = ["Joe", "Chris"]
self.assertEqual(mobber_manager.get_mobbers(), result)
示例3: test_add_4_mobbers_move_down_bottom
# 需要導入模塊: from Infrastructure.MobberManager import MobberManager [as 別名]
# 或者: from Infrastructure.MobberManager.MobberManager import get_mobbers [as 別名]
def test_add_4_mobbers_move_down_bottom(self):
mobber_manager = MobberManager()
mobber_manager.add_mobber("Joe")
mobber_manager.add_mobber("Chris")
mobber_manager.add_mobber("Will")
mobber_manager.add_mobber("Eric")
mobber_manager.move_mobber_down(3)
result = ["Eric", "Chris", "Will", "Joe"]
self.assertEqual(mobber_manager.get_mobbers(), result)
示例4: test_add_4_mobbers_move_up_middle
# 需要導入模塊: from Infrastructure.MobberManager import MobberManager [as 別名]
# 或者: from Infrastructure.MobberManager.MobberManager import get_mobbers [as 別名]
def test_add_4_mobbers_move_up_middle(self):
mobber_manager = MobberManager()
mobber_manager.add_mobber("Joe")
mobber_manager.add_mobber("Chris")
mobber_manager.add_mobber("Will")
mobber_manager.add_mobber("Eric")
mobber_manager.move_mobber_up(2)
result = ["Joe", "Will", "Chris", "Eric"]
self.assertEqual(mobber_manager.get_mobbers(), result)
示例5: test_remove_empty
# 需要導入模塊: from Infrastructure.MobberManager import MobberManager [as 別名]
# 或者: from Infrastructure.MobberManager.MobberManager import get_mobbers [as 別名]
def test_remove_empty(self):
mobber_manager = MobberManager()
mobber_manager.remove_mobber(0)
result = []
self.assertEqual(mobber_manager.get_mobbers(), result)
示例6: test_add_mobber_chris_has_chris
# 需要導入模塊: from Infrastructure.MobberManager import MobberManager [as 別名]
# 或者: from Infrastructure.MobberManager.MobberManager import get_mobbers [as 別名]
def test_add_mobber_chris_has_chris(self):
mobber_manager = MobberManager()
mobber_manager.add_mobber("Chris")
result = ["Chris"]
self.assertEqual(mobber_manager.get_mobbers(), result)