Esempio n. 1
0
 def test_013_slave_AP_client_num(self):
     u"""终端设备关联在Slave AP上,检查用户数量统计是否正确(testlink_ID:1155,1156)"""
     log.debug("013")
     #新增一个ssid
     NG2_ssid = "%s-2"%data_ng["NG2_ssid"]
     Add = SSIDBusiness(self.driver)
     Add.new_vlan_ssid(NG2_ssid,data_wireless["short_wpa"],"2")
     #多个网络组时,搜索-配对-加入ssid
     tmp1 = APSBusiness(self.driver)
     tmp1.search_pair_add(2,data_ap["slave:mac2"])
     #使用无线连接slave AP
     tmp1.connect_DHCP_WPA_AP(NG2_ssid,\
                 data_wireless["short_wpa"],data_basic['wlan_pc'])
     #等待2分钟
     time.sleep(120)
     tmp = OVBusiness(self.driver)
     tmp.OV_menu()
     #获取2.4G客户端数
     result1 = tmp.get_2g4_client()
     #获取5G客户端数
     result2 = tmp.get_5g_client()
     #释放无线网卡的ip
     tmp.dhcp_release_wlan(data_basic['wlan_pc'])
     tmp.disconnect_ap()
     assert (result1 == "1") or (result2 == "1"),\
         "check clients number when client connect slave AP,test fail!"
     print "check clients number when client connect slave AP,test pass!"
Esempio n. 2
0
    def test_032_client_download(self):
        u"""client 下载流量统计的准确性(testlink_ID:1225)"""
        log.debug("032")
        #client下载流量统计的准确性
        tmp = OVBusiness(self.driver)
        result1,result2 = tmp.check_client_download()

        #测试完毕,禁用无线网卡,使pc能够上网
        tmp.dhcp_release_wlan(data_basic['wlan_pc'])
        tmp.disconnect_ap()
        tmp.wlan_disable(data_basic['wlan_pc'])
        #rsyslog服务器完成工作
        tmp.finish_rsyslog("OverView")

        assert ("MB" in result1) or ("GB" in result1),"test client upload fail!"
        print "test client upload pass!"
Esempio n. 3
0
 def test_010_clients_num(self):
     u"""2.4G/5G 用户数量统计(testlink_ID:1151,1152)"""
     log.debug("010")
     tmp = OVBusiness(self.driver)
     #获取2.4G客户端数
     result1 = tmp.get_2g4_client()
     #获取5G客户端数
     result2 = tmp.get_5g_client()
     #释放无线网卡的ip
     tmp.dhcp_release_wlan(data_basic['wlan_pc'])
     #AP切换到2.4G
     Lg = LoginBusiness(self.driver)
     Lg.refresh_login_ap()
     tmp1 = SSIDBusiness(self.driver)
     tmp1.change_AP_Freq("2.4GHz")
     assert (result1 == "1") or (result2 == "1"),"check clients number,test fail!"
     print "check clients number,test pass!"
Esempio n. 4
0
 def test_011_2g4_client_num(self):
     u"""终端设备在2.4G上, 检查用户数量统计是否正确(testlink_ID:1153_1)"""
     log.debug("011")
     tmp = OVBusiness(self.driver)
     #使用无线连接该AP
     tmp.connect_DHCP_WPA_AP(data_wireless['all_ssid'],\
                 data_wireless["short_wpa"],data_basic['wlan_pc'])
     #等待2分钟
     time.sleep(120)
     #获取2.4G客户端数
     result = tmp.get_2g4_client()
     #释放无线网卡的ip
     tmp.dhcp_release_wlan(data_basic['wlan_pc'])
     #AP切换到5G
     Lg = LoginBusiness(self.driver)
     Lg.refresh_login_ap()
     tmp1 = SSIDBusiness(self.driver)
     tmp1.change_AP_Freq("5GHz")
     assert result == "1","check 2.4G client number,test fail!"
     print "check 2.4G client number,test pass!"
Esempio n. 5
0
 def test_012_5g_client_num(self):
     u"""终端设备在5G上, 检查用户数量统计是否正确(testlink_ID:1153_2)"""
     log.debug("012")
     tmp = OVBusiness(self.driver)
     #使用无线连接该AP
     tmp.connect_DHCP_WPA_AP(data_wireless['all_ssid'],\
                 data_wireless["short_wpa"],data_basic['wlan_pc'])
     time.sleep(120)
     # 获取5G客户端数
     result = tmp.get_5g_client()
     tmp.dhcp_release_wlan(data_basic['wlan_pc'])
     #释放无线网卡的ip
     tmp.disconnect_ap()
     #AP切换到双频
     #切换Dual-Band频段
     Lg = LoginBusiness(self.driver)
     Lg.refresh_login_ap()
     tmp1 = SSIDBusiness(self.driver)
     tmp1.change_AP_Freq("Dual-Band")
     #7000上新建一个网络组,vid设为2,开启dhcp server
     tmp2 = NGBusiness(self.driver)
     tmp2.mixed_7000_new_NG()
     assert result == "1","check 5G client number,test fail!"
     print "check 5G client number,test pass!"