コード例 #1
0
ファイル: TextInterFace.py プロジェクト: rubik0cube/MyAirLine
        print "\n"

    elif n.strip() == "3":
        UserQuerying.getStaticalInfomation()
        print "\n"

    elif n.strip() == "4":
        cityCode = raw_input("Please type the city's code: \n")
        if UserQuerying.mapCity(cityCode.upper()) == False:
            print "Sorry, the city's code is invalid\n"

    elif n.strip() == "5":
        UserQueryingExpand.addCity()

    elif n.strip() == "6":
        UserQueryingExpand.removeCity()

    elif n.strip() == "7":
        UserQueryingExpand.addRoute()

    elif n.strip() == "8":
        UserQueryingExpand.removeRoute()

    elif n.strip() == "9":
        UserQueryingExpand.getRouteInfo()

    elif n.strip() == "10":
        UserQueryingExpand.editCity()

    elif n.strip() == "11":
        UserQueryingExpand.saveBackToJson()
コード例 #2
0
 def testRemoveCity(self):
     UserQueryingExpand.removeCity()
     key = 'Champaign'
     self.assertFalse(key in QueryingData.cityDicationary)