aboutsummaryrefslogtreecommitdiff
path: root/en/compatibility/cts/development.html
diff options
context:
space:
mode:
authorAndroid Partner Docs <noreply@android.com>2017-06-19 21:12:35 -0700
committerClay Murphy <claym@google.com>2017-06-20 13:09:22 -0700
commitd72514453123a8634ae55406807d77f03362a2bd (patch)
treeb528f70cbfa22decfea5899870efc1a42e7b7778 /en/compatibility/cts/development.html
parent8560a623b8040782583740e9dd1cbc4be310a568 (diff)
downloadsource.android.com-d72514453123a8634ae55406807d77f03362a2bd.tar.gz
Docs: Changes to source.android.com
- 159519221 Add CTS Media 1.3 file link by claym <claym@google.com> - 159296442 Changed devsite tag classes on a couple pages. by cqn <cqn@google.com> - 159296357 Add devsite class to tags in devices/tech/power by cqn <cqn@google.com> - 159296314 Added devsite class to tags in compatibility/cts. by cqn <cqn@google.com> - 159296265 Added devsite class to tags in devices/tech/ota. by cqn <cqn@google.com> - 159273197 Added devsite class to tags for devices/tech/test_infra/t... by cqn <cqn@google.com> - 159269559 Add speed-profile and verify-profile to the list of options by claym <claym@google.com> - 159268556 Add devsite class to tags in devices/tech/display by cqn <cqn@google.com> - 159247742 Add devsite class to tags in devices/tech/admin by cqn <cqn@google.com> - 159246177 Finished adding devsite class to tags on devices/tech/debug by cqn <cqn@google.com> - 159245597 Add devsite tag to classes in devices/tech/debug by cqn <cqn@google.com> - 159128910 Changed breaks to paragraph tags for formatting, and adde... by cqn <cqn@google.com> - 159115811 Add devsite class to tags for devices/tech/config by cqn <cqn@google.com> - 159115392 Added devsite class to tags on devices/tech/connect and d... by cqn <cqn@google.com> - 159114997 Add devsite class to tags in devices/storage and devices/tv by cqn <cqn@google.com> - 158948331 Provide advice to OEM and carrier app developers to reduc... by Android Partner Docs <noreply@android.com> - 158920824 Add devsite class to tags in devices/tech/dalvik by cqn <cqn@google.com> - 158917965 Fix links to sensors.h reference file by claym <claym@google.com> - 158916603 Docs: moving gdb to own page, updating index by hvm <hvm@google.com> - 158915436 Update Security acknowledgement with new researcher info by daroberts <daroberts@google.com> - 158883841 Finish adding devsite class to tags in devices/audio by cqn <cqn@google.com> - 158883680 Add devsite class to tags in devices/sensors and devices/... by cqn <cqn@google.com> - 158871012 Improve Jack deprecation warning message. by gdimino <gdimino@google.com> - 158867373 Add devsite classes to tags for devices/graphics by cqn <cqn@google.com> - 158867298 Added devsite classes to tags in devices/input by cqn <cqn@google.com> - 158867192 Add devsite classes to tags in devices/camera and devices... by cqn <cqn@google.com> PiperOrigin-RevId: 159519221 Change-Id: I924de0c1668bcbcc94ee97e60c144aac4c81708d
Diffstat (limited to 'en/compatibility/cts/development.html')
-rw-r--r--en/compatibility/cts/development.html26
1 files changed, 14 insertions, 12 deletions
diff --git a/en/compatibility/cts/development.html b/en/compatibility/cts/development.html
index 6e44d27f..ae4c6e7e 100644
--- a/en/compatibility/cts/development.html
+++ b/en/compatibility/cts/development.html
@@ -37,14 +37,16 @@ CTS console:</p>
<p class="note"><strong>Note:</strong> You may supply one of these other values
for <code>TARGET_PRODUCT</code> to build for different architectures:
<code>aosp_x86_64</code> or <code>aosp_mips</code></p>
-<pre><code>cd <em>/path/to/android/root</em>
-make cts -j32 TARGET_PRODUCT=aosp_arm64
-cts-tradefed
+<pre class="devsite-click-to-copy">
+<code class="devsite-terminal">cd <em>/path/to/android/root</em></code>
+<code class="devsite-terminal">make cts -j32 TARGET_PRODUCT=aosp_arm64</code>
+<code class="devsite-terminal">cts-tradefed</code>
</code></pre>
<p>At the cts-tf console, enter e.g.:</p>
-<pre><code>run cts --plan CTS
-</code></pre>
+<pre class="devsite-click-to-copy">
+tf&gt; run cts --plan CTS
+</pre>
<h2 id="writing-cts-tests">Writing CTS tests</h2>
@@ -106,7 +108,7 @@ For Android 6.0 and earlier, use CTS v1. For CTS v1, the sample code is at
<p>
The directory structure in CTS v1 tests looks like this:
</p>
-<pre class="no-pretty-print">
+<pre class="devsite-click-to-copy">
cts/
tests/
tests/
@@ -120,7 +122,7 @@ cts/
cts/
SampleDeviceTest.java
</pre>
-<h4 id="cts-v2"><strong>CTS v2</strong></h4>
+<h4 id="cts-v2">CTS v2</h4>
<p>
For Android 7.0 and later, use CTS v2. For details, see <a
href="https://android.googlesource.com/platform/cts/+/master/tests/sample/">the
@@ -130,7 +132,7 @@ sample test in AOSP</a>.
The CTS v2 directory structure looks like this:
</p>
-<pre class="no-pretty-print">
+<pre class="devsite-click-to-copy">
cts/
tests/
<em>module-name</em>/
@@ -169,7 +171,7 @@ to quick start your new test module with following steps:
<ol>
<li>Run this command to create the test directory and copy sample files to it:
- <pre class="no-pretty-print">$ mkdir cts/tests/<i>module-name</i> && cp -r cts/tests/sample/* cts/tests/<i>module-name</i></pre>
+ <pre class="devsite-terminal devsite-click-to-copy">mkdir cts/tests/<i>module-name</i> && cp -r cts/tests/sample/* cts/tests/<i>module-name</i></pre>
<li>Navigate to <code>cts/tests/<em>module-name</em></code> and substitute all instances of
"[Ss]ample" following the recommended naming convention from above.
<li>Update <code>SampleDeviceActivity</code> to exercise the feature you're testing.
@@ -177,7 +179,7 @@ to quick start your new test module with following steps:
errors.</li>
</ol>
-<h4><strong>Additional directories</strong></h4>
+<h4>Additional directories</h4>
<p> Other Android directories such as <code>assets</code>, <code>jni</code>,
<code>libs</code> and <code>res</code> can also be added. To add JNI code,
@@ -187,7 +189,7 @@ code and an <code>Android.mk</code> in it.</p>
<p>
The makefile typically contains the following settings:
</p>
-<pre>
+<pre class="devsite-click-to-copy">
LOCAL_PATH := $(call my-dir)
include $(CLEAR_VARS)
LOCAL_MODULE := libCtsSample_jni
@@ -210,7 +212,7 @@ include $(BUILD_SHARED_LIBRARY)
need to be modified to build the native code and depend on it, as shown
below:</p>
-<pre>
+<pre class="devsite-click-to-copy">
# All tests should include android.test.runner.
LOCAL_JAVA_LIBRARIES := android.test.runner