Let resolv_integration_test listen to onPrivateDnsValidationEvent
The resolver integration tests used to consider the private dns validation complete by means of monitoring whether the testing servers receive the validation packet or not, which could cause the tests to flake. The reason is: the validation flag hasn't yet been marked as SUCCESS in PrivateDnsConfiguration. At that moment, since the testing servers has received the validation packet, the tests consider the private dns server is available and then start querying. If the flag still hasn't been marked as SUCCESS, the query go over udp. This change make the tests listen to onPrivateDnsValidationEvent which guarantees the flag has already been marked. Besides, we are able to have test coverage for onPrivateDnsValidationEvent now. Bug: 124422785 Bug: 139327133 Test: atest --include-subdirs packages/modules/DnsResolver Test: resolv_integration_test --gtest_repeat=1000 --gtest_filter="ResolverTest.BrokenEdns" Change-Id: I0b11f98c3e8c44e4b347621a79815a19689f155b
Loading
Please register or sign in to comment