Finishing helper activity in test teardown

If the activity is left started when a test fails, it can interfere with
subsequent tests that depend on the app to be in a certain
process-state.

Test: atest CtsHostsideNetworkPolicyTests:HostsideConnOnActivityStartTest

Bug: 335333785
(cherry picked from https://googleplex-android-review.googlesource.com/q/commit:1050e8e0cbd3c07c729abda4678d1ed227e63eb3)
Merged-In: I3be40a8d9e7c3b358ec8b26cb881534fc948f214
Change-Id: I3be40a8d9e7c3b358ec8b26cb881534fc948f214
diff --git a/tests/cts/hostside-network-policy/app/src/com/android/cts/netpolicy/hostside/ConnOnActivityStartTest.java b/tests/cts/hostside-network-policy/app/src/com/android/cts/netpolicy/hostside/ConnOnActivityStartTest.java
index 4fbf116..811190f 100644
--- a/tests/cts/hostside-network-policy/app/src/com/android/cts/netpolicy/hostside/ConnOnActivityStartTest.java
+++ b/tests/cts/hostside-network-policy/app/src/com/android/cts/netpolicy/hostside/ConnOnActivityStartTest.java
@@ -53,6 +53,7 @@
     @After
     public final void tearDown() throws Exception {
         super.tearDown();
+        finishActivity();
         resetDeviceState();
     }