• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1#!/usr/bin/env python3.4
2#
3#   Copyright 2016 - The Android Open Source Project
4#
5#   Licensed under the Apache License, Version 2.0 (the "License");
6#   you may not use this file except in compliance with the License.
7#   You may obtain a copy of the License at
8#
9#       http://www.apache.org/licenses/LICENSE-2.0
10#
11#   Unless required by applicable law or agreed to in writing, software
12#   distributed under the License is distributed on an "AS IS" BASIS,
13#   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14#   See the License for the specific language governing permissions and
15#   limitations under the License.
16
17import time
18
19from acts import asserts
20from acts import base_test
21from acts.test_decorators import test_tracker_info
22from acts_contrib.test_utils.wifi import wifi_constants
23from acts_contrib.test_utils.wifi import wifi_test_utils as wutils
24from acts_contrib.test_utils.wifi.WifiBaseTest import WifiBaseTest
25
26WifiEnums = wutils.WifiEnums
27NETWORK_ID_ERROR = "Network don't have ID"
28NETWORK_ERROR = "Device is not connected to reference network"
29
30
31class WifiNewSetupAutoJoinTest(WifiBaseTest):
32
33    def __init__(self, configs):
34        super().__init__(configs)
35        self.enable_packet_log = True
36
37    def add_network_and_enable(self, network):
38        """Add a network and enable it.
39
40        Args:
41            network : Network details for the network to be added.
42
43        """
44        ret = self.dut.droid.wifiAddNetwork(network)
45        asserts.assert_true(ret != -1, "Add network %r failed" % network)
46        self.dut.droid.wifiEnableNetwork(ret, 0)
47
48    def setup_class(self):
49        """It will setup the required dependencies from config file and configure
50           the required networks for auto-join testing. Configured networks will
51           not be removed. If networks are already configured it will skip
52           configuring the networks
53
54        Returns:
55            True if successfully configured the requirements for testing.
56        """
57        super().setup_class()
58
59        self.dut = self.android_devices[0]
60        wutils.wifi_test_device_init(self.dut)
61        req_params = ("atten_val", "ping_addr")
62        opt_param = ["reference_networks"]
63        self.unpack_userparams(
64            req_param_names=req_params, opt_param_names=opt_param)
65
66        if "AccessPoint" in self.user_params:
67            self.legacy_configure_ap_and_start(ap_count=2)
68
69        configured_networks = self.dut.droid.wifiGetConfiguredNetworks()
70        self.log.debug("Configured networks :: {}".format(configured_networks))
71        count_confnet = 0
72        result = False
73        if self.reference_networks[0]['2g']['SSID'] == self.reference_networks[
74                0]['5g']['SSID']:
75            self.ref_ssid_count = 1
76        else:
77            self.ref_ssid_count = 2  # Different SSID for 2g and 5g
78        for confnet in configured_networks:
79            if confnet[WifiEnums.SSID_KEY] == self.reference_networks[0]['2g'][
80                    'SSID']:
81                count_confnet += 1
82            elif confnet[WifiEnums.SSID_KEY] == self.reference_networks[0][
83                    '5g']['SSID']:
84                count_confnet += 1
85        self.log.info("count_confnet {}".format(count_confnet))
86        if count_confnet == self.ref_ssid_count:
87            return
88        else:
89            self.log.info("Configured networks for testing")
90            self.dut.droid.wakeLockAcquireBright()
91            self.dut.droid.wakeUpNow()
92            # Add and enable all networks.
93            for network in self.reference_networks:
94                self.add_network_and_enable(network['2g'])
95                self.add_network_and_enable(network['5g'])
96            self.dut.droid.wifiLockRelease()
97            self.dut.droid.goToSleepNow()
98
99    def check_connection(self, network_bssid):
100        """Check current wifi connection networks.
101        Args:
102            network_bssid: Network bssid to which connection.
103        Returns:
104            True if connection to given network happen, else return False.
105        """
106        time.sleep(40)  #time for connection state to be updated
107        self.log.info("Check network for {}".format(network_bssid))
108        current_network = self.dut.droid.wifiGetConnectionInfo()
109        self.log.debug("Current network:  {}".format(current_network))
110        if WifiEnums.BSSID_KEY in current_network:
111            return current_network[WifiEnums.BSSID_KEY] == network_bssid
112        return False
113
114    def set_attn_and_validate_connection(self, attn_value, bssid):
115        """Validate wifi connection status on different attenuation setting.
116
117        Args:
118            attn_value: Attenuation value for different APs signal.
119            bssid: Bssid of expected network.
120
121        Returns:
122            True if bssid of current network match, else false.
123        """
124        self.attenuators[0].set_atten(attn_value[0])
125        self.attenuators[1].set_atten(attn_value[1])
126        self.attenuators[2].set_atten(attn_value[2])
127        self.attenuators[3].set_atten(attn_value[3])
128        time.sleep(10) # wait time for attenuation
129        self.dut.droid.wakeLockAcquireBright()
130        self.dut.droid.wakeUpNow()
131        try:
132            asserts.assert_true(
133                self.check_connection(bssid),
134                "Device is not connected to required bssid {}".format(bssid))
135            time.sleep(10)  #wait for connection to be active
136            asserts.assert_true(
137                wutils.validate_connection(self.dut, self.ping_addr),
138                "Error, No Internet connection for current bssid {}".format(
139                    bssid))
140        finally:
141            self.dut.droid.wifiLockRelease()
142            self.dut.droid.goToSleepNow()
143
144    def teardown_class(self):
145        for ad in self.android_devices:
146            wutils.reset_wifi(ad)
147        if "AccessPoint" in self.user_params:
148            del self.user_params["reference_networks"]
149            del self.user_params["open_network"]
150
151    def setup_test(self):
152        super().setup_test()
153        # initialize attenuators
154        self.attenuators[0].set_atten(0)
155        self.attenuators[1].set_atten(0)
156        self.attenuators[2].set_atten(90)
157        self.attenuators[3].set_atten(90)
158
159
160    """ Tests Begin """
161
162    """ Test wifi auto join functionality move in range of AP1.
163
164        1. Attenuate the signal to low range of AP1 and Ap2 not visible at all.
165        2. Wake up the device.
166        3. Check that device is connected to right BSSID and maintain stable
167           connection to BSSID in range.
168    """
169    @test_tracker_info(uuid="9ea2c78d-d305-497f-87a5-f621f0a4b34e")
170    def test_autojoin_Ap1_2g_AP1_20_AP2_95_AP3_95(self):
171        att0, att1, att2, att3 = self.atten_val["Ap1_2g"]
172        variance = 5
173        attn_value = [att0 + variance * 2, att1, att2, att3]
174        self.set_attn_and_validate_connection(
175            attn_value, self.reference_networks[0]["2g"]['bssid'])
176
177    @test_tracker_info(uuid="7c34a508-2ffa-4bca-82b3-9637b7c8250a")
178    def test_autojoin_Ap1_2g_AP1_15_AP2_95_AP3_95(self):
179        att0, att1, att2, att3 = self.atten_val["Ap1_2g"]
180        variance = 5
181        attn_value = [att0 + variance, att1, att2, att3]
182        self.set_attn_and_validate_connection(
183            attn_value, self.reference_networks[0]["2g"]['bssid'])
184
185    @test_tracker_info(uuid="ea614fcc-7fca-4172-ba3a-5978427eb40f")
186    def test_autojoin_Ap1_2g_AP1_10_AP2_95_AP3_95(self):
187        att0, att1, att2, att3 = self.atten_val["Ap1_2g"]
188        variance = 5
189        attn_value = [att0, att1, att2, att3]
190        self.set_attn_and_validate_connection(
191            attn_value, self.reference_networks[0]["2g"]['bssid'])
192
193    @test_tracker_info(uuid="a1ad25cf-11e7-4240-b3c0-9f14325d5b2d")
194    def test_autojoin_Ap1_2g_AP1_5_AP2_95_AP3_95(self):
195        att0, att1, att2, att3 = self.atten_val["Ap1_2g"]
196        variance = 5
197        attn_value = [att0 - variance, att1, att2, att3]
198        self.set_attn_and_validate_connection(
199            attn_value, self.reference_networks[0]["2g"]['bssid'])
200
201    """ Test wifi auto join functionality move to high range.
202
203        1. Attenuate the signal to high range of AP1.
204        2. Wake up the device.
205        3. Check that device is connected to right BSSID and maintain stable
206           connection to BSSID in range.
207    """
208    @test_tracker_info(uuid="b5eba5ec-96e5-4bd8-b483-f5b2a9504558")
209    def test_autojoin_Ap1_2gto5g_AP1_55_AP2_10_AP3_95(self):
210        att0, att1, att2, attn3 = self.atten_val["Ap1_2gto5g"]
211        variance = 5
212        attn_value = [att0 + variance * 2, att1, att2, attn3]
213        self.set_attn_and_validate_connection(
214            attn_value, self.reference_networks[0]["5g"]['bssid'])
215
216    @test_tracker_info(uuid="e63543f7-5f43-4ba2-a5bd-2af3c159a622")
217    def test_autojoin_Ap1_2gto5g_AP1_50_AP2_10_AP3_95(self):
218        att0, att1, att2, attn3 = self.atten_val["Ap1_2gto5g"]
219        variance = 5
220        attn_value = [att0 + variance, att1, att2, attn3]
221        self.set_attn_and_validate_connection(
222            attn_value, self.reference_networks[0]["5g"]['bssid'])
223
224    @test_tracker_info(uuid="0c2cef5d-695d-4d4e-832d-f5e8b393a09c")
225    def test_autojoin_Ap1_2gto5g_AP1_45_AP2_10_AP3_95(self):
226        att0, att1, att2, attn3 = self.atten_val["Ap1_2gto5g"]
227        variance = 5
228        attn_value = [att0, att1, att2, attn3]
229        self.set_attn_and_validate_connection(
230            attn_value, self.reference_networks[0]["5g"]['bssid'])
231
232    """ Test wifi auto join functionality move to low range toward AP2.
233
234        1. Attenuate the signal to medium range of AP1 and low range of AP2.
235        2. Wake up the device.
236        3. Check that device is connected to right BSSID and maintain stable
237           connection to BSSID in range.
238    """
239    @test_tracker_info(uuid="37822578-d35c-462c-87c0-7a2d9252938c")
240    def test_autojoin_in_AP1_5gto2g_AP1_5_AP2_80_AP3_95(self):
241        att0, att1, att2, attn3 = self.atten_val["In_AP1_5gto2g"]
242        variance = 5
243        attn_value = [att0 - variance, att1 + variance, att2, attn3]
244        self.set_attn_and_validate_connection(
245            attn_value, self.reference_networks[0]["2g"]['bssid'])
246
247    @test_tracker_info(uuid="194ffe44-9718-4beb-b69e-cccb569f9b81")
248    def test_autojoin_in_AP1_5gto2g_AP1_10_AP2_75_AP3_95(self):
249        att0, att1, att2, attn3 = self.atten_val["In_AP1_5gto2g"]
250        variance = 5
251        attn_value = [att0, att1, att2, attn3]
252        self.set_attn_and_validate_connection(
253            attn_value, self.reference_networks[0]["2g"]['bssid'])
254
255    @test_tracker_info(uuid="09bdcb0f-7833-4604-a839-f7d981bf4aca")
256    def test_autojoin_in_AP1_5gto2g_AP1_15_AP2_70_AP3_95(self):
257        att0, att1, att2, attn3 = self.atten_val["In_AP1_5gto2g"]
258        variance = 5
259        attn_value = [att0 + variance, att1 - variance, att2, attn3]
260        self.set_attn_and_validate_connection(
261            attn_value, self.reference_networks[0]["2g"]['bssid'])
262
263    """ Test wifi auto join functionality move from low range of AP1 to better
264        range of AP2.
265
266        1. Attenuate the signal to low range of AP1 and medium range of AP2.
267        2. Wake up the device.
268        3. Check that device is connected to right BSSID and maintain stable
269            connection to BSSID in range.
270    """
271    @test_tracker_info(uuid="8ffdcab1-2bfb-4acd-b1e8-089ba8a4ec41")
272    def test_autojoin_swtich_AP1toAp2_AP1_65_AP2_75_AP3_2(self):
273        att0, att1, att2, attn3 = self.atten_val["Swtich_AP1toAp2"]
274        variance = 5
275        attn_value = [att0 - variance, att1 + variance, att2, attn3]
276        self.set_attn_and_validate_connection(
277            attn_value, self.reference_networks[1]["2g"]['bssid'])
278
279    @test_tracker_info(uuid="23e05821-3c53-4033-830e-a446b6105831")
280    def test_autojoin_swtich_AP1toAp2_AP1_70_AP2_70_AP3_2(self):
281        att0, att1, att2, attn3 = self.atten_val["Swtich_AP1toAp2"]
282        variance = 5
283        attn_value = [att0, att1, att2, attn3]
284        self.set_attn_and_validate_connection(
285            attn_value, self.reference_networks[1]["2g"]['bssid'])
286
287    @test_tracker_info(uuid="a56ad87d-d37f-4606-9ae8-af6f55cbb6cf")
288    def test_autojoin_swtich_AP1toAp2_AP1_75_AP2_65_AP3_2(self):
289        att0, att1, att2, attn3 = self.atten_val["Swtich_AP1toAp2"]
290        variance = 5
291        attn_value = [att0 + variance, att1 - variance, att2, attn3]
292        self.set_attn_and_validate_connection(
293            attn_value, self.reference_networks[1]["2g"]['bssid'])
294
295    """ Test wifi auto join functionality move to high range of AP2.
296
297        1. Attenuate the signal to out range of AP1 and high range of AP2.
298        2. Wake up the device.
299        3. Check that device is connected to right BSSID and maintain stable
300           connection to BSSID in range.
301    """
302    @test_tracker_info(uuid="7a8b9242-f93c-449a-90a6-4562274a213a")
303    def test_autojoin_Ap2_2gto5g_AP1_70_AP2_85_AP3_75(self):
304        att0, att1, att2, attn3 = self.atten_val["Ap2_2gto5g"]
305        variance = 5
306        attn_value = [att0 - variance, att1 + variance * 2, att2, attn3]
307        self.set_attn_and_validate_connection(
308            attn_value, self.reference_networks[1]["5g"]['bssid'])
309
310    @test_tracker_info(uuid="5e0c5485-a3ae-438a-92e5-9a6b5a22cb82")
311    def test_autojoin_Ap2_2gto5g_AP1_75_AP2_80_AP3_75(self):
312        att0, att1, att2, attn3 = self.atten_val["Ap2_2gto5g"]
313        variance = 5
314        attn_value = [att0, att1 + variance, att2, attn3]
315        self.set_attn_and_validate_connection(
316            attn_value, self.reference_networks[1]["5g"]['bssid'])
317
318    @test_tracker_info(uuid="3b289144-a12a-424f-822e-8d173d75c3c3")
319    def test_autojoin_Ap2_2gto5g_AP1_75_AP2_75_AP3_75(self):
320        att0, att1, att2, attn3 = self.atten_val["Ap2_2gto5g"]
321        variance = 5
322        attn_value = [att0, att1, att2, attn3]
323        self.set_attn_and_validate_connection(
324            attn_value, self.reference_networks[1]["5g"]['bssid'])
325
326    """ Test wifi auto join functionality move to low range of AP2.
327
328        1. Attenuate the signal to low range of AP2.
329        2. Wake up the device.
330        3. Check that device is connected to right BSSID and maintain stable.
331    """
332    @test_tracker_info(uuid="009457df-f430-402c-96ab-c456b043b6f5")
333    def test_autojoin_Ap2_5gto2g_AP1_75_AP2_70_AP3_10(self):
334        att0, att1, att2, attn3 = self.atten_val["Ap2_5gto2g"]
335        variance = 5
336        attn_value = [att0, att1 - variance, att2, attn3]
337        self.set_attn_and_validate_connection(
338            attn_value, self.reference_networks[1]["2g"]['bssid'])
339
340    @test_tracker_info(uuid="15ef731c-ddfb-4118-aedb-c177f50bdea0")
341    def test_autojoin_Ap2_5gto2g_AP1_75_AP2_75_AP3_10(self):
342        att0, att1, att2, attn3 = self.atten_val["Ap2_5gto2g"]
343        variance = 5
344        attn_value = [att0, att1, att2, attn3]
345        self.set_attn_and_validate_connection(
346            attn_value, self.reference_networks[1]["2g"]['bssid'])
347
348    @test_tracker_info(uuid="f79b0570-56a0-43d2-962d-9e114d48bacf")
349    def test_autojoin_Ap2_5gto2g_AP1_75_AP2_80_AP3_10(self):
350        att0, att1, att2, attn3 = self.atten_val["Ap2_5gto2g"]
351        variance = 5
352        attn_value = [att0, att1 + variance, att2, attn3]
353        self.set_attn_and_validate_connection(
354            attn_value, self.reference_networks[1]["2g"]['bssid'])
355
356    @test_tracker_info(uuid="c6d070af-b601-42f1-adec-5ac564154b29")
357    def test_autojoin_out_of_range(self):
358        """Test wifi auto join functionality move to low range.
359
360         1. Attenuate the signal to out of range.
361         2. Wake up the device.
362         3. Start the scan.
363         4. Check that device is not connected to any network.
364        """
365        self.attenuators[0].set_atten(90)
366        self.attenuators[1].set_atten(90)
367        self.attenuators[2].set_atten(90)
368        self.attenuators[3].set_atten(90)
369        self.dut.droid.wakeLockAcquireBright()
370        self.dut.droid.wakeUpNow()
371        try:
372            wutils.start_wifi_connection_scan(self.dut)
373            wifi_results = self.dut.droid.wifiGetScanResults()
374            self.log.debug("Scan result {}".format(wifi_results))
375            time.sleep(20)
376            current_network = self.dut.droid.wifiGetConnectionInfo()
377            self.log.info("Current network: {}".format(current_network))
378            asserts.assert_true(
379                ('network_id' in current_network and
380                 current_network['network_id'] == -1),
381                "Device is connected to network {}".format(current_network))
382        finally:
383            self.dut.droid.wifiLockRelease()
384            self.dut.droid.goToSleepNow()
385
386    """ Test wifi auto join functionality move in low range of AP2.
387
388        1. Attenuate the signal to move in range of AP2 and Ap1 not visible at all.
389        2. Wake up the device.
390        3. Check that device is connected to right BSSID and maintain stable
391           connection to BSSID in range.
392    """
393    @test_tracker_info(uuid="15c27654-bae0-4d2d-bdc8-54fb04b901d1")
394    def test_autojoin_Ap2_2g_AP1_75_AP2_85_AP3_10(self):
395        att0, att1, att2, attn3 = self.atten_val["Ap2_2g"]
396        variance = 5
397        attn_value = [att0, att1 + variance * 2, att2, attn3]
398        self.set_attn_and_validate_connection(
399            attn_value, self.reference_networks[1]["2g"]['bssid'])
400
401    @test_tracker_info(uuid="af40824a-4d65-4789-980f-d534abeca36b")
402    def test_autojoin_Ap2_2g_AP1_75_AP2_80_AP3_10(self):
403        att0, att1, att2, attn3 = self.atten_val["Ap2_2g"]
404        variance = 5
405        attn_value = [att0, att1 + variance, att2, attn3]
406        self.set_attn_and_validate_connection(
407            attn_value, self.reference_networks[1]["2g"]['bssid'])
408
409    @test_tracker_info(uuid="2d482060-9865-472b-810b-c74c6a099e6c")
410    def test_autojoin_Ap2_2g_AP1_75_AP2_75_AP3_10(self):
411        att0, att1, att2, attn3 = self.atten_val["Ap2_2g"]
412        variance = 5
413        attn_value = [att0, att1, att2, attn3]
414        self.set_attn_and_validate_connection(
415            attn_value, self.reference_networks[1]["2g"]['bssid'])
416
417    @test_tracker_info(uuid="b5cad09e-6e31-40f4-a568-2a1d5271e20c")
418    def test_autojoin_Ap2_2g_AP1_75_AP2_70_AP3_10(self):
419        att0, att1, att2, attn3 = self.atten_val["Ap2_2g"]
420        variance = 5
421        attn_value = [att0, att1 - variance, att2, attn3]
422        self.set_attn_and_validate_connection(
423            attn_value, self.reference_networks[1]["2g"]['bssid'])
424
425    """ Test wifi auto join functionality move to medium range of Ap2 and
426        low range of AP1.
427
428        1. Attenuate the signal to move in medium range of AP2 and low range of AP1.
429        2. Wake up the device.
430        3. Check that device is connected to right BSSID and maintain stable
431           connection to BSSID in range.
432    """
433    @test_tracker_info(uuid="80e74c78-59e2-46db-809d-cb03bd1b6824")
434    def test_autojoin_in_Ap2_5gto2g_AP1_75_AP2_70_AP3_10(self):
435        att0, att1, att2, attn3 = self.atten_val["In_Ap2_5gto2g"]
436        variance = 5
437        attn_value = [att0, att1 - variance, att2, attn3]
438        self.set_attn_and_validate_connection(
439            attn_value, self.reference_networks[1]["2g"]['bssid'])
440
441    @test_tracker_info(uuid="d2a188bd-91cf-4412-a098-739c0c236fe1")
442    def test_autojoin_in_Ap2_5gto2g_AP1_75_AP2_75_AP3_10(self):
443        att0, att1, att2, attn3 = self.atten_val["In_Ap2_5gto2g"]
444        variance = 5
445        attn_value = [att0, att1, att2, attn3]
446        self.set_attn_and_validate_connection(
447            attn_value, self.reference_networks[1]["2g"]['bssid'])
448
449    @test_tracker_info(uuid="032e81e9-bc8a-4fa2-a96b-d733c241869e")
450    def test_autojoin_in_Ap2_5gto2g_AP1_75_AP2_80_AP3_10(self):
451        att0, att1, att2, attn3 = self.atten_val["In_Ap2_5gto2g"]
452        variance = 5
453        attn_value = [att0, att1 + variance, att2, attn3]
454        self.set_attn_and_validate_connection(
455            attn_value, self.reference_networks[1]["2g"]['bssid'])
456
457    """ Test wifi auto join functionality move from low range of AP2 to better
458        range of AP1.
459
460        1. Attenuate the signal to low range of AP2 and medium range of AP1.
461        2. Wake up the device.
462        3. Check that device is connected to right BSSID and maintain stable
463           connection to BSSID in range.
464    """
465    @test_tracker_info(uuid="01faeba0-bd66-4d30-a3d9-b81e959025b2")
466    def test_autojoin_swtich_AP2toAp1_AP1_15_AP2_65_AP3_75(self):
467        att0, att1, att2, attn3 = self.atten_val["Swtich_AP2toAp1"]
468        variance = 5
469        attn_value = [att0 + variance, att1 - variance, att2, attn3]
470        self.set_attn_and_validate_connection(
471            attn_value, self.reference_networks[0]["2g"]['bssid'])
472
473    @test_tracker_info(uuid="68b15c50-03ab-4385-9231-280002315fe5")
474    def test_autojoin_swtich_AP2toAp1_AP1_10_AP2_70_AP3_75(self):
475        att0, att1, att2, attn3 = self.atten_val["Swtich_AP2toAp1"]
476        variance = 5
477        attn_value = [att0, att1, att2, attn3]
478        self.set_attn_and_validate_connection(
479            attn_value, self.reference_networks[0]["2g"]['bssid'])
480
481    @test_tracker_info(uuid="1986d79b-097e-44c9-9aff-7bcd56490c3b")
482    def test_autojoin_swtich_AP2toAp1_AP1_5_AP2_75_AP3_75(self):
483        att0, att1, att2, attn3 = self.atten_val["Swtich_AP2toAp1"]
484        variance = 5
485        attn_value = [att0 - variance, att1 + variance, att2, attn3]
486        self.set_attn_and_validate_connection(
487            attn_value, self.reference_networks[0]["2g"]['bssid'])
488
489    """ Test wifi auto join functionality move to medium range of AP1.
490
491        1. Attenuate the signal to medium range of AP1.
492        2. Wake up the device.
493        3. Check that device is connected to right BSSID and maintain stable
494           connection to BSSID in range.
495    """
496    @test_tracker_info(uuid="ec509d40-e339-47c2-995e-cc77f5a28687")
497    def test_autojoin_Ap1_5gto2g_AP1_10_AP2_80_AP3_95(self):
498        att0, att1, att2, attn3 = self.atten_val["Ap1_5gto2g"]
499        variance = 5
500        attn_value = [att0, att1, att2, attn3]
501        self.set_attn_and_validate_connection(
502            attn_value, self.reference_networks[0]["2g"]['bssid'])
503
504    @test_tracker_info(uuid="ddc66d1e-3241-4040-996a-85bc2a2a4d67")
505    def test_autojoin_Ap1_5gto2g_AP1_15_AP2_80_AP3_95(self):
506        att0, att1, att2, attn3 = self.atten_val["Ap1_5gto2g"]
507        variance = 5
508        attn_value = [att0 + variance, att1, att2, attn3]
509        self.set_attn_and_validate_connection(
510            attn_value, self.reference_networks[0]["2g"]['bssid'])
511
512    @test_tracker_info(uuid="dfc84504-230f-428e-b701-edc496d0e7b3")
513    def test_autojoin_Ap1_5gto2g_AP1_20_AP2_80_AP3_95(self):
514        att0, att1, att2, attn3 = self.atten_val["Ap1_5gto2g"]
515        variance = 5
516        attn_value = [att0 + variance * 2, att1, att2, attn3]
517        self.set_attn_and_validate_connection(
518            attn_value, self.reference_networks[0]["2g"]['bssid'])
519
520    """ Tests End """
521