Skip to content

Commit

Permalink
Fix bug where on AGP 7.0+ the Gradle plugin bytecode transform was no…
Browse files Browse the repository at this point in the history
…t applied to non-test code.

Also add AGP 7.0.0-beta04 to the AGP versions we test.

Fixes #2784.

RELNOTES=Fix bug where on AGP 7.0+ the Gradle plugin bytecode transform was not applied to non-test code (#2784)
PiperOrigin-RevId: 386999244
  • Loading branch information
Chang-Eric authored and Dagger Team committed Jul 27, 2021
1 parent 2ba9ce0 commit 666df50
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 1 deletion.
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,7 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
agp: ['4.1.0', '4.2.0']
agp: ['4.1.0', '4.2.0', '7.0.0-beta04']
steps:
- name: 'Check out repository'
uses: actions/checkout@v2
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@ sealed class AndroidComponentsExtensionCompat {
) : AndroidComponentsExtensionCompat() {
override fun onAllVariants(block: (ComponentCompat) -> Unit) {
actual.onVariants { variant ->
block.invoke(ComponentCompat.Api70Impl(variant))
when (variant) {
is ApplicationVariant -> variant.androidTest
is LibraryVariant -> variant.androidTest
Expand Down
1 change: 1 addition & 0 deletions util/run-local-tests.sh
Original file line number Diff line number Diff line change
Expand Up @@ -18,4 +18,5 @@ pushd examples/maven && mvn compile && popd
util/run-local-gradle-tests.sh
util/run-local-gradle-android-tests.sh "4.1.0"
util/run-local-gradle-android-tests.sh "4.2.0"
util/run-local-gradle-android-tests.sh "7.0.0-beta04"

0 comments on commit 666df50

Please sign in to comment.