Gradle DSL method not found: 'destination()' after update to Gradle 5.2.1

Before Gradle 5.0 the method setDestination(Object file) was already deprecated, see here : setDestination(Object file)

In Gradle 5.x this method has been removed, you must now use setDestination(File file) which takes a File parameter (see setDestination(File file) )

So you need to change your code into:

reports {
    xml {
        destination file("$buildDir/outputs/reports/checkstyle_report.xml")
    }
}

All adjustment was done in my quality.gradle. Check config folder for quality.gradle file and change all usage of

destination "$reportsDir/pmd/pmd.xml"

to

destination file("$reportsDir/pmd/pmd.html")