diff options
author | 2023-12-18 22:43:45 +0000 | |
---|---|---|
committer | 2023-12-18 22:43:45 +0000 | |
commit | 51428c451a73d9d246ccecd045b0b8c76a417df1 (patch) | |
tree | 5113d87ec33b1e96150a9ad5df463e579facdb18 /apex/classpath_element_test.go | |
parent | 8070c4b457d890455bd7c8437ab84d02d9e7f3bc (diff) | |
parent | 5a37718c956b1bfbda5e236c0fe50f08661a81de (diff) |
Merge changes I6f116385,Id77f514d,I73479de1,If58f4b53 into main
* changes:
Convert ModuleProvder to generic providers API
Convert OtherModuleProvider to generic providers API
Convert Provider to generic providers API
Convert SetProvider to generic providers API
Diffstat (limited to 'apex/classpath_element_test.go')
-rw-r--r-- | apex/classpath_element_test.go | 16 |
1 files changed, 6 insertions, 10 deletions
diff --git a/apex/classpath_element_test.go b/apex/classpath_element_test.go index 1ce60ced9..b9a91982a 100644 --- a/apex/classpath_element_test.go +++ b/apex/classpath_element_test.go @@ -20,7 +20,6 @@ import ( "android/soong/android" "android/soong/java" - "github.com/google/blueprint" ) // Contains tests for java.CreateClasspathElements logic from java/classpath_element.go that @@ -28,19 +27,12 @@ import ( // testClasspathElementContext is a ClasspathElementContext suitable for use in tests. type testClasspathElementContext struct { + android.OtherModuleProviderContext testContext *android.TestContext module android.Module errs []error } -func (t *testClasspathElementContext) OtherModuleHasProvider(module blueprint.Module, provider blueprint.AnyProviderKey) bool { - return t.testContext.ModuleHasProvider(module, provider) -} - -func (t *testClasspathElementContext) OtherModuleProvider(module blueprint.Module, provider blueprint.AnyProviderKey) interface{} { - return t.testContext.ModuleProvider(module, provider) -} - func (t *testClasspathElementContext) ModuleErrorf(fmt string, args ...interface{}) { t.errs = append(t.errs, t.testContext.ModuleErrorf(t.module, fmt, args...)) } @@ -238,7 +230,11 @@ func TestCreateClasspathElements(t *testing.T) { } newCtx := func() *testClasspathElementContext { - return &testClasspathElementContext{testContext: result.TestContext, module: bootclasspath} + return &testClasspathElementContext{ + OtherModuleProviderContext: result.TestContext.OtherModuleProviderAdaptor(), + testContext: result.TestContext, + module: bootclasspath, + } } // Verify that CreateClasspathElements works when given valid input. |