Any suggestions on a test case for my PR fixing by...
# ksp
z
Any suggestions on a test case for my PR fixing bytecode post processing?
t
Sorry I missed the discussion in the PR. Would you mind to try adding the artifact check around this to AndroidIT?
the path of artifact may need to be changed to
workload/build/outputs/apk/debug/workload-debug.apk
or
workload/build/outputs/apk/release/workload-release-unsigned.apk
z
will do
hmm, I don't think that'll work. I'll need to generate a proguard file and then read the merged proguard configuration from a proguard/R8 task run. Are you ok with that?
t
Sure, that's better than my proposal. I just tried w/w.o you patch and the log is not included / included so I guessed that it would work. Apparently what you said is more realistic and has better coverage.
👍 1
👍🏼 1
z
Where would be the right place to add a processor? The test-processor dir under playground-android has no sources so I’m not sure what it’s testing. I can add one there if needed
j
playground-android
has a base project of
playground
therefore is using the
playground
’s test processor implementation. If you are writing a custom test processor you can just put it under
test-processor
folder
z
ahhh ok
the next thing I'm stuck on is that I can't get tests to recognize my android SDK, even though I have all the envs set correctly 🤔. I'll push up what I have
I actually get internal failures when trying to run multiple tests, so I think something else is wrong? Updated the PR with what I have so far
j
it is quite unexpected since you are not touching test processors.. might have something to do with the build options. Let me note it and we can investigate it.
👍 1
t
Would you mind to try splitting the file extension passed into
codeGenerator.createNewFile
? The generated proguard file was treated as a Kotlin source and KSP's error handling didn't survive. 😢
z
that did it, let me add a test now
👍 1
ready!
t
Merged. Thanks!
👍🏼 1
👍 1