Ensure the app is killed before collecting startup time metrics

The measured app startup time was not collected correctly while running
metrics because the app was not killed. Tear down the application and
get the cold app startup time.

Bug: 236621823
Test: atest AVFHostTestCase#testAppStartupTime
Change-Id: I85f145373bc773d8371df40f3fadd434cba60737
diff --git a/tests/benchmark_hostside/java/android/avf/test/AVFHostTestCase.java b/tests/benchmark_hostside/java/android/avf/test/AVFHostTestCase.java
index f3aa199..17f773e 100644
--- a/tests/benchmark_hostside/java/android/avf/test/AVFHostTestCase.java
+++ b/tests/benchmark_hostside/java/android/avf/test/AVFHostTestCase.java
@@ -159,6 +159,8 @@
             throws DeviceNotAvailableException, InterruptedException {
         CommandRunner android = new CommandRunner(getDevice());
         unlockScreen(android);
+        // Ensure we are killing the app to get the cold app startup time
+        android.run("am force-stop " + pkgName);
         android.run("echo 3 > /proc/sys/vm/drop_caches");
         String vmStartAppLog = android.run("am", "start -W -S " + pkgName);
         assertNotNull(vmStartAppLog);