1page.title=Setting Up for Licensing
2parent.title=Application Licensing
3parent.link=index.html
4@jd:body
5
6
7<div id="qv-wrapper">
8<div id="qv">
9
10  <h2>In this document</h2>
11  <ol>
12  <li><a href="#account">Setting Up a Publisher Account</a></li>
13  <li><a href="#dev-setup">Setting Up the Development Environment</a>
14    <ol>
15      <li><a href="#runtime-setup">Setting up the runtime environment</a></li>
16      <li><a href="#download-lvl">Downloading the LVL</a></li>
17      <li><a href="#lvl-setup">Setting Up the Licensing Verification Library</a></li>
18      <li><a href="#add-library">Including the LVL library project sources in your
19application</a></li>
20    </ol>
21  </li>
22  <li><a href="#test-env">Setting Up the Testing Environment</a>
23    <ol>
24      <li><a href="#test-response">Setting test responses for license checks</a></li>
25      <li><a href="#test-acct-setup">Setting up test accounts</a></li>
26      <li><a href="#acct-signin">Signing in to an authorized account in the runtime
27environment</a></li>
28    </ol>
29  </li>
30</ol>
31</div>
32</div>
33
34<p>Before you start adding license verification to your application, you need to set up your Google
35Play publishing account, your development environment, and any test accounts required to verify
36your implementation.</p>
37
38
39<h2 id="account">Setting Up a Publisher Account</h2>
40
41<p>If you don't already have a publisher account for Google Play, you need to register for one
42using your Google account and agree to the Google Play terms of service.</p>
43
44<p>For more information, see <a
45href="{@docRoot}distribute/googleplay/start.html">Get Started with Publishing</a>.</p>
46
47<p>If you already have a publisher account on Google Play, use your
48Developer Console to set up licensing.</p>
49
50<p>Using the Google Play Developer Console, you can:</p>
51
52<ul>
53<li>Obtain an app-specific public key for licensing</li>
54<li>Debug and test an application's licensing implementation, prior to
55publishing the application</li>
56<li>Publish the applications to which you have added licensing support</li>
57</ul>
58
59<h4>Administrative settings for licensing</h4>
60
61<p>You can manage several
62administrative controls for Google Play licensing in the Developer Console. The controls
63let you: </p>
64
65<ul>
66<li>Set up multiple "test accounts," identified by email address. The licensing
67server allows users signed in to test accounts on a device or emulator to send
68license checks and receive static test responses. You can set up accounts in the
69Account Details page of the Developer Console.</li>
70<li>Configure static test responses that the server sends, when it receives a
71license check for an application uploaded to the publisher account, from a user
72signed in to the publisher account or a test account. You can set test responses
73in the Account Details page of the Developer Console.</li>
74<li>Obtain the app's public key for licensing. When you are implementing
75licensing in an application, you must copy the public key string into the
76application. You can obtain the app's public key for licensing in the Services
77& APIs page (under All Applications).</li>
78</ul>
79
80<div style="width:640px;">
81<img src="{@docRoot}images/licensing_public_key.png" class="frame">
82<p class="img-caption"><strong>Figure
832.</strong> An app's license key is available from the Services &amp; APIs page in
84the Developer Console.</p>
85</div>
86
87<p>For more information about how to work with test accounts and static test
88responses, see <a href="#test-env">Setting Up a Testing Environment</a>, below.
89
90
91<h2 id="dev-setup">Setting Up the Development Environment</h2>
92
93<p>Setting up your environment for licensing involves these tasks:</p>
94
95<ol>
96<li><a href="#runtime-setup">Setting up the runtime environment</a> for development</li>
97<li><a href="#download-lvl">Downloading the LVL</a> into your SDK </li>
98<li><a href="#lvl-setup">Setting up the Licensing Verification Library</a></li>
99<li><a href="#add-library">Including the LVL library project in your application</a></li>
100</ol>
101
102<p>The sections below describe these tasks. When you are done with setup,
103you can begin <a href="{@docRoot}google/play/licensing/adding-licensing.html">Adding
104Licensing to Your App</a>.</p>
105
106<p>To get started, you need to set up a proper runtime environment on which
107you can run, debug, and test your application's implementation of license
108checking and enforcement. </p>
109
110
111<h3 id="runtime-setup">Setting up the runtime environment</h3>
112
113<p>As described earlier, applications check licensing status not by contacting
114the licensing server directly, but by binding to a service provided by the
115Google Play application and initiating a license check request. The Google
116Play service then handles the direct communication with the licensing server
117and finally routes the response back to your application. To debug and test
118licensing in your application, you need to set up a runtime environment that
119includes the necessary Google Play service, so that your application is able
120to send license check requests to the licensing server. </p>
121
122<p>There are two types of runtime environment that you can use: </p>
123
124<ul>
125<li>An Android-powered device that includes the Google Play application, or</li>
126<li>An Android emulator running the Google APIs Add-on, API level 8 (release 2)
127or higher</li>
128</ul>
129
130<h4 id="runtime-device">Running on a device</h4>
131
132<p>To use an Android-powered device for
133debugging and testing licensing, the device must:</p>
134
135<ul>
136<li>Run a compatible version of Android 1.5 or later (API level
1373 or higher) platform, <em>and</em> </li>
138<li>Run a system image on which the Google Play client application
139is preinstalled. </li>
140</ul>
141
142<p>If Google Play is not preinstalled in the system image, your application won't
143be able to communicate with the Google Play licensing server. </p>
144
145<p>For general information about how to set up a device for use in developing
146Android applications, see <a
147href="{@docRoot}tools/device.html">Using Hardware Devices</a>.</p>
148
149<h4 id="runtime-emulator">Running on an Android emulator</h4>
150
151<p>If you don't have a device available, you can use an Android emulator for debugging and testing
152licensing.</p>
153
154<p>Because the Android platforms provided in the Android SDK <em>do
155not</em> include Google Play, you need to download the Google APIs Add-On
156platform, API level 8 (or higher), from the SDK repository. After downloading
157the add-on, you need to create an AVD configuration that uses that system image.
158</p>
159
160<p>The Google APIs Add-On does not include the full Google Play client.
161However, it does provide: </p>
162
163<ul>
164<li>A Google Play background service that implements the
165<code>ILicensingService</code> remote interface, so that your application can
166send license checks over the network to the licensing server. </li>
167<li>A set of underlying account services that let you add an a Google account on
168the AVD and sign in using your publisher account or test account credentials.
169<p>Signing in using your publisher or test account enables you to debug and test
170your application without having publish it. For more information see <a
171href="#acct-signin">Signing in to an authorized account</a>, below.</p></li>
172</ul>
173
174<p>Several versions of the Google APIs add-on are available through the SDK Manager, but only
175the version for Android 2.2 and higher includes the necessary Google
176Play services.</p>
177
178<p>To set up an emulator for adding licensing to an application, follow
179these steps: </p>
180
181<ol>
182  <li>Launch the Android SDK Manager, available under the Android Studio Tools menu
183(<strong>Tools > Android > SDK Manager</strong>) or by executing
184{@code &lt;sdk>/tools/android sdk}.</li>
185  <li>Select and download <strong>Google APIs</strong> for the Android version you'd like to target
186(must be Android 2.2 or higher).</li>
187  <li>When the download is complete, open the AVD Manager, available under the Android Studio
188Tools menu (<strong>Tools > Android > AVD Manager</strong>) or by executing
189{@code &lt;sdk>/tools/android avd}.</li>
190  <li>In the <em>Android Virtual Device Manager</em> window, select
191<strong>+ Create Virtual Device</strong> to set the configuration details for the new AVD. </li>
192  <li>In the <em>Virtual Device Configuration</em> window, select device hardware, then
193select <strong>Next</strong>.</li>
194<li>Select a <strong>Google API</strong> as the system image to run on the new AVD, then
195select <strong>Next</strong>.</li>
196<li>Assign a descriptive name to the AVD and then set the other configuration details as
197needed.</li>
198<li>Select <strong>Finish</strong> to create the new AVD configuration, which will appear in the
199list of available Android Virtual Devices.</li>
200</ol>
201
202<p>If you are not familiar with AVDs or how to use them, see <a
203href="{@docRoot}tools/devices/index.html">Managing Virtual Devices</a>.</p>
204
205<h4 id="project-update">Updating your project configuration</h4>
206
207<p>After you set up a runtime environment that meets the requirements described
208above &mdash; either on an actual device or on an emulator &mdash; make sure to
209update your application project or build scripts as needed, so that your compiled
210<code>.apk</code> files that use licensing are deployed into that environment.
211In particular, if you are developing in Android Studio, make sure that you set up a
212Run/Debug Configuration that targets the appropriate device or AVD. </p>
213
214<p>You do not need to make any changes to your application's
215build configuration, provided that the project is already configured to compile
216against a standard Android 1.5 (API level 3) or higher library. Adding licensing to an application
217should have no impact whatsoever on the application's build configuration.</p>
218
219<h3 id="download-lvl">Downloading the LVL</h3>
220
221<p>The License Verification Library (LVL) is a collection of helper classes that
222greatly simplify the work that you need to do to add licensing to your
223application. In all cases, we recommend that you download the LVL and use it as
224the basis for the licensing implementation in your application.</p>
225
226<p>The LVL is available as a downloadable package of the Android SDK. The
227package includes: </p>
228
229<ul>
230<li>The LVL sources, stored inside an Android library project. </li>
231<li>An example application called "sample" that depends on the LVL library
232project. The example illustrates how an application uses the library helper
233classes to check and enforce licensing.</li>
234</ul>
235
236<p>To download the LVL package into your development environment, use the
237Android SDK Manager. Launch the Android SDK Manager and then
238select the <strong>Google Market Licensing</strong> package, as shown in figure 2.
239Accept the terms and click <strong>Install Selected</strong> to begin the download. </p>
240
241<img src="{@docRoot}images/licensing_package.png" alt=""/>
242<p class="img-caption"><strong>Figure 2.</strong> The Licensing package contains the LVL and
243the LVL sample application.</p>
244
245<p>When the download is complete, the Android SDK Manager installs both
246the LVL library project and the example application into these directories: </p>
247
248<p style="margin-left:2em"><code>&lt;<em>sdk</em>&gt;/extras/google/market_licensing/library/</code>
249&nbsp;&nbsp;(the LVL library project)<br />
250<code>&lt;<em>sdk</em>&gt;/extras/google/market_licensing/sample/</code>&nbsp;&nbsp;(the example
251application)</p>
252
253<p>If you aren't familiar with how to download packages into your SDK, learn how to
254<a href="{@docRoot}studio/intro/update.html">update the SDK tools</a>. </p>
255
256
257<h3 id="lvl-setup">Setting Up the Licensing Verification Library</h3>
258
259<p>After downloading the LVL to your computer, you need to set it up in your
260development environment, either as an Android library project or by
261copying (or importing) the library sources directly into your existing
262application package. In general, using the LVL as a library project is recommended,
263since it lets you reuse your licensing code across multiple applications and
264maintain it more easily over time. Note that the LVL is not designed to be
265compiled separately and added to an application as a static .jar file. </p>
266
267<h4>Moving the library sources to a new location</h4>
268
269<p>Because you will be customizing the LVL sources to some extent, you should
270make sure to <em>move or copy</em> the library sources (the entire
271directory at <code>&lt;<em>sdk</em>&gt;/market_licensing/library/</code>)
272to a working directory outside of the SDK. You should then use the relocated
273sources as your working set. If you are using a source-code management
274system, add and track the sources that are in the working location rather
275than those in default location in the SDK. </p>
276
277<p>Moving the library sources is important because when you later update the
278Licensing package, the SDK installs the new files to the same location as
279the older files. Moving your working library files to a safe location ensures
280that your work won't be inadvertently overwritten should you download a new
281version of the LVL.</p>
282
283<h4>Creating the LVL as a library project</h4>
284
285<div class="sidebox-wrapper">
286<div class="sidebox">
287<h2>Working with library projects</h2>
288
289<p>The LVL is provided as an Android library project, which means that you can
290share its code and resources across multiple applications. </p>
291
292<p style="margin-top:.5em;">If you aren't familiar with library projects or how
293to use them, see <a href="{@docRoot}tools/projects/index.html#LibraryProjects">
294Managing Projects</a>.
295</p>
296</div>
297</div>
298
299<p>The recommended way of using the LVL is setting it up as a new Android
300<em>library project</em>. A library project is a type of development project
301that holds shared Android source code and resources. Other Android application
302projects can reference the library project and, at build time, include its
303compiled sources in their <code>.apk</code> files. In the context of licensing,
304this means that you can do most of your licensing development once, in a library
305project, then include the library sources in your various application projects.
306In this way, you can easily maintain a uniform implementation of licensing
307across all of your projects and maintain it centrally. </p>
308
309<p>The LVL is provided as a configured library project &mdash; once you have
310downloaded it, you can start using it right away. </p>
311
312<p>If you are working in Android Studio, you need to add the LVL to your
313project as a new module.</p>
314
315<ol>
316<li>Use the New Module Wizard to import a library module by selecting
317<strong>File > New > Import Module</strong>.</li>
318<li>In the <em>New Module</em> window, in <em>Source directory</em>, enter the LVL's
319<code>library</code> directory (the directory containing the library's AndroidManifest.xml file)
320as the project root ({@code &lt;sdk>/extras/google/play_licensing/library/AndroidManifest.xml}),
321then select <strong>Next</strong>.</li>
322<li>Select <strong>Finish</strong> to import the library module.</li>
323</ol>
324
325<p>For more information about how to work with library modules in Android Studio, see
326<a href="{@docRoot}studio/projects/android-library.html">Create an Android Library</a>.</p>
327
328
329<h4>Copying the LVL sources to your application</h4>
330
331<p>As an alternative to adding the LVL as a library project, you can copy the
332library sources directly into your application. To do so, copy (or import) the
333LVL's <code>library/src/com</code> directory into your application's
334<code>src/</code> directory.</p>
335
336<p>If you add the LVL sources directly to your application, you can skip the
337next section and start working with the library, as described in <a
338href="{@docRoot}google/play/licensing/adding-licensing.html">Adding
339Licensing to Your App</a>.</p>
340
341
342<h3 id="add-library">Including the LVL library project sources in your
343application</h3>
344
345<p>If you want to use the LVL sources as a library project, you need to add a
346reference to the LVL library project in your application project properties. This tells
347build tools to include the LVL library project sources in your application at
348compile time. The process for adding a reference to a library project depends
349on your development environment, as described below.</p>
350
351<p> If you are developing in Android Studio, you should already have added the
352library module to your project, as described in the previous section. If you
353haven't done that already, do it now before continuing. </p>
354
355<p>If you are developing using the SDK command-line tools, navigate to the
356directory containing your application project and open the
357<code>project.properties</code> file. Add a line to the file that specifies the
358<code>android.library.reference.&lt;n&gt;</code> key and the path to the
359library. For example: </p>
360
361<pre>android.library.reference.1=path/to/library_project</pre>
362
363<p>Alternatively, you can use this command to update the project
364properties, including the reference to the library project:</p>
365
366<pre class="no-pretty-print" style="color:black">android update lib-project
367--target <em>&lt;target_ID&gt;</em> \
368--path <em>path/to/my/app_project</em> \
369--library <em>path/to/my/library_project</em>
370</pre>
371
372<p>For more information about working with library projects,
373see <a href="{@docRoot}tools/projects/projects-cmdline.html#SettingUpLibraryProject">
374Setting up a Library Project</a>.</p>
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396<h2 id="test-env">Setting Up the Testing Environment</h2>
397
398<p>The Google Play Developer Console provides configuration tools that let you
399and others test licensing on your application before it is published. As you are
400implementing licensing, you can make use of the Developer Console tools to test
401your application's Policy and handling of different licensing responses and
402error conditions.</p>
403
404<p>The main components of the test environment for licensing include: </p>
405
406<ul>
407<li>A "Test response" configuration in your publisher account that lets you
408set the static licensing response returned, when the server processes a
409license check for an application uploaded to the publisher account, from a user
410signed in to the publisher account or a test account.</li>
411<li>An optional set of test accounts that will receive the static test
412response when they check the license of an application that you have uploaded
413(regardless whether the application is published or not).</li>
414<li>A runtime environment for the application that includes the Google Play
415application or Google APIs Add-On, on which the user is signed in to the
416publisher account or one of the test accounts.</li>
417</ul>
418
419<p>Setting up the test environment properly involves:</p>
420
421<ol>
422<li><a href="#test-response">Setting static test responses</a> that are returned by the licensing server.</li>
423<li><a href="#test-acct-setup">Setting up test accounts</a> as needed.</li>
424<li><a href="#acct-signin">Signing in</a> properly to an emulator or device, before initiating a license check test.</li>
425</ol>
426
427<p>The sections below provide more information.</p>
428
429
430<h3 id="test-response">Setting test responses for license checks</h3>
431
432<p>Google Play provides a configuration setting in your publisher account
433that lets you override the normal processing of a license check and return a
434specified static response code. The setting is for testing only and applies
435<em>only</em> to license checks for applications that you have uploaded, made by
436any user signed in to an emulator or device using the credentials of the
437publisher account or a registered test account. For other users, the server
438always processes license checks according to normal rules.  </p>
439
440<p>To set a test response for your account, sign in to your publisher account
441and click "Edit Profile". In the Edit Profile page, locate the Test Response
442menu in the Licensing panel, shown below. You can select from the full set of
443valid server response codes to control the response or condition you want to
444test in your application.</p>
445
446<p>In general, you should make sure to test your application's licensing
447implementation with every response code available in the Test Response menu.
448For a description of the codes, see <a
449href="{@docRoot}google/play/licensing/licensing-reference.html#server-response-codes">Server
450Response Codes</a> in the <a
451href="{@docRoot}google/play/licensing/licensing-reference.html">Licensing Reference</a>.</p>
452
453<div style="width:640px;">
454<img src="{@docRoot}images/licensing_test_response.png" class="frame">
455<p class="img-caption"><strong>Figure 4.</strong> The License Testing
456panel of your Account details page lets you set up test accounts and
457manage test responses.</p>
458</div>
459
460<p>Note that the test response that you configure applies account-wide &mdash;
461that is, it applies not to a single application, but to <em>all</em>
462applications associated with the publisher account. If you are testing multiple
463applications at once, changing the test response will affect all of those
464applications on their next license check (if the user is signed in to
465the emulator or device using the publisher account or a test account).</p>
466
467<p>Before you can successfully receive a test response for a license check,
468you must sign in to the device or emulator on which the application
469is installed, and from which it is querying the server. Specifically, you must
470sign using either your publisher account or one of the test accounts that you
471have set up. For more information about test accounts, see the next section.</p>
472
473<p>See <a
474href="{@docRoot}google/play/licensing/licensing-reference.html#server-response-codes">Server
475Response Codes</a> for a list of
476test responses available and their meanings. </p>
477
478
479<h3 id="test-acct-setup">Setting up test accounts</h3>
480
481<p>In some cases, you might want to let multiple teams of developers test
482licensing on applications that will ultimately be published through your
483publisher account, but without giving them access to your publisher account's
484sign-in credentials. To meet that need, the Google Play Developer Console lets
485you set up one or more optional <em>test accounts</em> &mdash; accounts that are
486authorized to query the licensing server and receive static test responses from
487your publisher account.</p>
488
489<p>Test accounts are standard Google accounts that you register on your
490publisher account, such that they will receive the test response for
491applications that you have uploaded. Developers can then sign in to their
492devices or emulators using the test account credentials and initiate license
493checks from installed applications. When the licensing server receives a license
494check from a user of a test account, it returns the static test response
495configured for the publisher account.  </p>
496
497<p>Necessarily, there are limitations on the access and permissions given to
498users signed in through test accounts, including:</p>
499
500<ul>
501<li>Test account users can query the licensing server only for applications that
502are already uploaded to the publisher account. </li>
503<li>Test account users do not have permission to upload applications to your
504publisher account.</li>
505<li>Test account users do not have permission to set the publisher account's
506static test response.</li>
507</ul>
508
509<p>The table below summarizes the differences in capabilities, between the
510publisher account, a test account, and any other account.</p>
511
512<p class="table-caption" id="acct-types-table"><strong>Table 1.</strong>
513Differences in account types for testing licensing.</p>
514
515<table>
516<tr>
517<th>Account Type</th>
518<th>Can check license before upload?</th>
519<th>Can receive test response?</th>
520<th>Can set test response?</th>
521</tr>
522
523<tr>
524<td>Publisher account</td>
525<td>Yes</td>
526<td>Yes</td>
527<td>Yes</td>
528</tr>
529
530<tr>
531<td>Test account</td>
532<td>No</td>
533<td>Yes</td>
534<td>No</td>
535</tr>
536
537<tr>
538<td>Other</td>
539<td>No</td>
540<td>No</td>
541<td>No</td>
542</tr>
543</table>
544
545<h4 id="reg-test-acct">Registering test accounts on the publisher account</h4>
546
547<p>To get started, you need to register each test account in your publisher
548account. As shown in Figure 4, you
549register test accounts in the Licensing panel of your publisher account's Edit
550Profile page. Simply enter the accounts as a comma-delimited list and click
551<strong>Save</strong> to save your profile changes.</p>
552
553<p>You can use any Google account as a test account. If you want to own and
554control the test accounts, you can create the accounts yourself and distribute
555the credentials to your developers or testers.</p>
556
557<h4 id="test-app-upload">Handling application upload and distribution for test
558account users</h4>
559
560<p>As mentioned above, users of test accounts can only receive static test
561responses for applications that are uploaded to the publisher account. Since
562those users do not have permission to upload applications, as the publisher you
563will need to work with those users to collect apps for upload and distribute
564uploaded apps for testing. You can handle collection and distribution in any way
565that is convenient. </p>
566
567<p>Once an application is uploaded and becomes known to the licensing server,
568developers and testers can continue modify the application in their local
569development environment, without having to upload new versions. You only need to
570upload a new version if the local application increments the
571<code>versionCode</code> attribute in the manifest file. </p>
572
573<h4 id="test-key">Distributing your public key to test account users</h4>
574
575<p>The licensing server handles static test responses in the normal way,
576including signing the license response data, adding extras parameters, and so
577on. To support developers who are implementing licensing using test accounts
578rather than the publisher account, you will need to distribute
579the app's public key for licensing to them. Developers without access to the
580Developer Console do not have access to the app's public key, and without
581the key they won't be able to verify license responses. </p>
582
583<p>Note that if you decide to generate a new licensing key pair for the app
584for some reason, you need to notify all users of test accounts. For
585testers, you can embed the new key in the application package and distribute it
586to users. For developers, you will need to distribute the new key to them
587directly. </p>
588
589
590<h3 id="acct-signin">Signing in to an authorized account in the runtime
591environment</h3>
592
593<p>The licensing service is designed to determine whether a given user is
594licensed to use a given application &mdash; during a license check, the Google
595Play application gathers the user ID from the primary account on the system
596and sends it to the server, together with the package name of the application
597and other information. However, if there is no user information available, the
598license check cannot succeed, so the Google Play application terminates the
599request and returns an error to the application. </p>
600
601<p>During testing, to ensure that your application can successfully query the
602licensing server, you must make sure that you sign in to an account <em>on the
603device or emulator</em> using:</p>
604
605<ul>
606<li>The credentials of a publisher account, or</li>
607<li>The credentials of a test account that is registered with a publisher
608account</li>
609</ul>
610
611
612<div class="sidebox-wrapper">
613<div class="sidebox">
614<h2>Signing in to a Google account on an emulator</h2>
615
616<p>If you are testing licensing on an emulator, you need to sign in to a Google
617account on the emulator. If you do not see an option to create a new Google
618account, the problem might be that your AVD is running a standard Android system
619image, rather than the Google APIs Add-On, API 8 (release 2) or higher. </p>
620
621<p style="margin-top:.5em;">For more information, see <a
622href="#runtime-setup">Setting up the runtime environment</a>, above.</p>
623
624</div>
625</div>
626
627<p>Signing in using a publisher account offers the advantage of letting your
628applications receive static test responses even before the applications are
629uploaded to the Developer Console.</p>
630
631<p>If you are part of a larger organization or are working with external groups
632on applications that will be published through your site, you will more likely
633want to distribute test accounts instead, then use those to sign in during
634testing. </p>
635
636<p>To sign in on a device or emulator, follow the steps below. The preferred
637approach is to sign in as the primary account &mdash; however, if there are
638other accounts already in use on the device or emulator, you can create an
639additional account and sign in to it using the publisher or test account
640credentials.  </p>
641
642<ol>
643<li>Open Settings &gt; Accounts &amp; sync</li>
644<li>Select <strong>Add Account</strong> and choose to add a Google account.
645</li>
646<li>Select <strong>Next</strong> and then <strong>Sign in</strong>.</li>
647<li>Enter the username and password of either the publisher account or a test
648account that is registered in the publisher account.</li>
649<li>Select <strong>Sign in</strong>. The system signs you in to the new
650account.</li>
651</ol>
652
653<p>Once you are signed in, you can begin testing licensing in your application
654(if you have completed the LVL integration steps above). When your application
655initiates a license check, it will receive a response containing the static test
656response configured on the publisher account. </p>
657
658<p>Note that, if you are using an emulator, you will need to sign in to the
659publisher account or test account each time you wipe data when restarting the
660emulator.</p>
661
662<p>Once you've completed the setup procedures, continue to <a
663href="{@docRoot}google/play/licensing/adding-licensing.html">Adding Licensing to Your App</a>.</p>
664
665
666
667