xref: /aosp_15_r20/external/mockito/build.gradle (revision ceffa222020788e9b81e120db61d5f29c922f983)
1*ceffa222STreehugger Robotapply plugin: 'java'
2*ceffa222STreehugger Robot
3*ceffa222STreehugger Robotconfigurations {
4*ceffa222STreehugger Robot    // similar to 'default', export compile-time dependencies
5*ceffa222STreehugger Robot    host.extendsFrom(hostCompile)
6*ceffa222STreehugger Robot    target.extendsFrom(targetCompile)
7*ceffa222STreehugger Robot}
8*ceffa222STreehugger Robot
9*ceffa222STreehugger RobotsourceSets {
10*ceffa222STreehugger Robot    host {
11*ceffa222STreehugger Robot        java {
12*ceffa222STreehugger Robot            srcDirs = ['src', 'cglib-and-asm/src']
13*ceffa222STreehugger Robot        }
14*ceffa222STreehugger Robot    }
15*ceffa222STreehugger Robot
16*ceffa222STreehugger Robot    target {
17*ceffa222STreehugger Robot        java {
18*ceffa222STreehugger Robot            srcDirs = ['src']
19*ceffa222STreehugger Robot            exclude 'org/mockito/internal/creation/cglib/**',
20*ceffa222STreehugger Robot                    'org/mockito/internal/creation/jmock/**',
21*ceffa222STreehugger Robot                    'org/mockito/internal/creation/AbstractMockitoMethodProxy.java',
22*ceffa222STreehugger Robot                    'org/mockito/internal/creation/AcrossJVMSerializationFeature.java',
23*ceffa222STreehugger Robot                    'org/mockito/internal/creation/CglibMockMaker.java',
24*ceffa222STreehugger Robot                    'org/mockito/internal/creation/DelegatingMockitoMethodProxy.java',
25*ceffa222STreehugger Robot                    'org/mockito/internal/creation/MethodInterceptorFilter.java',
26*ceffa222STreehugger Robot                    'org/mockito/internal/creation/MockitoMethodProxy.java',
27*ceffa222STreehugger Robot                    'org/mockito/internal/creation/SerializableMockitoMethodProxy.java',
28*ceffa222STreehugger Robot                    'org/mockito/internal/invocation/realmethod/FilteredCGLIBProxyRealMethod.java',
29*ceffa222STreehugger Robot                    'org/mockito/internal/invocation/realmethod/CGLIBProxyRealMethod.java',
30*ceffa222STreehugger Robot                    'org/mockito/internal/invocation/realmethod/HasCGLIBMethodProxy.java'
31*ceffa222STreehugger Robot        }
32*ceffa222STreehugger Robot    }
33*ceffa222STreehugger Robot}
34*ceffa222STreehugger Robot
35*ceffa222STreehugger Robotdependencies {
36*ceffa222STreehugger Robot    targetCompile project(':hamcrest')
37*ceffa222STreehugger Robot    targetCompile project(':objenesis')
38*ceffa222STreehugger Robot    targetCompile project(path: ':junit', configuration: 'target')
39*ceffa222STreehugger Robot
40*ceffa222STreehugger Robot    hostCompile project(':hamcrest')
41*ceffa222STreehugger Robot    hostCompile project(':objenesis')
42*ceffa222STreehugger Robot    hostCompile project(path: ':junit', configuration: 'host')
43*ceffa222STreehugger Robot    hostCompile 'org.apache.ant:ant:1.8.0'
44*ceffa222STreehugger Robot}
45*ceffa222STreehugger Robot
46*ceffa222STreehugger Robottask targetJar(type: Jar) {
47*ceffa222STreehugger Robot    from sourceSets.target.output
48*ceffa222STreehugger Robot    dependsOn targetClasses
49*ceffa222STreehugger Robot    baseName "mockito"
50*ceffa222STreehugger Robot    classifier "target"
51*ceffa222STreehugger Robot}
52*ceffa222STreehugger Robot
53*ceffa222STreehugger Robottask hostJar(type: Jar) {
54*ceffa222STreehugger Robot    from sourceSets.host.output
55*ceffa222STreehugger Robot    dependsOn hostClasses
56*ceffa222STreehugger Robot    baseName "mockito"
57*ceffa222STreehugger Robot    classifier "host"
58*ceffa222STreehugger Robot}
59*ceffa222STreehugger Robot
60*ceffa222STreehugger Robotartifacts {
61*ceffa222STreehugger Robot    host hostJar
62*ceffa222STreehugger Robot    target targetJar
63*ceffa222STreehugger Robot}
64