Fix: AnnotationTest is failing for P-launching devices

AnnotationTest is failing for P-launching devices that do not have
Android Auto APIs. This is a regression caused by f838cc917d364faa4a346f4587fadc5b2be52003
that added Android Auto APIs to the expected APIs set.

AbstractApiChecker that the test is inheriting from ensures that all
documented APIs are found in the device under test. That behavior is
required for other signature tests such as
CtsCurrentApiSignatureTestCases, but is not required for this test.
The primary goal of this test is to make sure that the set of APIs (such
as ones annotated with @SystemApi) is not greater than the documented
API set. It is not an error that the former is smaller than the latter.

Fixing the issue by adding a new overridable method 'checkMissingClass'
that can be used for each test to handle the missing class case
differently.

Bug: 122276795
Test: run CtsSystemApiAnnotationTestCases on Pixel 3

Change-Id: Ifd58b10b2c496eb495f5286bf8413302a6c8895f
2 files changed