buildframework/helium/doc/src/manual/stage_ats.rst.inc.ftl
author wbernard
Wed, 16 Jun 2010 16:51:40 +0300
changeset 588 c7c26511138f
parent 587 85df38eb4012
child 628 7c4a911dc066
permissions -rw-r--r--
helium-10.0.0-bc45d50958fe
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
587
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
     1
<#--
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
     2
============================================================================ 
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
     3
Name        : stage_ats.rst.inc.ftl
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
     4
Part of     : Helium 
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
     5
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
     6
Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies).
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
     7
All rights reserved.
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
     8
This component and the accompanying materials are made available
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
     9
under the terms of the License "Eclipse Public License v1.0"
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    10
which accompanies this distribution, and is available
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    11
at the URL "http://www.eclipse.org/legal/epl-v10.html".
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    12
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    13
Initial Contributors:
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    14
Nokia Corporation - initial contribution.
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    15
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    16
Contributors:
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    17
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    18
Description:
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    19
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    20
============================================================================
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    21
-->
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    22
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    23
.. index::
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    24
  single: ATS - STIF, TEF, RTEST, MTF and EUnit
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    25
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    26
.. _`Stage-ATS-label`:
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    27
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    28
Stage: ATS - STIF, TEF, RTEST, MTF and EUnit (also Qt)
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    29
=======================================================
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    30
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    31
ATS testing is the automatic testing of the phone code once it has been compiled and linked to create a ROM image.
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    32
588
c7c26511138f helium-10.0.0-bc45d50958fe
wbernard
parents: 587
diff changeset
    33
Explanation of the process for getting ATS (`STIF`_ and `EUnit`_) tests compiled and executed by Helium, through the use of the :hlm-t:`ats-test` target.
587
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    34
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    35
http://developer.symbian.org/wiki/index.php/Symbian_Test_Tools
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    36
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    37
<#if !(ant?keys?seq_contains("sf"))>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    38
.. _`STIF`: http://s60wiki.nokia.com/S60Wiki/STIF
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    39
.. _`EUnit`: http://s60wiki.nokia.com/S60Wiki/EUnit
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    40
</#if>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    41
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    42
.. image:: ats.dot.png
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    43
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    44
Prerequisites
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    45
----------------
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    46
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    47
* `Harmonized Test Interface (HTI)`_ needs to be compiled and into the image.
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    48
* The reader is expected to already have a working ATS setup in which test cases can be executed.  ATS server names, 
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    49
  access rights and authentication etc. is supposed to be already taken care of.
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    50
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    51
<#if !(ant?keys?seq_contains("sf"))>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    52
.. _`Harmonized Test Interface (HTI)`: http://s60wiki.nokia.com/S60Wiki/HTI
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    53
<#else>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    54
.. _`Harmonized Test Interface (HTI)`: http://developer.symbian.org/wiki/index.php/HTI_Tool
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    55
</#if>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    56
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    57
Test source components
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    58
-------------------------
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    59
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    60
Test source usually lives in a component's ``tsrc`` directory.  Test source components are created like any other Symbian SW component; 
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    61
there is a ``group`` directory with a ``bld.inf`` file for building, ``.mmp`` files for defining the targets, and so on.
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    62
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    63
The test generation code expects ``.pkg`` file in the ``group`` directory of test component to be compiled, to get the paths of the files 
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    64
(can be data, configuration, initialization, etc files) to be installed and where to install on the phone. 
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    65
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    66
Three STEPS to setup ATS with Helium
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    67
--------------------------------------
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    68
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    69
**Step 1: Configure System Definition Files**
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    70
 If the tsrc directory structure meets the criteria defined in the `new API test automation guidelines`_, then test components 
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    71
 should be included in the System Definition files; **layers** in ``layers.sysdef.xml`` file and **configuration** in ``build.sysdef.xml`` 
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    72
 file (`Structure of System Definition files`_).
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    73
 
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    74
 <#if !(ant?keys?seq_contains("sf"))>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    75
.. _`new API test automation guidelines`: http://s60wiki.nokia.com/S60Wiki/Test_Asset_Guidelines
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    76
.. _`Structure of System Definition files`: http://delivery.nmp.nokia.com/trac/helium/wiki/SystemDefinitionFiles
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    77
</#if>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    78
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    79
A template of layer in layers.sysdef.xml
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    80
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    81
.. code-block:: xml
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    82
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    83
    <layer name="name_test_layer">
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    84
        <module name="module_name_one">
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    85
            <unit unitID="unit_id1" name="unit_name1" bldFile="path_of_tsrc_folder_to_be_built" mrp="" />
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    86
        </module>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    87
        
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    88
        <module name="module_name_two">
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    89
            <unit unitID="unit_id2" name="unit_name2" bldFile="path_of_tsrc_folder_to_be_built" mrp="" />
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    90
        </module>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    91
    </layer> 
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    92
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    93
* Layer name should end with **_test_layer**
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    94
* Two standard names for ATS test layers are being used; ``unit_test_layer`` and ``api_test_layer``. Test components (the``unit`` tags) 
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    95
  should be specified under these layers and grouped by ``module`` tag(s).
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    96
* In the above, two modules means two drop files will be created; ``module`` may have one or more ``unit``
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    97
* By using property ``exclude.test.layers``, complete layers can be excluded and the components inside that layer will not be included in the AtsDrop. This property is a comma (,) separated list
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    98
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
    99
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   100
**Step 2: Configure ATS properties in build.xml**
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   101
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   102
**(A)** Username and Password for the ATS should be set in the `.netrc file`_::
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   103
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   104
    machine ats login ats_user_name password ats_password
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   105
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   106
Add the above line in the ``.netrc`` file and replace ``ats_user_name`` with your real ATS username and ``ats_password`` with ATS password.
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   107
    
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   108
**(B)** The following properties are ATS dependent with their edit status
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   109
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   110
* [must] - must be set by user
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   111
* [recommended] - should be set by user but not mandatory
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   112
* [allowed] - should **not** be set by user however, it is possible.
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   113
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   114
.. csv-table:: ATS Ant properties
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   115
   :header: "Property name", "Edit status", "Description"
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   116
   
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   117
    ":hlm-p:`ats.server`", "[must]", "For example: ``4fix012345`` or ``catstresrv001.cats.noklab.net:80``. Default server port is ``8080``, but it is not allowed between intra and Noklab. Because of this we need to define server port as 80. The host can be different depending on site and/or product."
588
c7c26511138f helium-10.0.0-bc45d50958fe
wbernard
parents: 587
diff changeset
   118
    ":hlm-p:`ats.drop.location`", "[allowed]", "Server location (UNC path) to save the ATSDrop file, before sending to the ATS Server. For example: ``\\\\trwsem00\\some_folder\\``. In case, :hlm-p:`ats.script.type` is set to ``import``, ATS doesn't need to have access to :hlm-p:`ats.drop.location`,  its value can be any local folder on build machine, for example ``c:/temp`` (no network share needed)."
587
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   119
    ":hlm-p:`ats.product.name`", "[must]", "Name of the product to be tested."
588
c7c26511138f helium-10.0.0-bc45d50958fe
wbernard
parents: 587
diff changeset
   120
    ":hlm-p:`eunit.test.package`", "[allowed]", "The EUnit package name to be unzipped on the environment, for executing EUnit tests."
c7c26511138f helium-10.0.0-bc45d50958fe
wbernard
parents: 587
diff changeset
   121
    ":hlm-p:`eunitexerunner.flags`", "[allowed]", "Flags for EUnit exerunner can be set by setting the value of this variable. The default flags are set to ``/E S60AppEnv /R Off``."
c7c26511138f helium-10.0.0-bc45d50958fe
wbernard
parents: 587
diff changeset
   122
    ":hlm-p:`ats.email.list`", "[allowed]", "The property is needed if you want to get an email from ATS server after the tests are executed. There can be one to many semicolon-separated email addresses."
c7c26511138f helium-10.0.0-bc45d50958fe
wbernard
parents: 587
diff changeset
   123
    ":hlm-p:`ats.report.type`", "[allowed]", "Value of the ats email report"
587
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   124
    ":hlm-p:`ats.flashfiles.minlimit`", "[recommended]", "Limit of minimum number of flash files to execute :hlm-t:`ats-test` target, otherwise ``ATSDrop.zip`` will not be generated. Default value is 2 files."
588
c7c26511138f helium-10.0.0-bc45d50958fe
wbernard
parents: 587
diff changeset
   125
    ":hlm-p:`ats.plan.name`", "[allowed]", "Modify the plan name if you have understanding of ``test.xml`` file or leave it as it is. Default value is ``plan``."
c7c26511138f helium-10.0.0-bc45d50958fe
wbernard
parents: 587
diff changeset
   126
    ":hlm-p:`ats.product.hwid`", "[allowed]", "Product HardWare ID (HWID) attached to ATS. By default the value of HWID is not set."
c7c26511138f helium-10.0.0-bc45d50958fe
wbernard
parents: 587
diff changeset
   127
    ":hlm-p:`ats.script.type`", "[allowed]", "There are two types of ats script files to send drop to ATS server, ``runx`` and ``import``; only difference is that with ``import`` ATS doesn't have to have access rights to ``testdrop.zip`` file, as it is sent to the system over http and import doesn't need network shares. If that is not needed ``import`` should not be used. Default value is ``runx`` as ``import`` involves heavy processing on ATS server."
c7c26511138f helium-10.0.0-bc45d50958fe
wbernard
parents: 587
diff changeset
   128
    ":hlm-p:`ats.target.platform`", "[allowed]", "Sets target platform for compiling test components. Default value is ``armv5 urel``."
c7c26511138f helium-10.0.0-bc45d50958fe
wbernard
parents: 587
diff changeset
   129
    ":hlm-p:`ats.test.timeout`", "[allowed]", "To set test commands execution time limit on ATS server, in seconds. Default value is ``60``."
c7c26511138f helium-10.0.0-bc45d50958fe
wbernard
parents: 587
diff changeset
   130
    ":hlm-p:`ats.testrun.name`", "[allowed]", "Modify the test-run name if you have understanding of ``test.xml`` file or leave it as it is. Default value is a string consist of build id, product name, major and minor versions."
c7c26511138f helium-10.0.0-bc45d50958fe
wbernard
parents: 587
diff changeset
   131
    ":hlm-p:`ats.trace.enabled`", "[allowed]", "Should be ``True`` if tracing is needed during the tests running on ATS. Default value is ``False``, the values are case-sensitive. See http://s60wiki.nokia.com/S60Wiki/CATS/TraceTools."
c7c26511138f helium-10.0.0-bc45d50958fe
wbernard
parents: 587
diff changeset
   132
    ":hlm-p:`ats.ctc.enabled`", "[allowed]", "Should be ``True`` if coverage measurement and dynamic analysis (CTC) tool support is to be used by ATS. Default value is ``False``. The values are case-sensitive."
c7c26511138f helium-10.0.0-bc45d50958fe
wbernard
parents: 587
diff changeset
   133
    ":hlm-p:`ats.ctc.host`", "[allowed]", "CTC host, provided by CATS used to create coverage measurement reports. MON.sym files are copied to this location, for example ``10.0.0.1``. If not given, code coverage reports are not created"
c7c26511138f helium-10.0.0-bc45d50958fe
wbernard
parents: 587
diff changeset
   134
    ":hlm-p:`ats.obey.pkgfiles.rule`", "[allowed]", "If the property is set to ``True``, then the only test components which will have PKG files, will be included into the ``test.xml`` as a test-set. Which means, even if there's a test component (executable) but there's no PKG file, it should not be considered as a test component and hence not included into the test.xml as a separate test. By default the property value is ``False``."
c7c26511138f helium-10.0.0-bc45d50958fe
wbernard
parents: 587
diff changeset
   135
    "``reference.ats.flash.images``", "[allowed]", "Fileset for list of flash images (can be .fpsx, .C00, .V01 etc) It is recommended to set the fileset, default filset is given below which can be overwritten. set *dir=""* attribute of the filset to ``${r'$'}{build.output.dir}/variant_images`` if hlm-t:`variant-image-creation` target is being used."
587
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   136
    ":hlm-p:`tsrc.data.dir`", "[allowed]", "The default value is ``data`` and refers to the 'data' directory under 'tsrc' directory."
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   137
    ":hlm-p:`tsrc.path.list`", "[allowed]", "Contains list of the tsrc directories. Gets the list from system definition layer files. Assuming that the test components are defined already in te ``layers.sysdef.xml`` files to get compiled. Not recommended, but the property value can be set if there are no System Definition file(s), and tsrc directories paths to set manually."
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   138
    ":hlm-p:`ats.report.location`", "[allowed]", "Sets ATS reports store location. Default location is ``${r'$'}{publish.dir}/${r'$'}{publish.subdir}``."
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   139
    ":hlm-p:`ats.multiset.enabled`", "[allowed]", "Should be ``True`` so a set is used for each pkg file in a component, this allows tests to run in parallel on several devices."
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   140
    ":hlm-p:`ats.diamonds.signal`", "[allowed]", "Should be ``true`` so at end of the build diamonds is checked for test results and Helium fails if tests failed."
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   141
    ":hlm-p:`ats.delta.enabled`", "[allowed]", "Should be ``true`` so only ADOs changed during :hlm-t:`do-prep-work-area` are tested by ATS."
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   142
    ":hlm-p:`ats4.enabled`", "[allowed]", "Should be ``true`` if ATS4 is to be used."
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   143
    ":hlm-p:`ats.emulator.enable`", "[allowed]", "Should be ``true`` if ``WINSCW`` emulator is to be used."
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   144
    ":hlm-p:`ats.specific.pkg`", "[allowed]", "Text in name of PKG files to use eg. 'sanity' would only use xxxsanity.pkg files from components."
588
c7c26511138f helium-10.0.0-bc45d50958fe
wbernard
parents: 587
diff changeset
   145
    ":hlm-p:`ats.create.singledrop.file`", "[recommended]", "If present and set to 'true', it will create one drop file, if set to any other value or not present it will create multiple drop files (defined by the sysdef file). This is to save traffic to the server."
587
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   146
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   147
An example of setting up properties:
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   148
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   149
.. code-block:: xml
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   150
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   151
    <property name="ats.server" value="4fio00105"  />
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   152
    <property name="ats.drop.location" location="\\trwsimXX\ATS_TEST_SHARE\" />
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   153
    <property name="ats.email.list" value="temp.user@company.com; another.email@company.com" />
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   154
    <property name="ats.flashfiles.minlimit" value="2" />
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   155
    <property name="ats.product.name" value="PRODUCT" />
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   156
    <property name="ats.plan.name" value="plan" />
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   157
    <property name="ats.product.hwid" value="" />
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   158
    <property name="ats.script.type" value="runx" />
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   159
    <property name="ats.target.platform" value="armv5 urel" />
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   160
    <property name="ats.test.timeout" value="60" />
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   161
    <property name="ats.testrun.name" value="${r'$'}{build.id}_${r'$'}{ats.product.name}_${r'$'}{major.version}.${r'$'}{minor.version}" />
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   162
    <property name="ats.trace.enabled" value="False" />
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   163
    <property name="ats.ctc.enabled" value="False" />
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   164
    <property name="ats.obey.pkgfiles.rule" value="False" />
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   165
    <property name="ats.report.location" value="${r'$'}{publish.dir}/${r'$'}{publish.subdir}" />
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   166
    <property name="eunit.test.package" value="" />
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   167
    <property name="eunitexerunner.flags" value="/E S60AppEnv /R Off" />
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   168
        
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   169
        ...
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   170
        <import file="${r'$'}{helium.dir}/helium.ant.xml" />
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   171
        ...
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   172
    
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   173
    <fileset id="reference.ats.flash.images" dir="${r'$'}{release.images.dir}">
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   174
        <include name="**/${r'$'}{build.id}*.core.fpsx"/>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   175
        <include name="**/${r'$'}{build.id}*.rofs2.fpsx"/>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   176
        <include name="**/${r'$'}{build.id}*.rofs3.fpsx"/>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   177
    </fileset>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   178
    
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   179
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   180
.. Note::
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   181
   
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   182
   Always declare *Properties* before and *filesets* after importing helium.ant.xml.
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   183
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   184
**STEP 3: Call target ats-test**
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   185
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   186
To execute the target, a property should be set(``<property name="enabled.ats" value="true" />``).
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   187
588
c7c26511138f helium-10.0.0-bc45d50958fe
wbernard
parents: 587
diff changeset
   188
Then call :hlm-t:`ats-test`, which will create the ATSDrop.zip (test package).
587
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   189
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   190
If property *ats.email.list* is set, an email (test report) will be sent when the tests are ready on ATS.
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   191
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   192
CTC:
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   193
----
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   194
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   195
CTC code coverage measurements reports can be created as part of Test Automation process.
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   196
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   197
1. Build the src using ``build_ctc`` configuration, which is in ``build.sysdef.xml`` file, to create ``MON.sym`` files. It means that a property ``sysdef.configurations.list`` should be modified either add or replace current build configuration with ``build_ctc``
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   198
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   199
2. Set the property, ``ats.ctc.host``, as described above, for sending the ``MON.sym`` files to the network drive. *(Please contact ATS server administrator and ask for the value to set this property)*
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   200
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   201
3. Enable CTC process by setting up property ``ats.ctc.enabled`` to "true"
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   202
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   203
4. Test drops are sent to the ATS server, where, after executing tests ``ctcdata.txt`` files are created. ``ctcdata.txt`` and ``MON.sym`` files are then further processed to create code coverage reports.
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   204
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   205
5. View or download the Code coverage reports by following the link provided in the ATS report email (sent after the tests are executed on ATS)
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   206
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   207
*NOTE: After receiving the email notification, it may take a few minutes before the code coverage reports are available.*
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   208
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   209
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   210
Qt Tests:
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   211
---------
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   212
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   213
QtTest.lib is supported and the default harness is set to EUnit. If ``QtTest.lib`` is there in ``.mmp`` file, Helium sets the Harness to Eunit and ATS supported Qt steps are added to test.xml file
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   214
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   215
In ``layers.sysdef.xml`` file, the layer name should end with "_test_layer" e.g. "qt_unit_test_layer".
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   216
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   217
There are several ``.PKG`` files created after executing ``qmake``, but only one is selected based on which target platform is set. Please read the property (``ats.target.platform``) description above.
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   218
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   219
.. _`Skip-Sending-AtsDrop-label`:
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   220
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   221
Skip Sending AtsDrop to ATS
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   222
----------------------------
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   223
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   224
By setting property of ``skip.ats.sending``, ``ats-test`` target only creates a drop file, and does not send the drop (or package) to ATS server.
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   225
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   226
Customizing the test.xml in ATS
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   227
--------------------------------
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   228
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   229
The user can customize the generated test.xml with files:
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   230
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   231
* **preset_custom.xml** goes before first set
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   232
* **postset_custom.xml** goes after last set
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   233
* **precase_custom.xml** goes before first case 
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   234
* **postcase_custom.xml** goes after last case
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   235
* **prestep_custom.xml** goes before first step
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   236
* **poststep_custom.xml** goes after last step
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   237
* **prerun_custom.xml** goes before first run or execute step
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   238
* **postrun_custom.xml** goes after last run or execute step
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   239
* **prepostaction.xml** goes before first postaction
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   240
* **postpostaction.xml** goes after last postaction
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   241
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   242
The files must be in the directory custom under the tsrc folder processed. 
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   243
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   244
The files need to be proper XML snippets that fit to their place. In case of an error an error is logged and a comment inserted to the generated XML file.
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   245
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   246
A postaction section customization file ( prepostaction.xml or postpostaction.xml) could look like this
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   247
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   248
.. code-block:: xml
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   249
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   250
  <postAction>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   251
    <type>Pre PostAction from custom file</type> 
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   252
    <params>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   253
       <param name="foo2" value="bar2" /> 
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   254
    </params>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   255
  </postAction>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   256
  
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   257
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   258
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   259
The ``prestep_custom.xml`` can be used to flash and unstall something custom.
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   260
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   261
.. code-block:: xml
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   262
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   263
  <step name="Install measurement tools" harness="STIF" significant="false">
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   264
    <!-- Copy SIS-packages to DUT -->
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   265
    <command>install</command>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   266
    <params>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   267
        <param src="Nokia_Energy_Profiler_1_1.sisx"/>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   268
        <param dst="c:\data\Nokia_Energy_Profiler_1_1.sisx"/>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   269
    </params>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   270
    ...
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   271
  </step>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   272
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   273
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   274
And then the  ``prerun_custom.xml`` can be used to start measuring.
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   275
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   276
.. code-block:: xml
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   277
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   278
  <step name="Start measurement" harness="STIF" significant="false">
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   279
      <!-- Start measurement -->
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   280
      <command>execute</command>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   281
      <params>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   282
          <param file="neplauncher.exe"/>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   283
          <param parameters="start c:\data\nep.csv"/>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   284
          <param timeout="30"/>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   285
      </params>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   286
  </step>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   287
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   288
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   289
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   290
**Note:** The users is expected to check the generated test.xml manually, as there is no validation. Invalid XML input files will be disregarded and a comment will be inserted to the generated XML file.
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   291
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   292
Overriding Test xml values
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   293
--------------------------
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   294
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   295
Set the property ``ats.config.file`` to the location of the config file.
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   296
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   297
Example configuration:
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   298
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   299
.. code-block:: xml
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   300
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   301
    <ATSConfigData>  
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   302
        <config name="common" abstract="true">
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   303
         
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   304
            <!-- Properties to add/ modify -->
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   305
            <config type="properties">
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   306
               <set name="HARNESS" value="STIF" />
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   307
               <set name="2" value="3" />
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   308
            </config>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   309
            
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   310
            <!-- Settings to add/ modify -->
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   311
            <config type="settings">
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   312
               <set name="HARNESS" value="STIF" />
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   313
               <set name="2" value="3" />
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   314
            </config>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   315
            
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   316
            <!-- Attributes to modify -->
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   317
            <config type="attributes">
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   318
               <set name="xyz" value="2" />
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   319
               <set name="significant" value="true" />
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   320
            </config>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   321
        </config>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   322
    </ATSConfigData>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   323
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   324
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   325
.. index::
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   326
  single: ATS - ASTE
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   327
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   328
Stage: ATS - ASTE
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   329
===================
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   330
588
c7c26511138f helium-10.0.0-bc45d50958fe
wbernard
parents: 587
diff changeset
   331
Explanation of the process for getting ATS `ASTE`_ tests compiled and executed by Helium, through the use of the :hlm-t:`ats-aste` target.
587
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   332
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   333
<#if !(ant?keys?seq_contains("sf"))>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   334
.. _`ASTE`: http://s60wiki.nokia.com/S60Wiki/ASTE
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   335
</#if>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   336
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   337
Prerequisites
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   338
--------------
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   339
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   340
* `Harmonized Test Interface (HTI)`_ needs to be compiled and into the image.
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   341
* The reader is expected to already have a working ATS setup in which test cases can be executed.  ATS server names, access rights and authentication etc. is supposed to be already taken care of.
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   342
* `SW Test Asset`_ location and type of test should be known.
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   343
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   344
<#if !(ant?keys?seq_contains("sf"))>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   345
.. _`Harmonized Test Interface (HTI)`: http://s60wiki.nokia.com/S60Wiki/HTI
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   346
.. _`SW Test Asset`: http://s60wiki.nokia.com/S60Wiki/MC_SW_Test_Asset_documentation
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   347
</#if>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   348
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   349
Test source components
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   350
--------------------------
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   351
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   352
Unlike STIF, EUnit etc tests, test source components (or ``tsrc`` structure) is not needed for `ASTE`_ tests.
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   353
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   354
Two STEPS to setup ASTE with Helium
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   355
------------------------------------
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   356
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   357
**STEP 1: Configure ASTE properties in build.xml**
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   358
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   359
**(A)** Username and Password for the ATS should be set in the `.netrc file`_
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   360
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   361
.. code-block:: text
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   362
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   363
    machine ats login ats_user_name password ats_password
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   364
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   365
Add the above line in the .netrc file and replace *ats_user_name* with your real ats username and "ats_password" with ats password.
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   366
    
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   367
.. _`.netrc file`: configuring.html?highlight=netrc#passwords
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   368
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   369
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   370
**(B)** The following properties are ASTE dependent with their edit status
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   371
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   372
* [must] - must be set by user
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   373
* [recommended] - should be set by user but not mandatory
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   374
* [allowed] - should **not** be set by user however, it is possible.
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   375
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   376
.. csv-table:: ATS Ant properties
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   377
   :header: "Property name", "Edit status", "Description"
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   378
   
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   379
    ":hlm-p:`ats.server`", "[must]", "For example: ``4fio00105`` or ``catstresrv001.cats.noklab.net:80``. Default server port is ``8080``, but it is not allowed between intra and Noklab. Because of this we need to define server port as ``80``. The host can be different depending on site and/or product."
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   380
    ":hlm-p:`ats.drop.location`", "[must]", "Server location (UNC path) to save the ATSDrop file, before sending to the ATS. For example: ``\\\\trwsem00\\some_folder\\``. In case, ``ats.script.type`` is set to ``import``, ATS doesn't need to have access to :hlm-p:`ats.drop.location`,  its value can be any local folder on build machine, for example ``c:/temp`` (no network share needed)."
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   381
    ":hlm-p:`ats.product.name`", "[must]", "Name of the product to be tested."
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   382
    ":hlm-p:`ats.aste.testasset.location`", "[must]", "Location of SW Test Assets, if the TestAsset is not packaged then it is first compressed to a ``.zip`` file. It should be a UNC path."
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   383
    ":hlm-p:`ats.aste.software.release`", "[must]", "Flash images releases, for example 'SPP 51.32'."
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   384
    ":hlm-p:`ats.aste.software.version`", "[must]", "Version of the software to be tested. For example: 'W810'"
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   385
    ":hlm-p:`ats.aste.email.list`", "[recommended]", "The property is needed if you want to get an email from ATS server after the tests are executed. There can be one to many semicolon(s) ";" separated email addresses."
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   386
    ":hlm-p:`ats.flashfiles.minlimit`", "[recommended]", "Limit of minimum number of flash files to execute ats-test target, otherwise ATSDrop.zip will not be generated. Default value is "2" files."
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   387
    ":hlm-p:`ats.aste.plan.name`", "[recommended]", "Modify the plan name if you have understanding of test.xml file or leave it as it is. Default value is "plan"."
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   388
    ":hlm-p:`ats.product.hwid`", "[recommended]", "Product HardWare ID (HWID) attached to ATS. By default the value of HWID is not set."
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   389
    ":hlm-p:`ats.test.timeout`", "[recommended]", "To set test commands execution time limit on ATS server, in seconds. Default value is '60'."
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   390
    ":hlm-p:`ats.aste.testrun.name`", "[recommended]", "Modify the test-run name if you have understanding of ``test.xml`` file or leave it as it is. Default value is a string consists of build id, product name, major and minor versions."
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   391
    ":hlm-p:`ats.aste.test.type`", "[recommended]", "Type of test to run. Default is 'smoke'."
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   392
    ":hlm-p:`ats.aste.testasset.caseids`", "[recommended]", "These are the cases that which tests should be run from the TestAsset. For example, value can be set as ``100,101,102,103,105,106,``. A comma is needed to separate case IDs"
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   393
    ":hlm-p:`ats.aste.language`", "[recommended]", "Variant Language to be tested. Default is 'English'"
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   394
    "``reference.ats.flash.images``", "[recommended]", "Fileset for list of flash images (can be .fpsx, .C00, .V01 etc) It is recommended to set the fileset, default filset is given below which can be overwritten. set *dir=\"\"* attribute of the filset to ``${r'$'}{build.output.dir}/variant_images`` if :hlm-t:`variant-image-creation` target is being used."
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   395
    
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   396
    
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   397
An example of setting up properties:
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   398
    
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   399
.. code-block:: xml
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   400
    
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   401
    <property name="ats.server" value="4fio00105"  />
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   402
    <property name="ats.drop.location" value="\\trwsimXX\ATS_TEST_SHARE\" />
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   403
    <property name="ats.aste.email.list" value="temp.user@company.com; another.email@company.com" />
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   404
    <property name="ats.flashfiles.minlimit" value="2" />
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   405
    <property name="ats.product.name" value="PRODUCT" />
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   406
    <property name="ats.aste.plan.name" value="plan" />
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   407
    <property name="ats.product.hwid" value="" />
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   408
    <property name="ats.test.timeout" value="60" />
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   409
    <property name="ats.aste.testrun.name" value="${r'$'}{build.id}_${r'$'}{ats.product.name}_${r'$'}{major.version}.${r'$'}{minor.version}" />
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   410
    <property name="ats.aste.testasset.location" value="" />
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   411
    <property name="ats.aste.software.release" value="SPP 51.32" />
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   412
    <property name="ats.aste.test.type" value="smoke" />
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   413
    <property name="ats.aste.testasset.caseids" value="100,101,102,104,106," />
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   414
    <property name="ats.aste.software.version" value="W810" />
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   415
    <property name="ats.aste.language" value="English" />
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   416
         
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   417
    ...
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   418
    <import file="${r'$'}{helium.dir}/helium.ant.xml" />
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   419
    ...
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   420
    
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   421
    <fileset id="reference.ats.flash.images" dir="${r'$'}{release.images.dir}">
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   422
        <include name="**/${r'$'}{build.id}*.core.fpsx"/>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   423
        <include name="**/${r'$'}{build.id}*.rofs2.fpsx"/>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   424
        <include name="**/${r'$'}{build.id}*.rofs3.fpsx"/>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   425
    </fileset>
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   426
    
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   427
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   428
*PLEASE NOTE:* Always declare *Properties* before and *filesets* after importing helium.ant.xml.
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   429
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   430
**STEP 2: Call target ats-aste**
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   431
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   432
To execute the target, a property should be set(``<property name="enabled.aste" value="true" />``).
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   433
588
c7c26511138f helium-10.0.0-bc45d50958fe
wbernard
parents: 587
diff changeset
   434
Then call :hlm-t:`ats-aste`, which will create the ATSDrop.zip (test package).
587
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   435
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   436
If property ``ats.aste.email.list`` is set, an email (test report) will be sent when the tests are ready on ATS/ASTE.
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   437
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   438
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   439
Skip Sending AtsDrop to ATS
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   440
------------------------------
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   441
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   442
click :ref:`Skip-Sending-AtsDrop-label`:
85df38eb4012 helium_9.0-a7879c935424
wbernard
parents:
diff changeset
   443
588
c7c26511138f helium-10.0.0-bc45d50958fe
wbernard
parents: 587
diff changeset
   444
Stage: ATS - Custom Drop
c7c26511138f helium-10.0.0-bc45d50958fe
wbernard
parents: 587
diff changeset
   445
========================
c7c26511138f helium-10.0.0-bc45d50958fe
wbernard
parents: 587
diff changeset
   446
c7c26511138f helium-10.0.0-bc45d50958fe
wbernard
parents: 587
diff changeset
   447
If you need to send a static drop to ATS then you can call the target :hlm-t:`ats-custom-drop` and set a property to your own template.
c7c26511138f helium-10.0.0-bc45d50958fe
wbernard
parents: 587
diff changeset
   448
c7c26511138f helium-10.0.0-bc45d50958fe
wbernard
parents: 587
diff changeset
   449
A example template is in helium/tools/testing/ats/templates/ats4_naviengine_template.xml
c7c26511138f helium-10.0.0-bc45d50958fe
wbernard
parents: 587
diff changeset
   450
c7c26511138f helium-10.0.0-bc45d50958fe
wbernard
parents: 587
diff changeset
   451
.. code-block:: xml
c7c26511138f helium-10.0.0-bc45d50958fe
wbernard
parents: 587
diff changeset
   452
c7c26511138f helium-10.0.0-bc45d50958fe
wbernard
parents: 587
diff changeset
   453
    <property name="ats.custom.template" value="path/to/mytemplate.xml" />