Генерация JBehave отчетов по умолчанию из Gradle без спокойствия - PullRequest
0 голосов
/ 14 апреля 2020

Я пытаюсь сгенерировать отчеты JBehave из сборки gradle. Я могу получить только отчет о gradle по умолчанию, но не JBehave. Мой файл Gradle выглядит примерно так:

task copyStories(type: Copy) {
    from 'src/main/resources' into "${buildDir}/classes/test"
    from 'src/main/stories' into "${buildDir}/classes/test/stories"
}


sourceSets {
    test {
        java {
            srcDir "src/main/java"
        }
        resources {
            srcDir "src/main/resources"
        }
    }
}

/* This is to copy the system properties from gradle available to Junit test classes*/

test {
    systemProperty "metaFilters", System.getProperty("metaFilters", "")
    doFirst {
        copy {
            from(zipTree(jarPath("jbehave-core"))) {
                include "style/*"
            }
            into("build/reports/jbehave/view")

        }
        copy {
            from(zipTree(jarPath("jbehave-site-resources"))) {
                include "js/**/*"
                include "style/**/*"
                include "images/*"
            }
            into("build/reports/jbehave/view")
        }
    }
    systemProperties System.getProperties()
    dependsOn([clean,copyStories])
}

def jarPath(String jarName) {
    configurations.testCompile.find({ it.name.startsWith(jarName) }).absolutePath
}

Я получаю ресурсы в папке jbehave, но не сам отчет. Может кто-нибудь помочь мне с этим?

...