Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit b373ce34 authored by Gavin Williams's avatar Gavin Williams
Browse files

Update NPMSTest to check for file existence

Add a check for file exists to prevent test crash

Bug: 432481295
Test: atest services/tests/servicestests/src/com/android/server/net/NetworkPolicyManagerServiceTest.java
Flag: TEST_ONLY
Change-Id: I73de33622821b58018669ebe5d8e79b4c29f70d7
parent a36f5b8e
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -643,7 +643,7 @@ public class NetworkPolicyManagerServiceTest {

    @After
    public void removeFiles() throws Exception {
        if (mPolicyDir != null) {
        if (mPolicyDir != null && mPolicyDir.exists()) {
            for (File file : mPolicyDir.listFiles()) {
                file.delete();
            }