@@ -1859,19 +1859,20 @@ Rectangle {
1860 var app1 = ApplicationManager.startApplication("libreoffice");
1860 var app1 = ApplicationManager.startApplication("libreoffice");
1861 waitUntilAppWindowIsFullyLoaded(app1);
1861 waitUntilAppWindowIsFullyLoaded(app1);
1862− var app2 = ApplicationManager.startApplication("dialer-app");
1862+ var app2 = ApplicationManager.startApplication("gallery-app");
1863 waitUntilAppWindowIsFullyLoaded(app2);
1863 waitUntilAppWindowIsFullyLoaded(app2);
1865− // Make sure app1 is unfocused but still running
1865+ // Make sure app1 is exempt with a requested suspend
1866− compare(app1.session.surface.activeFocus, false);
1866+ verify(app1.exemptFromLifecycle);
1867− compare(app1.isTouchApp, false); // sanity check our mock, which sets this for us
1867+ verify(!app1.isTouchApp); // sanity check our mock, which sets this for us
1868+ verify(!app1.session.surface.activeFocus);
1868− compare(app1.requestedState, ApplicationInfoInterface.RequestedRunning);
1869+ compare(app1.requestedState, ApplicationInfoInterface.RequestedSuspended);
1871 function test_lifecyclePolicyExemption_data() {
1872 function test_lifecyclePolicyExemption_data() {
1872 return [
1873 return [
1873− {tag: "phone", formFactor: "phone", usageScenario: "phone", suspendsApps: true},
1874+ {tag: "phone", formFactor: "phone", usageScenario: "phone"},
1874− {tag: "tablet", formFactor: "tablet", usageScenario: "tablet", suspendsApps: true}
1875+ {tag: "tablet", formFactor: "tablet", usageScenario: "tablet"}
@@ -1883,12 +1884,13 @@ Rectangle {
1884 var app1 = ApplicationManager.startApplication("webbrowser-app");
1885 var app1 = ApplicationManager.startApplication("webbrowser-app");
1885 waitUntilAppWindowIsFullyLoaded(app1);
1886 waitUntilAppWindowIsFullyLoaded(app1);
1886− var app2 = ApplicationManager.startApplication("dialer-app");
1887+ var app2 = ApplicationManager.startApplication("gallery-app");
1887 waitUntilAppWindowIsFullyLoaded(app2);
1888 waitUntilAppWindowIsFullyLoaded(app2);
1889− // Make sure app1 is unfocused but still running
1890+ // Make sure app1 is exempt with a requested suspend
1891+ verify(app1.exemptFromLifecycle);
1890− compare(app1.session.surface.activeFocus, false);
1892+ verify(!app1.session.surface.activeFocus);
1891− compare(app1.requestedState, ApplicationInfoInterface.RequestedRunning);
1893+ compare(app1.requestedState, ApplicationInfoInterface.RequestedSuspended);
1894 function test_switchToStagedForcesLegacyAppClosing_data() {
1896 function test_switchToStagedForcesLegacyAppClosing_data() {