Custom Task and dryRun in gradle 8x

Hey, I’m trying to migrate to gradle 8x from 7x.
There’s already an task something like this

class EfTestTask extends Test {
    @Input
    boolean integration;
 ...
}

now when I’ve upgraded to 8x I have following error:

Could not compile script 'EfTestTask.gradle'.
> startup failed:
  script 'EfTestTask.gradle': 5: Can't have an abstract method in a non-abstract class. The class 'EfTestTask' must be declared abstract or the method 'org.gradle.api.provider.Property getDryRun()' must be implemented.
   @ line 5, column 1.
     class EfTestTask extends Test {
     ^

how can I configure that dryRun? I’ve tried to add

@Input Property<Boolean> dryRun

but then I have this

   > Could not create task of type 'EfTestTask'.
      > Cannot invoke "org.gradle.api.provider.Property.convention(Object)" because the return value of "org.gradle.api.tasks.testing.Test.getDryRun()" is null

this build is somehow complicated and I’m not author of it so I’m trying to understand what should I do in order to migrate to gradle 8x

The “problem” is, that you are extending the built-in Test task class.
Most often extending built-in task classes is not really a good idea.
Anyway, in Gradle 8 the built-in Test task class became abstract and got the abstract getDryRun method.
Just declare your class abstract too and you are fine.