TaskConfiguration refactoring - part 2/3
authorTomasz Iwanek <t.iwanek@samsung.com>
Tue, 3 Sep 2013 12:05:07 +0000 (14:05 +0200)
committerGerrit Code Review <gerrit@gerrit.vlan144.tizendev.org>
Tue, 1 Oct 2013 13:45:27 +0000 (13:45 +0000)
commitd9835cb83e3c470617fade13e41ace7be360a61c
tree304c41eb2f10ba2f90fadcbd45d9762fef533ffd
parent2d6c54d6ae0bb8713807d422089521a5fd2525cb
TaskConfiguration refactoring - part 2/3

[Issue#]       LINUXWRT-820
[Problem]      Refactoring
[Cause]        Code needs clean up
[Solution]     This change is solving:
 - "Stepifying" TaskConfiguration (identification of sub-problems of this task)

This change makes clean up/reordering in TaskConfiguration,
(now called) TaskProcessWidget is just to be fixed.

[Verification] Walk through following procedure:
1. Testing SetupTempDirStep & DetectUpdateInstallationStep
   (run app after each installation, uninstall successfully app if not needed):
 1.1. Install any new widget for first time
 1.2. Update widget several times
 1.3. Test installtion from browser installation:
       wrt-installer -i /opt/share/widget/tests/widgetstest/config.xml (wrt-extra)
 1.4. hybrid app -> test new installation
       (hybrid app can be found in "HybridApplication/res" directory
        in TCT behavioural tests; change extension to .wgt)
 1.5. hybrid app -> test update installation (run it again)
2. Testing ResourceEncryptionStep:
 2.1 Check points 1.1 and 1.2 for encrypted widget.
3. (optional if possible) Testing InstallationFSLocationSte:
 3.1 Check installation on external card
      (sets setting in widget config: install-location="prefer-external")
      (make sure it's really installed on card)
4. Testing CheckRDSSupportStep:
 4.1 Install widget without encryption using SDk and update it (reinstall).
     SDK should run RDS deployment (check console for succesfull installation messages)
 4.2 Install widget encryption using SDK and update it (reinstall).
     SDK should run normal installation.
     SDK may try to install it with RDS. wrt-installer should prompt then about error (RDS not supported).
     SDK shoudl recognized message and run normal installation automatically if RDS fails.
5. Testing pkgmgr interaction (pkgmgr should display proper type of instalaltion, notifications and icons):
 5.1. Run new isntallation through Installer app on phone (access .wgt from myfiles)
 5.2. Run update installation through Installer app on phone (access .wgt from myfiles)
 5.3. Run new isntallation through Installer app on phone (access .wgt from myfiles) of hybrid app
 5.4. Run update installation through Installer app on phone (access .wgt from myfiles) of hybrid app

---

Update may be tested (1.2.):
 wrt-installer-tests-general --output=text --regexp="Update"
Hosted app may be tested (1.3.):
 wrt-extra-tests-widgets --output=text --regexp="hosted_app_simple_install"
Encrypted widget is located:
 /opt/share/widget/tests/misc/widgets/encrypted.wgt (wrt-extra).

---

This change is also fixing hosted app installation as it was broken.

---

Change-Id: Idd1bfba88d3c8569fcbbc80eda1462cf7dfc9f16
src/CMakeLists.txt
src/jobs/widget_install/job_widget_install.cpp
src/jobs/widget_install/task_configuration.cpp
src/jobs/widget_install/task_configuration.h
src/jobs/widget_install/task_process_config.cpp [moved from src/jobs/widget_install/task_widget_config.cpp with 91% similarity]
src/jobs/widget_install/task_process_config.h [moved from src/jobs/widget_install/task_widget_config.h with 91% similarity]