Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Getting error Plugin with id 'net.serenity-bdd.aggregator' not found. #2876

Closed
bachhavdipak opened this issue Jul 29, 2022 · 17 comments
Closed

Comments

@bachhavdipak
Copy link
Contributor

bachhavdipak commented Jul 29, 2022

I am using the below serenity version but while compiling the project getting the Plugin with id 'net.serenity-bdd.aggregator' not found. I am trying to apply plugin: 'net.serenity-bdd.aggregator'. It works fine with the old version 3.2.4

serenityCoreVersion = 3.3.0
serenityGradlePlugin = 3.3.0
@wakaleo
Copy link
Member

wakaleo commented Jul 29, 2022

Is this with Gradle?

@bachhavdipak bachhavdipak reopened this Jul 29, 2022
@bachhavdipak
Copy link
Contributor Author

bachhavdipak commented Jul 29, 2022

Yes I am using Gradle @wakaleo

@wakaleo
Copy link
Member

wakaleo commented Jul 29, 2022

@bachhavdipak
Copy link
Contributor Author

No, I am facing issue with apply plugin: 'net.serenity-bdd.aggregator'

@wakaleo
Copy link
Member

wakaleo commented Jul 29, 2022

Try using the plugin as defined in the link above.

@bachhavdipak
Copy link
Contributor Author

bachhavdipak commented Jul 29, 2022

@wakaleo No, it's not working. Also, index.html is not generating. I have very high hope for the display name generator with the 3.3.0 release but seems like it's not working too.

@wakaleo
Copy link
Member

wakaleo commented Jul 30, 2022

Have a look at https://github.com/serenity-dojo/swaglabs-serenity-cucumber for a working example of a Gradle build. I don't recall anyone proposing a pull request for the display name generator - was there something that led you to believe this would be in the next release?

@souwa
Copy link

souwa commented Aug 1, 2022

hi @bachhavdipak,

No, I am facing issue with apply plugin: 'net.serenity-bdd.aggregator'

please try to apply the serentiy gradle plugin instead. That worked for me:

apply plugin: "net.serenity-bdd.serenity-gradle-plugin"

@bachhavdipak
Copy link
Contributor Author

bachhavdipak commented Aug 4, 2022

@souwa : I have tried that but still getting an empty serenity report and if I compare it to the old version then I have only updated the

  1. serenity version from 3.2.4 to 3.3.0 and
  2. added apply plugin: "net.serenity-bdd.serenity-gradle-plugin" & commented //apply plugin: 'net.serenity-bdd.aggregator'

I am using serenity with Junit 5

image

@wakaleo
Copy link
Member

wakaleo commented Aug 4, 2022

That would mean that your tests are not being executed

@bachhavdipak
Copy link
Contributor Author

bachhavdipak commented Aug 4, 2022

The test is executed @wakaleo and fails due to the ElementNotInteractableException

 13:37:30.788 [ForkJoinPool-1-worker-1] INFO  d.e.u.s.eCommStepDefinitions - Destroy the web driver instance

e comm functional tests > Sample Test case  FAILED
    org.openqa.selenium.ElementNotInteractableException: Timed out after 20 seconds. Element not available
    Build info: version: '4.3.0', revision: 'a4995e2c09*'
    System info: host: 'UKC-DSEV023991', ip: '10.4.12.58', os.name: 'Windows 10', os.arch: 'amd64', os.version: '10.0', java.version: '1.8.0_281'
    Driver info: driver.version: unknown

Report locaton:

1 test completed, 1 failed
There were failing tests. See the report at: file://C:/Dipak/SerenityTest//build/reports/tests/beta-uk/index.html

> Task :aggregate
Generating Serenity Reports
  - Main report: file:///C:/Dipak/SerenityTest/target/serenity/index.html
      - Test Root: null
      - Requirements base directory: null

@wakaleo
Copy link
Member

wakaleo commented Aug 4, 2022

Try starting with one of the starter projects - I don't know what the issue is here.

@bachhavdipak
Copy link
Contributor Author

In my case, I need to delete the target/serenity folder from my local disk. Now its working fine Thanks @wakaleo

@aniket00197
Copy link

aniket00197 commented Sep 30, 2022

@wakaleo I am also facing the same issue which @bachhavdipak mentioned above. I tried to delete target/serenity but nothing works for me.

  • Test Root: starter
    • Requirements base directory: null

@wakaleo
Copy link
Member

wakaleo commented Sep 30, 2022

It's a known Gradle issue - I don't have a solution at this stage, but PRs are more than welcome - it's something to do with the way Gradle defines root directories.

@HanselCream
Copy link

Hello I am having an Issue with gradle. I am using JDK 18 and Gradle 7.6

This is showing an error

  • Exception is:
    org.gradle.api.plugins.UnknownPluginException: Plugin [id: 'net.serenity-bdd.serenity-gradle-plugin', version: '7.6'] was not found in any of the following sources:
  • Gradle Core Plugins (plugin is not in 'org.gradle' namespace)
  • Plugin Repositories (could not resolve plugin artifact 'net.serenity-bdd.serenity-gradle-plugin:net.serenity-bdd.serenity-gradle-plugin.gradle.plugin:7.6')

This is my build.gradle

plugins {
    id "net.serenity-bdd.serenity-gradle-plugin" version "7.6"
    id 'java'
    id 'eclipse'
    id 'idea'
}

defaultTasks 'clean','test','aggregate'

repositories {
    mavenCentral()
}

sourceCompatibility = 1.8
targetCompatibility = 1.8

ext {
    slf4jVersion = '1.7.7'
    serenityCoreVersion = '3.5.1'
    junitVersion = '5.8.2'
    assertJVersion = '3.22.0'
    logbackVersion = '1.2.10'
}

dependencies {
    testImplementation "net.serenity-bdd:serenity-core:7.6",
            "net.serenity-bdd:serenity-junit5:7.6",
            "net.serenity-bdd:serenity-screenplay:7.6",
            "net.serenity-bdd:serenity-ensure:7.6",
            "net.serenity-bdd:serenity-screenplay-webdriver:7.6",
            "org.junit.jupiter:junit-jupiter-api:5.8.2",
            "org.assertj:assertj-core:3.22.0",
            "ch.qos.logback:logback-classic:1.2.10"
    testRuntimeOnly "org.junit.jupiter:junit-jupiter-engine:5.8.2"
}

test {
    useJUnitPlatform()
    testLogging.showStandardStreams = true
    systemProperties System.getProperties()
}

gradle.startParameter.continueOnFailure = true

test.finalizedBy(aggregate)

What is wrong? I am using Intellij

@ferlot70
Copy link

ferlot70 commented Jul 5, 2023

@HanselCream got the same failure, but the problem was the plugin version. I fixed it by updating to the latest https://plugins.gradle.org/plugin/net.serenity-bdd.serenity-gradle-plugin

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants