Debian Codegraph @

wifi/tests/README.md

raw symbols SCIP
1 # Wifi Non-Updatable Framework Unit Tests
2 This package contains unit tests for the non-updatable part (i.e. outside the Wifi module) of the
3 Android Wifi framework APIs based on the
4 [Android Testing Support Library](http://developer.android.com/tools/testing-support-library/index.html).
5 The test cases are built using the [JUnit](http://junit.org/) and [Mockito](http://mockito.org/)
6 libraries.
7
8 ## Running Tests
9 The easiest way to run tests is simply run
10
11 ```
12 atest android.net.wifi
13 ```
14
15 To pick up changes in framework/base, you will need to:
16 1. rebuild the framework library 'make -j32'
17 2. sync over the updated library to the device 'adb sync'
18 3. restart framework on the device 'adb shell stop' then 'adb shell start'
19
20 To enable syncing data to the device for first time after clean reflash:
21 1. adb disable-verity
22 2. adb reboot
23 3. adb remount
24
25 ## Adding Tests
26 Tests can be added by adding classes to the src directory. JUnit4 style test cases can
27 be written by simply annotating test methods with `org.junit.Test`.
28
29 ## Debugging Tests
30 If you are trying to debug why tests are not doing what you expected, you can add android log
31 statements and use logcat to view them. The beginning and end of every tests is automatically logged
32 with the tag `TestRunner`.