Make IpClientIntegrationTest pass on rvc-dev.
On rvc-dev, IpClientIntegrationTest fails almost all the time because the tap interface disappears before the tests can run. This is due to the ParcelFileDescriptor finalizer, which helpfully closes the fd stored in the object even if it is in use elsewhere. Stash the ParcelFileDescriptor itself in the test class, instead of the actual FileDescriptor which everything uses, in order to ensure that the garbage collector does not finalize it. With this change, IpClientIntegrationTest#testRaRdnss (just an arbitrary test case in that class) goes from 10/10 failures to 10/10 passes. Bug: 152723363 Test: atest NetworkStackNextIntegrationTests:IpClientIntegrationTest#testRaRdnss Change-Id: I1015e7893ba6af74876665826960e8fcc1711476
Loading
Please register or sign in to comment