class Test_make_map_label(Bf3TestCase):
    def setUp(self):
        Bf3TestCase.setUp(self)
        self.conf = CfgConfigParser()
        self.p = VotemapPlugin(self.console, self.conf)
        self.p.onLoadConfig()
        self.p.onStartup()

    def test_nominal(self):
        self.assertEqual("Caspian Border (Rush)", self.p._make_map_label({"gamemode": "RushLarge0", "name": "MP_007"}))

    def test_unknown_gamemode(self):
        self.assertEqual("Caspian Border", self.p._make_map_label({"gamemode": "Elimination0", "name": "MP_007"}))

    def test_unknown_map(self):
        self.assertEqual("f00 (Rush)", self.p._make_map_label({"gamemode": "RushLarge0", "name": "f00"}))
class Test_make_map_label(Bf4TestCase):
    def setUp(self):
        Bf4TestCase.setUp(self)
        self.conf = CfgConfigParser()
        self.p = VotemapPlugin(self.console, self.conf)
        self.p.onLoadConfig()
        self.p.onStartup()

    def test_nominal(self):
        self.assertEqual(
            "Operation Locker (Defuse)", self.p._make_map_label({"gamemode": "Elimination0", "name": "MP_Prison"})
        )

    def test_unknown_gamemode(self):
        self.assertEqual("Siege of Shanghai", self.p._make_map_label({"gamemode": "f00", "name": "MP_Siege"}))

    def test_unknown_map(self):
        self.assertEqual("f00 (Rush)", self.p._make_map_label({"gamemode": "RushLarge0", "name": "f00"}))