diff --git a/debian/changelog b/debian/changelog index 17095fc..0199f63 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,10 @@ +applauncherd (0.15.3) unstable; urgency=low + + * Implemented: SWP#DUI-4131 + * Changes: change warning message when library can't be preloaded + + -- Nimika Keshri Fri, 26 Nov 2010 13:47:26 +0200 + applauncherd (0.15.2) stable; urgency=low * Changes: Fixed crash of booster-m and booster-w / non-quitting booster-m caused diff --git a/meego/0.15.2/create-tarball.sh b/meego/0.15.3/create-tarball.sh similarity index 64% rename from meego/0.15.2/create-tarball.sh rename to meego/0.15.3/create-tarball.sh index b643966..0d4a5cc 100644 --- a/meego/0.15.2/create-tarball.sh +++ b/meego/0.15.3/create-tarball.sh @@ -1,8 +1,8 @@ #!/bin/sh if test -n "$1" then - git archive --format tar --remote=$1 --output=meegotouch-applauncherd-0.15.2.tar --prefix meegotouch-applauncherd-0.15.2/ released/0.15.2 - bzip2 meegotouch-applauncherd-0.15.2.tar + git archive --format tar --remote=$1 --output=meegotouch-applauncherd-0.15.3.tar --prefix meegotouch-applauncherd-0.15.3/ released/0.15.3 + bzip2 meegotouch-applauncherd-0.15.3.tar else echo "Usage: create-tarball.sh " echo " where is suitable for git archive --remote=" diff --git a/meego/0.15.2/meegotouch-applauncherd.changes b/meego/0.15.3/meegotouch-applauncherd.changes similarity index 82% rename from meego/0.15.2/meegotouch-applauncherd.changes rename to meego/0.15.3/meegotouch-applauncherd.changes index f761136..ca23941 100644 --- a/meego/0.15.2/meegotouch-applauncherd.changes +++ b/meego/0.15.3/meegotouch-applauncherd.changes @@ -1,3 +1,6 @@ +* Fri Nov 26 2010 Nimika Keshri - 0.15.3 +- Updated to version 0.15.3. + * Thu Sep 2 2010 Pertti Kellomäki - 0.12.1 - Updated to version 0.12.1. - Packaged tests and test scripts as subpackages, reorganized testing diff --git a/meego/0.15.2/meegotouch-applauncherd.spec b/meego/0.15.3/meegotouch-applauncherd.spec similarity index 99% rename from meego/0.15.2/meegotouch-applauncherd.spec rename to meego/0.15.3/meegotouch-applauncherd.spec index f0a97c0..ac5dedc 100644 --- a/meego/0.15.2/meegotouch-applauncherd.spec +++ b/meego/0.15.3/meegotouch-applauncherd.spec @@ -7,7 +7,7 @@ Name: meegotouch-applauncherd Summary: Application launcher for fast startup -Version: 0.15.2 +Version: 0.15.3 Release: 1 Group: System/Daemons License: LGPLv2+ diff --git a/meego/0.15.2/meegotouch-applauncherd.yaml b/meego/0.15.3/meegotouch-applauncherd.yaml similarity index 99% rename from meego/0.15.2/meegotouch-applauncherd.yaml rename to meego/0.15.3/meegotouch-applauncherd.yaml index 7605ca7..b7c2a9f 100644 --- a/meego/0.15.2/meegotouch-applauncherd.yaml +++ b/meego/0.15.3/meegotouch-applauncherd.yaml @@ -1,6 +1,6 @@ Name: meegotouch-applauncherd Summary: Application launcher for fast startup -Version: 0.15.2 +Version: 0.15.3 Release: 1 Group: System/Daemons License: LGPLv2+ diff --git a/src/launcher/launcher.c b/src/launcher/launcher.c index eaa7580..ddff47d 100644 --- a/src/launcher/launcher.c +++ b/src/launcher/launcher.c @@ -67,7 +67,7 @@ static void loadLibraries(const char * const libs[], unsigned int numLibs) dlerror(); if (!dlopen(lib + skipChar, flags)) { - fprintf(stderr, "%s\n", dlerror()); + fprintf(stderr, "Warning: can't preload %s\n", lib + skipChar); } } } diff --git a/tests/Harmattan/TestScripts/tc_theming.rb b/tests/Harmattan/TestScripts/tc_theming.rb index c38d211..afa609a 100755 --- a/tests/Harmattan/TestScripts/tc_theming.rb +++ b/tests/Harmattan/TestScripts/tc_theming.rb @@ -176,7 +176,7 @@ class TC_Theming < Test::Unit::TestCase "/tmp/testshot3.png", "/tmp/testshot4.png") end - def test_booster_killer + def test_theme_change_booster_restart m_pid = `pgrep -n booster-m` w_pid = `pgrep -n booster-w` print "Current booster-m %s" % m_pid diff --git a/tests/Harmattan/TestScripts/test-func-launcher.py b/tests/Harmattan/TestScripts/test-func-launcher.py index 88dc4bc..b226bf9 100644 --- a/tests/Harmattan/TestScripts/test-func-launcher.py +++ b/tests/Harmattan/TestScripts/test-func-launcher.py @@ -313,21 +313,6 @@ class launcher_tests (unittest.TestCase): self.assert_(success, "invoker terminated before delay elapsed") - def test_013_applauncherd_usage(self): - """ - Test applauncherd.bin help - """ - st, op = commands.getstatusoutput("applauncherd.bin --help") - self.assert_(st == 0, "Usage not printed") - str = op.split('\n') - self.assert_(str[0] == 'Usage: applauncherd [options]', "usage not printed properly") - - # exec invoker --creds (for coverage) - run_app_as_user("invoker --creds") - - # exec invoker --help (for coverage) - run_app_as_user("invoker --help") - def test_014_fd_booster_m(self): """ diff --git a/tests/Harmattan/art-tests/tests.xml b/tests/Harmattan/art-tests/tests.xml index 204fd44..6735ddd 100644 --- a/tests/Harmattan/art-tests/tests.xml +++ b/tests/Harmattan/art-tests/tests.xml @@ -10,20 +10,20 @@ /usr/bin/waitloadavg.rb -l 1.0 -p 1.0 -t 120 - + source /tmp/session_bus_address.user; DISPLAY=:0 `pyversions -d` /usr/share/applauncherd-testscripts/test-func-launcher.py test_003_zombie_state - + source /tmp/session_bus_address.user; DISPLAY=:0 `pyversions -d` /usr/share/applauncherd-testscripts/test-func-launcher.py test_004_launch_multiple_apps - + source /tmp/session_bus_address.user; DISPLAY=:0 `pyversions -d` /usr/share/applauncherd-testscripts/test-func-launcher.py test_005_one_instance - @@ -40,7 +40,7 @@ /usr/bin/waitloadavg.rb -l 1.0 -p 1.0 -t 120 - + source /tmp/session_bus_address.user; DISPLAY=:0 /usr/share/applauncherd-testscripts/ts_prestartapp.rb name test_launch_prestarted_app diff --git a/tests/Harmattan/bug-tests/tests.xml b/tests/Harmattan/bug-tests/tests.xml index 6df9fb3..7985cb3 100644 --- a/tests/Harmattan/bug-tests/tests.xml +++ b/tests/Harmattan/bug-tests/tests.xml @@ -57,8 +57,8 @@ source /tmp/session_bus_address.user; DISPLAY=:0 /usr/share/applauncherd-testscripts/tc_theming.rb --name test_global_theming - - source /tmp/session_bus_address.user; DISPLAY=:0 /usr/share/applauncherd-testscripts/tc_theming.rb --name test_booster_killer + + source /tmp/session_bus_address.user; DISPLAY=:0 /usr/share/applauncherd-testscripts/tc_theming.rb --name test_theme_change_booster_restart true diff --git a/tests/Harmattan/functests/tests.xml b/tests/Harmattan/functests/tests.xml index b0274f5..b9405e9 100644 --- a/tests/Harmattan/functests/tests.xml +++ b/tests/Harmattan/functests/tests.xml @@ -39,10 +39,6 @@ source /tmp/session_bus_address.user; DISPLAY=:0 `pyversions -d` /usr/share/applauncherd-testscripts/test-func-launcher.py test_012 - - source /tmp/session_bus_address.user; DISPLAY=:0 `pyversions -d` /usr/share/applauncherd-testscripts/test-func-launcher.py test_013_applauncherd_usage - - source /tmp/session_bus_address.user; DISPLAY=:0 `pyversions -d` /usr/share/applauncherd-testscripts/test-func-launcher.py test_invoker_search_prog diff --git a/tests/Harmattan/perftests/tests.xml b/tests/Harmattan/perftests/tests.xml index b209ae9..79ee02c 100644 --- a/tests/Harmattan/perftests/tests.xml +++ b/tests/Harmattan/perftests/tests.xml @@ -10,7 +10,7 @@ /usr/bin/waitloadavg.rb -l 1.0 -p 1.0 -t 120 - + source /tmp/session_bus_address.user; DISPLAY=:0 `pyversions -d` /usr/share/applauncherd-testscripts/test-perf-mbooster.py test_001 > /tmp/launcher_perf.txt @@ -29,12 +29,12 @@ /usr/bin/waitloadavg.rb -l 1.0 -p 1.0 -t 120 - + source /tmp/session_bus_address.user; DISPLAY=:0 /usr/share/applauncherd-testscripts/test-perf.rb name test_performance -- -a fala_wol -b "fala_wol" > /tmp/perf_grid_without_launcher.txt - + source /tmp/session_bus_address.user; DISPLAY=:0 /usr/share/applauncherd-testscripts/test-perf.rb name test_performance -- -a fala_wl -b "fala_wl" > /tmp/perf_grid_with_launcher.txt @@ -56,11 +56,12 @@ /usr/bin/waitloadavg.rb -l 1.0 -p 1.0 -t 120 - + source /tmp/session_bus_address.user; DISPLAY=:0 /usr/share/applauncherd-testscripts/test-perf.rb name test_performance -- -c /usr/bin/fala_wl -b "fala_wl" > /tmp/perf_commandline_with_launcher.txt - + source /tmp/session_bus_address.user; DISPLAY=:0 /usr/share/applauncherd-testscripts/test-perf.rb name test_performance -- -c /usr/bin/fala_wol -b "fala_wol" > /tmp/perf_commandline_without_launcher.txt + false diff --git a/tests/Meego/TestScripts/tc_theming.rb b/tests/Meego/TestScripts/tc_theming.rb index c38d211..0e3a4c1 100755 --- a/tests/Meego/TestScripts/tc_theming.rb +++ b/tests/Meego/TestScripts/tc_theming.rb @@ -86,7 +86,7 @@ class TC_Theming < Test::Unit::TestCase system("pkill #{app_name}") - system("su - user -c #{app_name}&") + system("su - meego -c #{app_name}&") sleep(5) #pid = `pgrep -n #{app_name}` @@ -136,7 +136,7 @@ class TC_Theming < Test::Unit::TestCase # start app and take screenshots of the themed widgets system("pkill #{app_without_launcher}") system("pkill #{app_with_launcher}") - system("su - user -c #{app_without_launcher} &") + system("su - meego -c #{app_without_launcher} &") sleep(5) app = @sut.application(:name => app_without_launcher) @@ -150,7 +150,7 @@ class TC_Theming < Test::Unit::TestCase sleep(5) # once again using the launcher - system("su - user -c #{app_with_launcher} &") + system("su - meego -c #{app_with_launcher} &") sleep(5) app = @sut.application(:name => app_with_launcher) @@ -184,7 +184,7 @@ class TC_Theming < Test::Unit::TestCase app_name = 'fala_ft_hello' system("pkill #{app_name}") - system("su - user -c #{app_name}&") + system("su - meego -c #{app_name}&") sleep(2) original_theme = get_theme() diff --git a/tests/Meego/TestScripts/test-func-launcher.py b/tests/Meego/TestScripts/test-func-launcher.py index e6ef8da..4ced66f 100644 --- a/tests/Meego/TestScripts/test-func-launcher.py +++ b/tests/Meego/TestScripts/test-func-launcher.py @@ -111,16 +111,18 @@ class launcher_tests (unittest.TestCase): #self.kill_process(LAUNCHER_BINARY) process_handle = run_app_as_user(PREFERED_APP) - process_id = wait_for_app(PREFERED_APP, 5) - print process_id + process_id = wait_for_app(PREFERED_APP, 50) + debug("Pid of ",PREFERED_APP," is :",process_id) + time.sleep(2) kill_process(PREFERED_APP) - time.sleep(4) + time.sleep(2) process_handle = run_app_as_user(PREFERED_APP) - process_id1 = wait_for_app(PREFERED_APP, 5) - print process_id1 + process_id1 = wait_for_app(PREFERED_APP, 50) + debug("Pid of ",PREFERED_APP," is :",process_id1) + time.sleep(2) kill_process(PREFERED_APP) - time.sleep(4) + time.sleep(2) process_id1 = get_pid(PREFERED_APP) print process_id1 @@ -141,11 +143,13 @@ class launcher_tests (unittest.TestCase): for app in LAUNCHABLE_APPS: p = run_app_as_user(app) - pid = wait_for_app(app, timeout = 10, sleep = 1) + pid = wait_for_app(app, timeout = 100, sleep = 1) + time.sleep(6) + debug("Pid of ",app," is :",pid) if pid == None: kill_launched(pidlist) - self.fail("%s was not launched using applauncherd") + self.fail("%s was not launched using applauncherd",app) pidlist.append(pid) @@ -163,12 +167,13 @@ class launcher_tests (unittest.TestCase): #y = commands.getstatusoutput(pgrep appname) #len(y[-1].split(' ')) == 1 process_handle = run_app_as_user(PREFERED_APP) - process_id = wait_for_app(PREFERED_APP) - debug("PID of first %s" % process_id) + time.sleep(2) + process_id = wait_for_app(PREFERED_APP, 100) + debug("PID of 1st %s" % process_id) process_handle1 = run_app_as_user(PREFERED_APP) time.sleep(2) - process_id = wait_for_app(PREFERED_APP) + process_id = wait_for_app(PREFERED_APP,100) debug("PID of 2nd %s" % process_id) kill_process(PREFERED_APP) @@ -186,7 +191,7 @@ class launcher_tests (unittest.TestCase): #in a global dictionary, append the pid process_handle = run_app_as_user(app) - time.sleep(8) + time.sleep(30) process_id = get_pid('fala_ft_hello') pid_list = process_id.split() @@ -209,14 +214,16 @@ class launcher_tests (unittest.TestCase): # Launch the app with invoker using --wait-term p = run_app_as_user('invoker --type=m --wait-term %s' % app_path) - time.sleep(2) + time.sleep(4) # Retrieve their pids invoker_pid = wait_for_app('invoker') + time.sleep(4) app_pid = wait_for_app('fala_ft_hello') + time.sleep(4) - print "invoker_pid '%s'" % invoker_pid - print "app_pid '%s'" % app_pid + debug("invoker_pid ", invoker_pid) + debug("app_pid " ,app_pid) # Make sure that both apps started self.assert_(invoker_pid != None, "invoker not executed?") @@ -225,7 +232,7 @@ class launcher_tests (unittest.TestCase): # Send SIGTERM to invoker, the launched app should die kill_process(None, invoker_pid, 15) - time.sleep(2) + time.sleep(8) # This should be None app_pid2 = get_pid('fala_ft_hello') @@ -252,7 +259,9 @@ class launcher_tests (unittest.TestCase): time.sleep(5) st, op = commands.getstatusoutput('pgrep -lf "applauncherd.bin --daemon"') - print op + time.sleep(5) + + debug("The pid of applauncherd in daemon mode is :", op) # filter some cruft out from the output and see how many # instances are running @@ -265,9 +274,10 @@ class launcher_tests (unittest.TestCase): # try to launch an app run_app_as_user('/usr/bin/fala_ft_hello') - time.sleep(2) + time.sleep(6) pid = wait_for_app('fala_ft_hello') + time.sleep(6) if pid != None: kill_process(apppid = pid) @@ -313,21 +323,6 @@ class launcher_tests (unittest.TestCase): self.assert_(success, "invoker terminated before delay elapsed") - def test_013_applauncherd_usage(self): - """ - Test applauncherd.bin help - """ - st, op = commands.getstatusoutput("applauncherd.bin --help") - self.assert_(st == 0, "Usage not printed") - str = op.split('\n') - self.assert_(str[0] == 'Usage: applauncherd [options]', "usage not printed properly") - - # exec invoker --creds (for coverage) - run_app_as_user("invoker --creds") - - # exec invoker --help (for coverage) - run_app_as_user("invoker --help") - def test_014_fd_booster_m(self): """ diff --git a/tests/Meego/TestScripts/utils.py b/tests/Meego/TestScripts/utils.py index b116782..450c2c0 100644 --- a/tests/Meego/TestScripts/utils.py +++ b/tests/Meego/TestScripts/utils.py @@ -46,7 +46,7 @@ def start_applauncherd(): return handle.wait() == 0 -def stop_applauncherd(): +def kill_applauncherd(): handle = Popen(['initctl', 'stop', 'xsession/applauncherd'], stdout = DEV_NULL, stderr = DEV_NULL, shell = False) @@ -87,16 +87,14 @@ def get_pid(appname): else: return None -def get_newest_pid(app): - p = subprocess.Popen(['pgrep', '-n', app], shell = False, - stdout = subprocess.PIPE, stderr = DEV_NULL) - - op = p.communicate()[0] - - if p.wait() == 0: - return op.strip() - - return None +def get_newest_pid(appname): + temp = basename(appname)[:14] + st, op = commands.getstatusoutput("pgrep -n %s" % temp) + time.sleep(5) + if st == 0: + return op + else: + return None def wait_for_app(app = None, timeout = 5, sleep = 0.5): """ diff --git a/tests/Meego/functests/tests.xml b/tests/Meego/functests/tests.xml index 86f22e1..6c1d303 100644 --- a/tests/Meego/functests/tests.xml +++ b/tests/Meego/functests/tests.xml @@ -39,10 +39,6 @@ source /tmp/session_bus_address.user; DISPLAY=:0 python2.6 /usr/share/applauncherd-M-testscripts/test-func-launcher.py test_012 - - source /tmp/session_bus_address.user; DISPLAY=:0 python2.6 /usr/share/applauncherd-M-testscripts/test-func-launcher.py test_013_applauncherd_usage - - source /tmp/session_bus_address.user; DISPLAY=:0 python2.6 /usr/share/applauncherd-M-testscripts/test-func-launcher.py test_invoker_search_prog