diff options
author | Paul Duffin <paulduffin@google.com> | 2021-03-12 21:28:15 +0000 |
---|---|---|
committer | Paul Duffin <paulduffin@google.com> | 2021-03-14 01:08:26 +0000 |
commit | 6bac49c560e9aecd7c90550bc38c0270351aa33b (patch) | |
tree | e659d89f541539ce1eb52c7c79bd95698d8d82c8 /java/java_test.go | |
parent | 0ed42d3c9d208a6f06c3351fae3ffcf1e52ab4be (diff) |
Convert testJavaError to test fixtures
Bug: 182638834
Test: m nothing
Change-Id: If6de91cd60fea36c945f2b0d51a04e26c838e4af
Diffstat (limited to 'java/java_test.go')
-rw-r--r-- | java/java_test.go | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/java/java_test.go b/java/java_test.go index 670eefc76..2ef3f426f 100644 --- a/java/java_test.go +++ b/java/java_test.go @@ -147,7 +147,11 @@ func run(t *testing.T, ctx *android.TestContext, config android.Config) { // deprecated func testJavaError(t *testing.T, pattern string, bp string) (*android.TestContext, android.Config) { t.Helper() - return testJavaErrorWithConfig(t, pattern, testConfig(nil, bp, nil)) + result := javaFixtureFactory. + Extend(dexpreopt.PrepareForTestWithDexpreopt). + ExtendWithErrorHandler(android.FixtureExpectsAtLeastOneErrorMatchingPattern(pattern)). + RunTestWithBp(t, bp) + return result.TestContext, result.Config } // testJavaErrorWithConfig is a legacy way of running tests of java modules that expect errors. |