Skip to content

Commit b96e9bf

Browse files
nreid260Dagger Team
authored andcommitted
Internal change
PiperOrigin-RevId: 638422441
1 parent a8581e0 commit b96e9bf

File tree

3 files changed

+28
-21
lines changed

3 files changed

+28
-21
lines changed

java/dagger/hilt/android/testing/compile/HiltCompilerTests.java

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -162,7 +162,8 @@ public static void compileWithKapt(
162162
/* classpath= */ ImmutableList.of(CompilerTests.compilerDepsJar()),
163163
/* inheritClasspath= */ false,
164164
/* javacArguments= */ ImmutableList.of(),
165-
/* kotlincArguments= */ ImmutableList.of(),
165+
/* kotlincArguments= */ ImmutableList.of(
166+
),
166167
/* kaptProcessors= */ ImmutableList.<Processor>builder()
167168
.addAll(defaultProcessors())
168169
.addAll(additionalProcessors)
@@ -276,7 +277,8 @@ public void compile(Consumer<CompilationResultSubject> onCompilationResult) {
276277
/* options= */ processorOptions(),
277278
/* javacArguments= */ javacArguments().asList(),
278279
/* kotlincArguments= */ ImmutableList.of(
279-
"-P", "plugin:org.jetbrains.kotlin.kapt3:correctErrorTypes=true"),
280+
"-P",
281+
"plugin:org.jetbrains.kotlin.kapt3:correctErrorTypes=true"),
280282
/* config= */ HiltProcessingEnvConfigs.CONFIGS,
281283
/* javacProcessors= */ ImmutableList.<Processor>builder()
282284
.addAll(mergeProcessors(defaultProcessors(), additionalJavacProcessors()))

java/dagger/testing/compile/CompilerTests.java

Lines changed: 17 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -137,7 +137,8 @@ public void compile(Consumer<XTestInvocation> onInvocation) {
137137
/* classpath= */ ImmutableList.of(),
138138
processorOptions(),
139139
/* javacArguments= */ ImmutableList.of(),
140-
/* kotlincArguments= */ ImmutableList.of(),
140+
/* kotlincArguments= */ ImmutableList.of(
141+
),
141142
/* config= */ PROCESSING_ENV_CONFIG,
142143
invocation -> {
143144
onInvocation.accept(invocation);
@@ -230,7 +231,8 @@ public void compile(Consumer<CompilationResultSubject> onCompilationResult) {
230231
processorOptions(),
231232
/* javacArguments= */ ImmutableList.of(),
232233
/* kotlincArguments= */ ImmutableList.of(
233-
"-P", "plugin:org.jetbrains.kotlin.kapt3:correctErrorTypes=true"),
234+
"-P",
235+
"plugin:org.jetbrains.kotlin.kapt3:correctErrorTypes=true"),
234236
/* config= */ PROCESSING_ENV_CONFIG,
235237
/* javacProcessors= */ mergeProcessors(
236238
ImmutableList.of(
@@ -306,17 +308,19 @@ public static void compileWithKapt(
306308
Map<String, String> processorOptions,
307309
TemporaryFolder tempFolder,
308310
Consumer<TestCompilationResult> onCompilationResult) {
309-
TestCompilationResult result = TestKotlinCompilerKt.compile(
310-
tempFolder.getRoot(),
311-
new TestCompilationArguments(
312-
sources,
313-
/*classpath=*/ ImmutableList.of(compilerDepsJar()),
314-
/*inheritClasspath=*/ false,
315-
/*javacArguments=*/ ImmutableList.of(),
316-
/*kotlincArguments=*/ ImmutableList.of(),
317-
/*kaptProcessors=*/ ImmutableList.of(new ComponentProcessor()),
318-
/*symbolProcessorProviders=*/ ImmutableList.of(),
319-
/*processorOptions=*/ processorOptions));
311+
TestCompilationResult result =
312+
TestKotlinCompilerKt.compile(
313+
tempFolder.getRoot(),
314+
new TestCompilationArguments(
315+
sources,
316+
/* classpath= */ ImmutableList.of(compilerDepsJar()),
317+
/* inheritClasspath= */ false,
318+
/* javacArguments= */ ImmutableList.of(),
319+
/* kotlincArguments= */ ImmutableList.of(
320+
),
321+
/* kaptProcessors= */ ImmutableList.of(new ComponentProcessor()),
322+
/* symbolProcessorProviders= */ ImmutableList.of(),
323+
/* processorOptions= */ processorOptions));
320324
onCompilationResult.accept(result);
321325
}
322326

javatests/dagger/internal/codegen/XTypesStripTypeNameTest.java

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -187,12 +187,13 @@ private static void assertStrippedWildcardTypeNameEquals(Source source, String s
187187
private static void runTest(Source source, Function<XTestInvocation, Void> handler) {
188188
runProcessorTest(
189189
ImmutableList.of(source),
190-
/* classpath = */ ImmutableList.of(),
191-
/* options = */ ImmutableMap.of(),
192-
/* javacArguments = */ ImmutableList.of(),
193-
/* kotlincArguments = */ ImmutableList.of(),
194-
/* config = */ new XProcessingEnvConfig.Builder().build(),
195-
/* handler = */ invocation -> {
190+
/* classpath= */ ImmutableList.of(),
191+
/* options= */ ImmutableMap.of(),
192+
/* javacArguments= */ ImmutableList.of(),
193+
/* kotlincArguments= */ ImmutableList.of(
194+
),
195+
/* config= */ new XProcessingEnvConfig.Builder().build(),
196+
/* handler= */ invocation -> {
196197
handler.apply(invocation);
197198
return null;
198199
});

0 commit comments

Comments
 (0)