depends on nonexistent group "homePage" error

classic Classic list List threaded Threaded
9 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

depends on nonexistent group "homePage" error

Settaluri Karthik Sriharsha
Say for example I've a UntilLogin, PostLogin classes containing the following piece of code : 

class UntilLogin() {


@Test(groups=preSetup1)
public void test_setup1() {
button
.click() // some action 1
}


@Test(dependsOnGroups=preSetup1, groups=preSetup2)
public void test_setup2() {
button
.click()  // some action 2
}


@Test(dependsOnGroups=preSetup2, groups=preSetup3)
public void test_setup3() {
button
.click() // some action 3
}


@Test(dependsOnGroups=preSetup3, groups=preSetup4)
public void test_setup4() {
// perform login
}


@Test(dependsOnGroups=preSetup4, groups=preSetup5)
public void test_setup5() {
// wait for splash screen to appear and click
}


@Test(dependsOnGroups=preSetup5, groups=homePage)
public void test_homePage() {
// wait for the elements to appears
}






class PostLogin() {


@Test(dependOnGroups=homePage, groups=postgroup)
public void test_postLogin() {
//
}


When i try to do maven install on this - I get the following error "of Nonexistent Group" 

Enter code he[INFO] Results:

[INFO] 

[INFO] Tests run: 0, Failures: 0, Errors: 0, Skipped: 0

[INFO] 

[INFO] ------------------------------------------------------------------------

[INFO] BUILD FAILURE

[INFO] ------------------------------------------------------------------------

[INFO] Total time: 3.564 s

[INFO] Finished at: 2017-05-25T01:57:42+05:30

[INFO] Final Memory: 25M/278M

[INFO] ------------------------------------------------------------------------

[ERROR] Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.20:test (default-test) on project android: There are test failures.

[ERROR] 

[ERROR] Please refer to /Users/ssrihar/Documents/workspace/android/testapp/relay/android/target/surefire-reports for the individual test results.

[ERROR] Please refer to dump files (if any exist) [date]-jvmRun[N].dump, [date].dumpstream and [date]-jvmRun[N].dumpstream.

[ERROR] There was an error in the forked process

[ERROR] 

[ERROR] DependencyMap::Method "ListsTest.test_listsHomePage()[pri:0, instance:com.sears.relay.android.ListsTest@5a61f5df]" depends on nonexistent group "HomePageGroup"

[ERROR] org.apache.maven.surefire.booter.SurefireBooterForkException: There was an error in the forked process

[ERROR] 

[ERROR] DependencyMap::Method "PostLogin.test_postLogin()[pri:0. PostLogin@5a61f5df]" depends on nonexistent group "homePage"

[ERROR] at org.apache.maven.plugin.surefire.booterclient.ForkStarter.fork(ForkStarter.java:665)

[ERROR] at org.apache.maven.plugin.surefire.booterclient.ForkStarter.fork(ForkStarter.java:533)

[ERROR] at org.apache.maven.plugin.surefire.booterclient.ForkStarter.run(ForkStarter.java:279)

[ERROR] at org.apache.maven.plugin.surefire.booterclient.ForkStarter.run(ForkStarter.java:243)

[ERROR] at org.apache.maven.plugin.surefire.AbstractSurefireMojo.executeProvider(AbstractSurefireMojo.java:1077)

[ERROR] at org.apache.maven.plugin.surefire.AbstractSurefireMojo.executeAfterPreconditionsChecked(AbstractSurefireMojo.java:907)

[ERROR] at org.apache.maven.plugin.surefire.AbstractSurefireMojo.execute(AbstractSurefireMojo.java:785)

[ERROR] at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:134)

[ERROR] at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:207)

[ERROR] at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:153)

[ERROR] at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:145)

[ERROR] at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:116)

[ERROR] at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:80)

[ERROR] at org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder.build(SingleThreadedBuilder.java:51)

[ERROR] at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:128)

[ERROR] at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:307)

[ERROR] at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:193)

[ERROR] at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:106)

[ERROR] at org.apache.maven.cli.MavenCli.execute(MavenCli.java:863)

[ERROR] at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:288)

[ERROR] at org.apache.maven.cli.MavenCli.main(MavenCli.java:199)

[ERROR] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

[ERROR] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)

[ERROR] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)

[ERROR] at java.lang.reflect.Method.invoke(Method.java:498)

[ERROR] at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:289)

[ERROR] at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:229)

[ERROR] at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:415)

[ERROR] at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:356)

[ERROR] -> [Help 1]re...

Kindly help me out in resolving this issue.


--
You received this message because you are subscribed to the Google Groups "testng-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at https://groups.google.com/group/testng-users.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: depends on nonexistent group "homePage" error

Krishnan Mahadevan

Please show us how does your suite xml look like. Hard to say without seeing it's contents.


On Thu, May 25, 2017, 08:02 Settaluri Karthik Sriharsha <[hidden email]> wrote:
Say for example I've a UntilLogin, PostLogin classes containing the following piece of code : 

class UntilLogin() {


@Test(groups=preSetup1)
public void test_setup1() {
button
.click() // some action 1
}


@Test(dependsOnGroups=preSetup1, groups=preSetup2)
public void test_setup2() {
button
.click()  // some action 2
}


@Test(dependsOnGroups=preSetup2, groups=preSetup3)
public void test_setup3() {
button
.click() // some action 3
}


@Test(dependsOnGroups=preSetup3, groups=preSetup4)
public void test_setup4() {
// perform login
}


@Test(dependsOnGroups=preSetup4, groups=preSetup5)
public void test_setup5() {
// wait for splash screen to appear and click
}


@Test(dependsOnGroups=preSetup5, groups=homePage)
public void test_homePage() {
// wait for the elements to appears
}






class PostLogin() {


@Test(dependOnGroups=homePage, groups=postgroup)
public void test_postLogin() {
//
}


When i try to do maven install on this - I get the following error "of Nonexistent Group" 

Enter code he[INFO] Results:

[INFO] 

[INFO] Tests run: 0, Failures: 0, Errors: 0, Skipped: 0

[INFO] 

[INFO] ------------------------------------------------------------------------

[INFO] BUILD FAILURE

[INFO] ------------------------------------------------------------------------

[INFO] Total time: 3.564 s

[INFO] Finished at: 2017-05-25T01:57:42+05:30

[INFO] Final Memory: 25M/278M

[INFO] ------------------------------------------------------------------------

[ERROR] Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.20:test (default-test) on project android: There are test failures.

[ERROR] 

[ERROR] Please refer to /Users/ssrihar/Documents/workspace/android/testapp/relay/android/target/surefire-reports for the individual test results.

[ERROR] Please refer to dump files (if any exist) [date]-jvmRun[N].dump, [date].dumpstream and [date]-jvmRun[N].dumpstream.

[ERROR] There was an error in the forked process

[ERROR] 

[ERROR] DependencyMap::Method "ListsTest.test_listsHomePage()[pri:0, instance:com.sears.relay.android.ListsTest@5a61f5df]" depends on nonexistent group "HomePageGroup"

[ERROR] org.apache.maven.surefire.booter.SurefireBooterForkException: There was an error in the forked process

[ERROR] 

[ERROR] DependencyMap::Method "PostLogin.test_postLogin()[pri:0. PostLogin@5a61f5df]" depends on nonexistent group "homePage"

[ERROR] at org.apache.maven.plugin.surefire.booterclient.ForkStarter.fork(ForkStarter.java:665)

[ERROR] at org.apache.maven.plugin.surefire.booterclient.ForkStarter.fork(ForkStarter.java:533)

[ERROR] at org.apache.maven.plugin.surefire.booterclient.ForkStarter.run(ForkStarter.java:279)

[ERROR] at org.apache.maven.plugin.surefire.booterclient.ForkStarter.run(ForkStarter.java:243)

[ERROR] at org.apache.maven.plugin.surefire.AbstractSurefireMojo.executeProvider(AbstractSurefireMojo.java:1077)

[ERROR] at org.apache.maven.plugin.surefire.AbstractSurefireMojo.executeAfterPreconditionsChecked(AbstractSurefireMojo.java:907)

[ERROR] at org.apache.maven.plugin.surefire.AbstractSurefireMojo.execute(AbstractSurefireMojo.java:785)

[ERROR] at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:134)

[ERROR] at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:207)

[ERROR] at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:153)

[ERROR] at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:145)

[ERROR] at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:116)

[ERROR] at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:80)

[ERROR] at org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder.build(SingleThreadedBuilder.java:51)

[ERROR] at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:128)

[ERROR] at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:307)

[ERROR] at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:193)

[ERROR] at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:106)

[ERROR] at org.apache.maven.cli.MavenCli.execute(MavenCli.java:863)

[ERROR] at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:288)

[ERROR] at org.apache.maven.cli.MavenCli.main(MavenCli.java:199)

[ERROR] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

[ERROR] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)

[ERROR] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)

[ERROR] at java.lang.reflect.Method.invoke(Method.java:498)

[ERROR] at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:289)

[ERROR] at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:229)

[ERROR] at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:415)

[ERROR] at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:356)

[ERROR] -> [Help 1]re...

Kindly help me out in resolving this issue.


--
You received this message because you are subscribed to the Google Groups "testng-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at https://groups.google.com/group/testng-users.
For more options, visit https://groups.google.com/d/optout.
--

Thanks & Regards
Krishnan Mahadevan

"All the desirable things in life are either illegal, expensive, fattening or in love with someone else!"
My Scribblings @ http://wakened-cognition.blogspot.com/

My Technical Scribbings @ http://rationaleemotions.wordpress.com/

--
You received this message because you are subscribed to the Google Groups "testng-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at https://groups.google.com/group/testng-users.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: depends on nonexistent group "homePage" error

Settaluri Karthik Sriharsha







<?xml version="1.0" encoding="UTF-8"?>


<!DOCTYPE suite SYSTEM "http://testng.org/testng-1.0.dtd">


<suite name="Suite" parallel="none">


  <test name="Login_ClickLists_SelectListSelectItemAndOrderTest">

    <classes>


       <class name="com.test.myapp.android.UntilLogin">


        <methods>


                <include name="testSetup1" />


                <include name="testSetup2" />


                <include name="testSetup3" />


                <include name="testSetup4" />


                <include name="testSetup5" />


                <include name="testHomePage" />


        </methods>


       </class>


       <class name="com.test.myapp.android.PostLogin">


       <methods>


                <include name="test_postLogin" />


        </methods>


       </class>


    </classes>


  </test> <!-- Test -->


</suite> <!-- Suite -->



This is how my sample test suite looks. Please let me know if I'm correct.


On Thursday, May 25, 2017 at 11:40:59 AM UTC+5:30, Krishnan wrote:

Please show us how does your suite xml look like. Hard to say without seeing it's contents.


On Thu, May 25, 2017, 08:02 Settaluri Karthik Sriharsha <<a href="javascript:" target="_blank" gdf-obfuscated-mailto="5EypF2x2BgAJ" rel="nofollow" onmousedown="this.href=&#39;javascript:&#39;;return true;" onclick="this.href=&#39;javascript:&#39;;return true;">sksh...@...> wrote:
Say for example I've a UntilLogin, PostLogin classes containing the following piece of code : 

class UntilLogin() {


@Test(groups=preSetup1)
public void test_setup1() {
button
.click() // some action 1
}


@Test(dependsOnGroups=preSetup1, groups=preSetup2)
public void test_setup2() {
button
.click()  // some action 2
}


@Test(dependsOnGroups=preSetup2, groups=preSetup3)
public void test_setup3() {
button
.click() // some action 3
}


@Test(dependsOnGroups=preSetup3, groups=preSetup4)
public void test_setup4() {
// perform login
}


@Test(dependsOnGroups=preSetup4, groups=preSetup5)
public void test_setup5() {
// wait for splash screen to appear and click
}


@Test(dependsOnGroups=preSetup5, groups=homePage)
public void test_homePage() {
// wait for the elements to appears
}






class PostLogin() {


@Test(dependOnGroups=homePage, groups=postgroup)
public void test_postLogin() {
//
}


When i try to do maven install on this - I get the following error "of Nonexistent Group" 

Enter code he[INFO] Results:

[INFO] 

[INFO] Tests run: 0, Failures: 0, Errors: 0, Skipped: 0

[INFO] 

[INFO] ------------------------------------------------------------------------

[INFO] BUILD FAILURE

[INFO] ------------------------------------------------------------------------

[INFO] Total time: 3.564 s

[INFO] Finished at: 2017-05-25T01:57:42+05:30

[INFO] Final Memory: 25M/278M

[INFO] ------------------------------------------------------------------------

[ERROR] Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.20:test (default-test) on project android: There are test failures.

[ERROR] 

[ERROR] Please refer to /Users/ssrihar/Documents/workspace/android/testapp/relay/android/target/surefire-reports for the individual test results.

[ERROR] Please refer to dump files (if any exist) [date]-jvmRun[N].dump, [date].dumpstream and [date]-jvmRun[N].dumpstream.

[ERROR] There was an error in the forked process

[ERROR] 

[ERROR] DependencyMap::Method "ListsTest.test_listsHomePage()[pri:0, instance:com.sears.relay.android.ListsTest@5a61f5df]" depends on nonexistent group "HomePageGroup"

[ERROR] org.apache.maven.surefire.booter.SurefireBooterForkException: There was an error in the forked process

[ERROR] 

[ERROR] DependencyMap::Method "PostLogin.test_postLogin()[pri:0. PostLogin@5a61f5df]" depends on nonexistent group "homePage"

[ERROR] at org.apache.maven.plugin.surefire.booterclient.ForkStarter.fork(ForkStarter.java:665)

[ERROR] at org.apache.maven.plugin.surefire.booterclient.ForkStarter.fork(ForkStarter.java:533)

[ERROR] at org.apache.maven.plugin.surefire.booterclient.ForkStarter.run(ForkStarter.java:279)

[ERROR] at org.apache.maven.plugin.surefire.booterclient.ForkStarter.run(ForkStarter.java:243)

[ERROR] at org.apache.maven.plugin.surefire.AbstractSurefireMojo.executeProvider(AbstractSurefireMojo.java:1077)

[ERROR] at org.apache.maven.plugin.surefire.AbstractSurefireMojo.executeAfterPreconditionsChecked(AbstractSurefireMojo.java:907)

[ERROR] at org.apache.maven.plugin.surefire.AbstractSurefireMojo.execute(AbstractSurefireMojo.java:785)

[ERROR] at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:134)

[ERROR] at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:207)

[ERROR] at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:153)

[ERROR] at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:145)

[ERROR] at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:116)

[ERROR] at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:80)

[ERROR] at org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder.build(SingleThreadedBuilder.java:51)

[ERROR] at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:128)

[ERROR] at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:307)

[ERROR] at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:193)

[ERROR] at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:106)

[ERROR] at org.apache.maven.cli.MavenCli.execute(MavenCli.java:863)

[ERROR] at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:288)

[ERROR] at org.apache.maven.cli.MavenCli.main(MavenCli.java:199)

[ERROR] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

[ERROR] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)

[ERROR] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)

[ERROR] at java.lang.reflect.Method.invoke(Method.java:498)

[ERROR] at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:289)

[ERROR] at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:229)

[ERROR] at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:415)

[ERROR] at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:356)

[ERROR] -> [Help 1]re...

Kindly help me out in resolving this issue.


--
You received this message because you are subscribed to the Google Groups "testng-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to <a href="javascript:" target="_blank" gdf-obfuscated-mailto="5EypF2x2BgAJ" rel="nofollow" onmousedown="this.href=&#39;javascript:&#39;;return true;" onclick="this.href=&#39;javascript:&#39;;return true;">testng-users...@googlegroups.com.
To post to this group, send email to <a href="javascript:" target="_blank" gdf-obfuscated-mailto="5EypF2x2BgAJ" rel="nofollow" onmousedown="this.href=&#39;javascript:&#39;;return true;" onclick="this.href=&#39;javascript:&#39;;return true;">testng...@....
Visit this group at <a href="https://groups.google.com/group/testng-users" target="_blank" rel="nofollow" onmousedown="this.href=&#39;https://groups.google.com/group/testng-users&#39;;return true;" onclick="this.href=&#39;https://groups.google.com/group/testng-users&#39;;return true;">https://groups.google.com/group/testng-users.
For more options, visit <a href="https://groups.google.com/d/optout" target="_blank" rel="nofollow" onmousedown="this.href=&#39;https://groups.google.com/d/optout&#39;;return true;" onclick="this.href=&#39;https://groups.google.com/d/optout&#39;;return true;">https://groups.google.com/d/optout.
--

Thanks & Regards
Krishnan Mahadevan

"All the desirable things in life are either illegal, expensive, fattening or in love with someone else!"
My Scribblings @ <a href="http://wakened-cognition.blogspot.com/" target="_blank" rel="nofollow" onmousedown="this.href=&#39;http://www.google.com/url?q\x3dhttp%3A%2F%2Fwakened-cognition.blogspot.com%2F\x26sa\x3dD\x26sntz\x3d1\x26usg\x3dAFQjCNHzOdYJCASIDF_28vQtkp9gnKAYSQ&#39;;return true;" onclick="this.href=&#39;http://www.google.com/url?q\x3dhttp%3A%2F%2Fwakened-cognition.blogspot.com%2F\x26sa\x3dD\x26sntz\x3d1\x26usg\x3dAFQjCNHzOdYJCASIDF_28vQtkp9gnKAYSQ&#39;;return true;">http://wakened-cognition.blogspot.com/

My Technical Scribbings @ <a href="http://rationaleemotions.wordpress.com/" target="_blank" rel="nofollow" onmousedown="this.href=&#39;http://www.google.com/url?q\x3dhttp%3A%2F%2Frationaleemotions.wordpress.com%2F\x26sa\x3dD\x26sntz\x3d1\x26usg\x3dAFQjCNEcBOKyRn0lpL8LDbBuyAlKdwgXwQ&#39;;return true;" onclick="this.href=&#39;http://www.google.com/url?q\x3dhttp%3A%2F%2Frationaleemotions.wordpress.com%2F\x26sa\x3dD\x26sntz\x3d1\x26usg\x3dAFQjCNEcBOKyRn0lpL8LDbBuyAlKdwgXwQ&#39;;return true;">http://rationaleemotions.wordpress.com/

--
You received this message because you are subscribed to the Google Groups "testng-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at https://groups.google.com/group/testng-users.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: depends on nonexistent group "homePage" error

Krishnan Mahadevan

Please double check if you have mentioned the method names properly for com.test.myapp.android.UntilLogin

Based on what you shared as the xml contents all the method names in this class are missing an "_" (underscore )


On Thu, May 25, 2017, 13:53 Settaluri Karthik Sriharsha <[hidden email]> wrote:




--

Thanks & Regards
Krishnan Mahadevan

"All the desirable things in life are either illegal, expensive, fattening or in love with someone else!"
My Scribblings @ http://wakened-cognition.blogspot.com/

My Technical Scribbings @ http://rationaleemotions.wordpress.com/

--
You received this message because you are subscribed to the Google Groups "testng-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at https://groups.google.com/group/testng-users.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: depends on nonexistent group "homePage" error

Settaluri Karthik Sriharsha
In reply to this post by Settaluri Karthik Sriharsha
Please note that I've changed the methods and class names and thus the below

[ERROR] DependencyMap::Method "ListsTest.test_listsHomePage()[pri:0, instance:com.sears.relay.android.ListsTest@5a61f5df]" depends on nonexistent group "HomePageGroup"


maps to 

[ERROR] DependencyMap::Method "PostLogin.test_postLogin()[pri:0, instance:com.sears.relay.android.ListsTest@5a61f5df]" depends on nonexistent group "homePage"




On Thursday, May 25, 2017 at 1:53:00 PM UTC+5:30, Settaluri Karthik Sriharsha wrote:







<?xml version="1.0" encoding="UTF-8"?>


<!DOCTYPE suite SYSTEM "<a href="http://testng.org/testng-1.0.dtd" target="_blank" rel="nofollow" onmousedown="this.href=&#39;http://www.google.com/url?q\x3dhttp%3A%2F%2Ftestng.org%2Ftestng-1.0.dtd\x26sa\x3dD\x26sntz\x3d1\x26usg\x3dAFQjCNFHihXzQ1YlwcxcDehnw97TuniFLA&#39;;return true;" onclick="this.href=&#39;http://www.google.com/url?q\x3dhttp%3A%2F%2Ftestng.org%2Ftestng-1.0.dtd\x26sa\x3dD\x26sntz\x3d1\x26usg\x3dAFQjCNFHihXzQ1YlwcxcDehnw97TuniFLA&#39;;return true;">http://testng.org/testng-1.0.dtd">


<suite name="Suite" parallel="none">


  <test name="Login_ClickLists_SelectListSelectItemAndOrderTest">

    <classes>


       <class name="com.test.myapp.android.UntilLogin">


        <methods>


                <include name="testSetup1" />


                <include name="testSetup2" />


                <include name="testSetup3" />


                <include name="testSetup4" />


                <include name="testSetup5" />


                <include name="testHomePage" />


        </methods>


       </class>


       <class name="com.test.myapp.android.PostLogin">


       <methods>


                <include name="test_postLogin" />


        </methods>


       </class>


    </classes>


  </test> <!-- Test -->


</suite> <!-- Suite -->



This is how my sample test suite looks. Please let me know if I'm correct.


On Thursday, May 25, 2017 at 11:40:59 AM UTC+5:30, Krishnan wrote:

Please show us how does your suite xml look like. Hard to say without seeing it's contents.


On Thu, May 25, 2017, 08:02 Settaluri Karthik Sriharsha <[hidden email]> wrote:
Say for example I've a UntilLogin, PostLogin classes containing the following piece of code : 

class UntilLogin() {


@Test(groups=preSetup1)
public void test_setup1() {
button
.click() // some action 1
}


@Test(dependsOnGroups=preSetup1, groups=preSetup2)
public void test_setup2() {
button
.click()  // some action 2
}


@Test(dependsOnGroups=preSetup2, groups=preSetup3)
public void test_setup3() {
button
.click() // some action 3
}


@Test(dependsOnGroups=preSetup3, groups=preSetup4)
public void test_setup4() {
// perform login
}


@Test(dependsOnGroups=preSetup4, groups=preSetup5)
public void test_setup5() {
// wait for splash screen to appear and click
}


@Test(dependsOnGroups=preSetup5, groups=homePage)
public void test_homePage() {
// wait for the elements to appears
}






class PostLogin() {


@Test(dependOnGroups=homePage, groups=postgroup)
public void test_postLogin() {
//
}


When i try to do maven install on this - I get the following error "of Nonexistent Group" 

Enter code he[INFO] Results:

[INFO] 

[INFO] Tests run: 0, Failures: 0, Errors: 0, Skipped: 0

[INFO] 

[INFO] ------------------------------------------------------------------------

[INFO] BUILD FAILURE

[INFO] ------------------------------------------------------------------------

[INFO] Total time: 3.564 s

[INFO] Finished at: 2017-05-25T01:57:42+05:30

[INFO] Final Memory: 25M/278M

[INFO] ------------------------------------------------------------------------

[ERROR] Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.20:test (default-test) on project android: There are test failures.

[ERROR] 

[ERROR] Please refer to /Users/ssrihar/Documents/workspace/android/testapp/relay/android/target/surefire-reports for the individual test results.

[ERROR] Please refer to dump files (if any exist) [date]-jvmRun[N].dump, [date].dumpstream and [date]-jvmRun[N].dumpstream.

[ERROR] There was an error in the forked process

[ERROR] 

[ERROR] DependencyMap::Method "ListsTest.test_listsHomePage()[pri:0, instance:com.sears.relay.android.ListsTest@5a61f5df]" depends on nonexistent group "HomePageGroup"

[ERROR] org.apache.maven.surefire.booter.SurefireBooterForkException: There was an error in the forked process

[ERROR] 

[ERROR] DependencyMap::Method "PostLogin.test_postLogin()[pri:0. PostLogin@5a61f5df]" depends on nonexistent group "homePage"

[ERROR] at org.apache.maven.plugin.surefire.booterclient.ForkStarter.fork(ForkStarter.java:665)

[ERROR] at org.apache.maven.plugin.surefire.booterclient.ForkStarter.fork(ForkStarter.java:533)

[ERROR] at org.apache.maven.plugin.surefire.booterclient.ForkStarter.run(ForkStarter.java:279)

[ERROR] at org.apache.maven.plugin.surefire.booterclient.ForkStarter.run(ForkStarter.java:243)

[ERROR] at org.apache.maven.plugin.surefire.AbstractSurefireMojo.executeProvider(AbstractSurefireMojo.java:1077)

[ERROR] at org.apache.maven.plugin.surefire.AbstractSurefireMojo.executeAfterPreconditionsChecked(AbstractSurefireMojo.java:907)

[ERROR] at org.apache.maven.plugin.surefire.AbstractSurefireMojo.execute(AbstractSurefireMojo.java:785)

[ERROR] at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:134)

[ERROR] at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:207)

[ERROR] at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:153)

[ERROR] at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:145)

[ERROR] at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:116)

[ERROR] at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:80)

[ERROR] at org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder.build(SingleThreadedBuilder.java:51)

[ERROR] at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:128)

[ERROR] at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:307)

[ERROR] at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:193)

[ERROR] at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:106)

[ERROR] at org.apache.maven.cli.MavenCli.execute(MavenCli.java:863)

[ERROR] at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:288)

[ERROR] at org.apache.maven.cli.MavenCli.main(MavenCli.java:199)

[ERROR] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

[ERROR] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)

[ERROR] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)

[ERROR] at java.lang.reflect.Method.invoke(Method.java:498)

[ERROR] at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:289)

[ERROR] at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:229)

[ERROR] at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:415)

[ERROR] at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:356)

[ERROR] -> [Help 1]re...

Kindly help me out in resolving this issue.


--
You received this message because you are subscribed to the Google Groups "testng-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to testng-users...@googlegroups.com.
To post to this group, send email to [hidden email].
Visit this group at <a href="https://groups.google.com/group/testng-users" rel="nofollow" target="_blank" onmousedown="this.href=&#39;https://groups.google.com/group/testng-users&#39;;return true;" onclick="this.href=&#39;https://groups.google.com/group/testng-users&#39;;return true;">https://groups.google.com/group/testng-users.
For more options, visit <a href="https://groups.google.com/d/optout" rel="nofollow" target="_blank" onmousedown="this.href=&#39;https://groups.google.com/d/optout&#39;;return true;" onclick="this.href=&#39;https://groups.google.com/d/optout&#39;;return true;">https://groups.google.com/d/optout.
--

Thanks & Regards
Krishnan Mahadevan

"All the desirable things in life are either illegal, expensive, fattening or in love with someone else!"
My Scribblings @ <a href="http://wakened-cognition.blogspot.com/" rel="nofollow" target="_blank" onmousedown="this.href=&#39;http://www.google.com/url?q\x3dhttp%3A%2F%2Fwakened-cognition.blogspot.com%2F\x26sa\x3dD\x26sntz\x3d1\x26usg\x3dAFQjCNHzOdYJCASIDF_28vQtkp9gnKAYSQ&#39;;return true;" onclick="this.href=&#39;http://www.google.com/url?q\x3dhttp%3A%2F%2Fwakened-cognition.blogspot.com%2F\x26sa\x3dD\x26sntz\x3d1\x26usg\x3dAFQjCNHzOdYJCASIDF_28vQtkp9gnKAYSQ&#39;;return true;">http://wakened-cognition.blogspot.com/

My Technical Scribbings @ <a href="http://rationaleemotions.wordpress.com/" rel="nofollow" target="_blank" onmousedown="this.href=&#39;http://www.google.com/url?q\x3dhttp%3A%2F%2Frationaleemotions.wordpress.com%2F\x26sa\x3dD\x26sntz\x3d1\x26usg\x3dAFQjCNEcBOKyRn0lpL8LDbBuyAlKdwgXwQ&#39;;return true;" onclick="this.href=&#39;http://www.google.com/url?q\x3dhttp%3A%2F%2Frationaleemotions.wordpress.com%2F\x26sa\x3dD\x26sntz\x3d1\x26usg\x3dAFQjCNEcBOKyRn0lpL8LDbBuyAlKdwgXwQ&#39;;return true;">http://rationaleemotions.wordpress.com/

--
You received this message because you are subscribed to the Google Groups "testng-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at https://groups.google.com/group/testng-users.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: depends on nonexistent group "homePage" error

Settaluri Karthik Sriharsha
Kindly let me know how to include group dependency if required instead of methods. 

Or groups and methods dependency if required.


On Thursday, May 25, 2017 at 2:00:15 PM UTC+5:30, Settaluri Karthik Sriharsha wrote:
Please note that I've changed the methods and class names and thus the below

[ERROR] DependencyMap::Method "ListsTest.test_listsHomePage()[pri:0, instance:com.sears.relay.android.ListsTest@5a61f5df]" depends on nonexistent group "HomePageGroup"


maps to 

[ERROR] DependencyMap::Method "PostLogin.test_postLogin()[pri:0, instance:com.sears.relay.android.ListsTest@5a61f5df]" depends on nonexistent group "homePage"




On Thursday, May 25, 2017 at 1:53:00 PM UTC+5:30, Settaluri Karthik Sriharsha wrote:







<?xml version="1.0" encoding="UTF-8"?>


<!DOCTYPE suite SYSTEM "<a href="http://testng.org/testng-1.0.dtd" rel="nofollow" target="_blank" onmousedown="this.href=&#39;http://www.google.com/url?q\x3dhttp%3A%2F%2Ftestng.org%2Ftestng-1.0.dtd\x26sa\x3dD\x26sntz\x3d1\x26usg\x3dAFQjCNFHihXzQ1YlwcxcDehnw97TuniFLA&#39;;return true;" onclick="this.href=&#39;http://www.google.com/url?q\x3dhttp%3A%2F%2Ftestng.org%2Ftestng-1.0.dtd\x26sa\x3dD\x26sntz\x3d1\x26usg\x3dAFQjCNFHihXzQ1YlwcxcDehnw97TuniFLA&#39;;return true;">http://testng.org/testng-1.0.dtd">


<suite name="Suite" parallel="none">


  <test name="Login_ClickLists_SelectListSelectItemAndOrderTest">

    <classes>


       <class name="com.test.myapp.android.UntilLogin">


        <methods>


                <include name="testSetup1" />


                <include name="testSetup2" />


                <include name="testSetup3" />


                <include name="testSetup4" />


                <include name="testSetup5" />


                <include name="testHomePage" />


        </methods>


       </class>


       <class name="com.test.myapp.android.PostLogin">


       <methods>


                <include name="test_postLogin" />


        </methods>


       </class>


    </classes>


  </test> <!-- Test -->


</suite> <!-- Suite -->



This is how my sample test suite looks. Please let me know if I'm correct.


On Thursday, May 25, 2017 at 11:40:59 AM UTC+5:30, Krishnan wrote:

Please show us how does your suite xml look like. Hard to say without seeing it's contents.


On Thu, May 25, 2017, 08:02 Settaluri Karthik Sriharsha <[hidden email]> wrote:
Say for example I've a UntilLogin, PostLogin classes containing the following piece of code : 

class UntilLogin() {


@Test(groups=preSetup1)
public void test_setup1() {
button
.click() // some action 1
}


@Test(dependsOnGroups=preSetup1, groups=preSetup2)
public void test_setup2() {
button
.click()  // some action 2
}


@Test(dependsOnGroups=preSetup2, groups=preSetup3)
public void test_setup3() {
button
.click() // some action 3
}


@Test(dependsOnGroups=preSetup3, groups=preSetup4)
public void test_setup4() {
// perform login
}


@Test(dependsOnGroups=preSetup4, groups=preSetup5)
public void test_setup5() {
// wait for splash screen to appear and click
}


@Test(dependsOnGroups=preSetup5, groups=homePage)
public void test_homePage() {
// wait for the elements to appears
}






class PostLogin() {


@Test(dependOnGroups=homePage, groups=postgroup)
public void test_postLogin() {
//
}


When i try to do maven install on this - I get the following error "of Nonexistent Group" 

Enter code he[INFO] Results:

[INFO] 

[INFO] Tests run: 0, Failures: 0, Errors: 0, Skipped: 0

[INFO] 

[INFO] ------------------------------------------------------------------------

[INFO] BUILD FAILURE

[INFO] ------------------------------------------------------------------------

[INFO] Total time: 3.564 s

[INFO] Finished at: 2017-05-25T01:57:42+05:30

[INFO] Final Memory: 25M/278M

[INFO] ------------------------------------------------------------------------

[ERROR] Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.20:test (default-test) on project android: There are test failures.

[ERROR] 

[ERROR] Please refer to /Users/ssrihar/Documents/workspace/android/testapp/relay/android/target/surefire-reports for the individual test results.

[ERROR] Please refer to dump files (if any exist) [date]-jvmRun[N].dump, [date].dumpstream and [date]-jvmRun[N].dumpstream.

[ERROR] There was an error in the forked process

[ERROR] 

[ERROR] DependencyMap::Method "ListsTest.test_listsHomePage()[pri:0, instance:com.sears.relay.android.ListsTest@5a61f5df]" depends on nonexistent group "HomePageGroup"

[ERROR] org.apache.maven.surefire.booter.SurefireBooterForkException: There was an error in the forked process

[ERROR] 

[ERROR] DependencyMap::Method "PostLogin.test_postLogin()[pri:0. PostLogin@5a61f5df]" depends on nonexistent group "homePage"

[ERROR] at org.apache.maven.plugin.surefire.booterclient.ForkStarter.fork(ForkStarter.java:665)

[ERROR] at org.apache.maven.plugin.surefire.booterclient.ForkStarter.fork(ForkStarter.java:533)

[ERROR] at org.apache.maven.plugin.surefire.booterclient.ForkStarter.run(ForkStarter.java:279)

[ERROR] at org.apache.maven.plugin.surefire.booterclient.ForkStarter.run(ForkStarter.java:243)

[ERROR] at org.apache.maven.plugin.surefire.AbstractSurefireMojo.executeProvider(AbstractSurefireMojo.java:1077)

[ERROR] at org.apache.maven.plugin.surefire.AbstractSurefireMojo.executeAfterPreconditionsChecked(AbstractSurefireMojo.java:907)

[ERROR] at org.apache.maven.plugin.surefire.AbstractSurefireMojo.execute(AbstractSurefireMojo.java:785)

[ERROR] at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:134)

[ERROR] at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:207)

[ERROR] at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:153)

[ERROR] at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:145)

[ERROR] at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:116)

[ERROR] at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:80)

[ERROR] at org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder.build(SingleThreadedBuilder.java:51)

[ERROR] at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:128)

[ERROR] at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:307)

[ERROR] at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:193)

[ERROR] at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:106)

[ERROR] at org.apache.maven.cli.MavenCli.execute(MavenCli.java:863)

[ERROR] at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:288)

[ERROR] at org.apache.maven.cli.MavenCli.main(MavenCli.java:199)

[ERROR] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

[ERROR] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)

[ERROR] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)

[ERROR] at java.lang.reflect.Method.invoke(Method.java:498)

[ERROR] at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:289)

[ERROR] at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:229)

[ERROR] at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:415)

[ERROR] at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:356)

[ERROR] -> [Help 1]re...

Kindly help me out in resolving this issue.


--
You received this message because you are subscribed to the Google Groups "testng-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to testng-users...@googlegroups.com.
To post to this group, send email to [hidden email].
Visit this group at <a href="https://groups.google.com/group/testng-users" rel="nofollow" target="_blank" onmousedown="this.href=&#39;https://groups.google.com/group/testng-users&#39;;return true;" onclick="this.href=&#39;https://groups.google.com/group/testng-users&#39;;return true;">https://groups.google.com/group/testng-users.
For more options, visit <a href="https://groups.google.com/d/optout" rel="nofollow" target="_blank" onmousedown="this.href=&#39;https://groups.google.com/d/optout&#39;;return true;" onclick="this.href=&#39;https://groups.google.com/d/optout&#39;;return true;">https://groups.google.com/d/optout.
--

Thanks & Regards
Krishnan Mahadevan

"All the desirable things in life are either illegal, expensive, fattening or in love with someone else!"
My Scribblings @ <a href="http://wakened-cognition.blogspot.com/" rel="nofollow" target="_blank" onmousedown="this.href=&#39;http://www.google.com/url?q\x3dhttp%3A%2F%2Fwakened-cognition.blogspot.com%2F\x26sa\x3dD\x26sntz\x3d1\x26usg\x3dAFQjCNHzOdYJCASIDF_28vQtkp9gnKAYSQ&#39;;return true;" onclick="this.href=&#39;http://www.google.com/url?q\x3dhttp%3A%2F%2Fwakened-cognition.blogspot.com%2F\x26sa\x3dD\x26sntz\x3d1\x26usg\x3dAFQjCNHzOdYJCASIDF_28vQtkp9gnKAYSQ&#39;;return true;">http://wakened-cognition.blogspot.com/

My Technical Scribbings @ <a href="http://rationaleemotions.wordpress.com/" rel="nofollow" target="_blank" onmousedown="this.href=&#39;http://www.google.com/url?q\x3dhttp%3A%2F%2Frationaleemotions.wordpress.com%2F\x26sa\x3dD\x26sntz\x3d1\x26usg\x3dAFQjCNEcBOKyRn0lpL8LDbBuyAlKdwgXwQ&#39;;return true;" onclick="this.href=&#39;http://www.google.com/url?q\x3dhttp%3A%2F%2Frationaleemotions.wordpress.com%2F\x26sa\x3dD\x26sntz\x3d1\x26usg\x3dAFQjCNEcBOKyRn0lpL8LDbBuyAlKdwgXwQ&#39;;return true;">http://rationaleemotions.wordpress.com/

--
You received this message because you are subscribed to the Google Groups "testng-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at https://groups.google.com/group/testng-users.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: depends on nonexistent group "homePage" error

Hoang Nguyen
In reply to this post by Settaluri Karthik Sriharsha
Hi,

In my case, I didn't declare dependsOnGroups in the @Test as you as below:

@Test(dependsOnGroups=preSetup2, groups=preSetup3)


My way is declare only group in the @Test, then in the TestNGTestSuite.xml, I define the group dependency


Class Preconfig1.java

package TestLab.Interagtion.UploadPayment;

import Libs.Utils.*;
import FrameWork.*;

@Test(groups = {"PreConfig_1"})
public class PreConfig_1
{
    @Test(alwaysRun = false)
public void PreConfig_1() throws Exception
{
        Code....
    }
}

Class Upload01.java

package TestLab.Interagtion.UploadPayment;

import Libs.Utils.*;
import FrameWork.*;


@Test(groups = {"Upload01"})
public class Upload01
{
    @Test(alwaysRun = false)
public void Upload01() throws Exception
{
        Code....
    }
}



Class Upload02.java


package TestLab.Interagtion.UploadPayment;

import Libs.Utils.*;
import FrameWork.*;

@Test(groups = {"Upload02"})
public class Upload02
{
    @Test(alwaysRun = false)
    public void Upload01() throws Exception
{
        Code....
    }
}

TestNG TestSuite

<?xml version="1.0" encoding="utf-8" standalone="no"?>
<!DOCTYPE suite SYSTEM "http://testng.org/testng-1.0.dtd">
<suite name="UploadPayment" verbose="10">
<test name="Test_1">
<groups>
<dependencies>
<group name="Upload01" depends-on="PreConfig_1" />
<group name="Upload02" depends-on="PreConfig_1" />
</dependencies>
</groups>
<classes>
<class name="TestLab.Interagtion.UploadPayment.PreConfig_1" />
<class name="TestLab.Interagtion.UploadPayment.Upload01" />
<class name="TestLab.Interagtion.UploadPayment.Upload02" />
</classes>
</test>
</suite>


If @Test PreConfig_1 failed --> skip running @Test Upload01 and @Test Upload02


Hope it help,




Vào 09:32:10 UTC+7 Thứ Năm, ngày 25 tháng 5 năm 2017, Settaluri Karthik Sriharsha đã viết:
Say for example I've a UntilLogin, PostLogin classes containing the following piece of code : 

class UntilLogin() {


@Test(groups=preSetup1)
public void test_setup1() {
button
.click() // some action 1
}


@Test(dependsOnGroups=preSetup1, groups=preSetup2)
public void test_setup2() {
button
.click()  // some action 2
}


@Test(dependsOnGroups=preSetup2, groups=preSetup3)
public void test_setup3() {
button
.click() // some action 3
}


@Test(dependsOnGroups=preSetup3, groups=preSetup4)
public void test_setup4() {
// perform login
}


@Test(dependsOnGroups=preSetup4, groups=preSetup5)
public void test_setup5() {
// wait for splash screen to appear and click
}


@Test(dependsOnGroups=preSetup5, groups=homePage)
public void test_homePage() {
// wait for the elements to appears
}






class PostLogin() {


@Test(dependOnGroups=homePage, groups=postgroup)
public void test_postLogin() {
//
}


When i try to do maven install on this - I get the following error "of Nonexistent Group" 

Enter code he[INFO] Results:

[INFO] 

[INFO] Tests run: 0, Failures: 0, Errors: 0, Skipped: 0

[INFO] 

[INFO] ------------------------------------------------------------------------

[INFO] BUILD FAILURE

[INFO] ------------------------------------------------------------------------

[INFO] Total time: 3.564 s

[INFO] Finished at: 2017-05-25T01:57:42+05:30

[INFO] Final Memory: 25M/278M

[INFO] ------------------------------------------------------------------------

[ERROR] Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.20:test (default-test) on project android: There are test failures.

[ERROR] 

[ERROR] Please refer to /Users/ssrihar/Documents/workspace/android/testapp/relay/android/target/surefire-reports for the individual test results.

[ERROR] Please refer to dump files (if any exist) [date]-jvmRun[N].dump, [date].dumpstream and [date]-jvmRun[N].dumpstream.

[ERROR] There was an error in the forked process

[ERROR] 

[ERROR] DependencyMap::Method "ListsTest.test_listsHomePage()[pri:0, instance:com.sears.relay.android.ListsTest@5a61f5df]" depends on nonexistent group "HomePageGroup"

[ERROR] org.apache.maven.surefire.booter.SurefireBooterForkException: There was an error in the forked process

[ERROR] 

[ERROR] DependencyMap::Method "PostLogin.test_postLogin()[pri:0. PostLogin@5a61f5df]" depends on nonexistent group "homePage"

[ERROR] at org.apache.maven.plugin.surefire.booterclient.ForkStarter.fork(ForkStarter.java:665)

[ERROR] at org.apache.maven.plugin.surefire.booterclient.ForkStarter.fork(ForkStarter.java:533)

[ERROR] at org.apache.maven.plugin.surefire.booterclient.ForkStarter.run(ForkStarter.java:279)

[ERROR] at org.apache.maven.plugin.surefire.booterclient.ForkStarter.run(ForkStarter.java:243)

[ERROR] at org.apache.maven.plugin.surefire.AbstractSurefireMojo.executeProvider(AbstractSurefireMojo.java:1077)

[ERROR] at org.apache.maven.plugin.surefire.AbstractSurefireMojo.executeAfterPreconditionsChecked(AbstractSurefireMojo.java:907)

[ERROR] at org.apache.maven.plugin.surefire.AbstractSurefireMojo.execute(AbstractSurefireMojo.java:785)

[ERROR] at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:134)

[ERROR] at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:207)

[ERROR] at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:153)

[ERROR] at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:145)

[ERROR] at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:116)

[ERROR] at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:80)

[ERROR] at org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder.build(SingleThreadedBuilder.java:51)

[ERROR] at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:128)

[ERROR] at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:307)

[ERROR] at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:193)

[ERROR] at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:106)

[ERROR] at org.apache.maven.cli.MavenCli.execute(MavenCli.java:863)

[ERROR] at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:288)

[ERROR] at org.apache.maven.cli.MavenCli.main(MavenCli.java:199)

[ERROR] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

[ERROR] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)

[ERROR] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)

[ERROR] at java.lang.reflect.Method.invoke(Method.java:498)

[ERROR] at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:289)

[ERROR] at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:229)

[ERROR] at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:415)

[ERROR] at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:356)

[ERROR] -> [Help 1]re...

Kindly help me out in resolving this issue.


--
You received this message because you are subscribed to the Google Groups "testng-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at https://groups.google.com/group/testng-users.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: depends on nonexistent group "homePage" error

Settaluri Karthik Sriharsha
Hoang Nguyen , 

Thanks for your wonderful response. I'm currently modifying the test annotations at class level instead of method level and trying out the same. 

I've one qq here though.

Lets say if "preConfig" has "10 tests" to run of which I need only say "first 4" and proceed with second classes test methods there after. How do i achieve that ?



On Thursday, May 25, 2017 at 3:38:27 PM UTC+5:30, Hoang Nguyen wrote:
Hi,

In my case, I didn't declare dependsOnGroups in the @Test as you as below:

@Test(dependsOnGroups=preSetup2, groups=preSetup3)


My way is declare only group in the @Test, then in the TestNGTestSuite.xml, I define the group dependency


Class Preconfig1.java

package TestLab.Interagtion.UploadPayment;

import Libs.Utils.*;
import FrameWork.*;

@Test(groups = {"PreConfig_1"})
public class PreConfig_1
{
    @Test(alwaysRun = false)
public void PreConfig_1() throws Exception
{
        Code....
    }
}

Class Upload01.java

package TestLab.Interagtion.UploadPayment;

import Libs.Utils.*;
import FrameWork.*;


@Test(groups = {"Upload01"})
public class Upload01
{
    @Test(alwaysRun = false)
public void Upload01() throws Exception
{
        Code....
    }
}



Class Upload02.java


package TestLab.Interagtion.UploadPayment;

import Libs.Utils.*;
import FrameWork.*;

@Test(groups = {"Upload02"})
public class Upload02
{
    @Test(alwaysRun = false)
    public void Upload01() throws Exception
{
        Code....
    }
}

TestNG TestSuite

<?xml version="1.0" encoding="utf-8" standalone="no"?>
<!DOCTYPE suite SYSTEM "<a href="http://testng.org/testng-1.0.dtd" target="_blank" rel="nofollow" onmousedown="this.href=&#39;http://www.google.com/url?q\x3dhttp%3A%2F%2Ftestng.org%2Ftestng-1.0.dtd\x26sa\x3dD\x26sntz\x3d1\x26usg\x3dAFQjCNFHihXzQ1YlwcxcDehnw97TuniFLA&#39;;return true;" onclick="this.href=&#39;http://www.google.com/url?q\x3dhttp%3A%2F%2Ftestng.org%2Ftestng-1.0.dtd\x26sa\x3dD\x26sntz\x3d1\x26usg\x3dAFQjCNFHihXzQ1YlwcxcDehnw97TuniFLA&#39;;return true;">http://testng.org/testng-1.0.dtd">
<suite name="UploadPayment" verbose="10">
<test name="Test_1">
<groups>
<dependencies>
<group name="Upload01" depends-on="PreConfig_1" />
<group name="Upload02" depends-on="PreConfig_1" />
</dependencies>
</groups>
<classes>
<class name="TestLab.Interagtion.UploadPayment.PreConfig_1" />
<class name="TestLab.Interagtion.UploadPayment.Upload01" />
<class name="TestLab.Interagtion.UploadPayment.Upload02" />
</classes>
</test>
</suite>


If @Test PreConfig_1 failed --> skip running @Test Upload01 and @Test Upload02


Hope it help,




Vào 09:32:10 UTC+7 Thứ Năm, ngày 25 tháng 5 năm 2017, Settaluri Karthik Sriharsha đã viết:
Say for example I've a UntilLogin, PostLogin classes containing the following piece of code : 

class UntilLogin() {


@Test(groups=preSetup1)
public void test_setup1() {
button
.click() // some action 1
}


@Test(dependsOnGroups=preSetup1, groups=preSetup2)
public void test_setup2() {
button
.click()  // some action 2
}


@Test(dependsOnGroups=preSetup2, groups=preSetup3)
public void test_setup3() {
button
.click() // some action 3
}


@Test(dependsOnGroups=preSetup3, groups=preSetup4)
public void test_setup4() {
// perform login
}


@Test(dependsOnGroups=preSetup4, groups=preSetup5)
public void test_setup5() {
// wait for splash screen to appear and click
}


@Test(dependsOnGroups=preSetup5, groups=homePage)
public void test_homePage() {
// wait for the elements to appears
}






class PostLogin() {


@Test(dependOnGroups=homePage, groups=postgroup)
public void test_postLogin() {
//
}


When i try to do maven install on this - I get the following error "of Nonexistent Group" 

Enter code he[INFO] Results:

[INFO] 

[INFO] Tests run: 0, Failures: 0, Errors: 0, Skipped: 0

[INFO] 

[INFO] ------------------------------------------------------------------------

[INFO] BUILD FAILURE

[INFO] ------------------------------------------------------------------------

[INFO] Total time: 3.564 s

[INFO] Finished at: 2017-05-25T01:57:42+05:30

[INFO] Final Memory: 25M/278M

[INFO] ------------------------------------------------------------------------

[ERROR] Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.20:test (default-test) on project android: There are test failures.

[ERROR] 

[ERROR] Please refer to /Users/ssrihar/Documents/workspace/android/testapp/relay/android/target/surefire-reports for the individual test results.

[ERROR] Please refer to dump files (if any exist) [date]-jvmRun[N].dump, [date].dumpstream and [date]-jvmRun[N].dumpstream.

[ERROR] There was an error in the forked process

[ERROR] 

[ERROR] DependencyMap::Method "ListsTest.test_listsHomePage()[pri:0, instance:com.sears.relay.android.ListsTest@5a61f5df]" depends on nonexistent group "HomePageGroup"

[ERROR] org.apache.maven.surefire.booter.SurefireBooterForkException: There was an error in the forked process

[ERROR] 

[ERROR] DependencyMap::Method "PostLogin.test_postLogin()[pri:0. PostLogin@5a61f5df]" depends on nonexistent group "homePage"

[ERROR] at org.apache.maven.plugin.surefire.booterclient.ForkStarter.fork(ForkStarter.java:665)

[ERROR] at org.apache.maven.plugin.surefire.booterclient.ForkStarter.fork(ForkStarter.java:533)

[ERROR] at org.apache.maven.plugin.surefire.booterclient.ForkStarter.run(ForkStarter.java:279)

[ERROR] at org.apache.maven.plugin.surefire.booterclient.ForkStarter.run(ForkStarter.java:243)

[ERROR] at org.apache.maven.plugin.surefire.AbstractSurefireMojo.executeProvider(AbstractSurefireMojo.java:1077)

[ERROR] at org.apache.maven.plugin.surefire.AbstractSurefireMojo.executeAfterPreconditionsChecked(AbstractSurefireMojo.java:907)

[ERROR] at org.apache.maven.plugin.surefire.AbstractSurefireMojo.execute(AbstractSurefireMojo.java:785)

[ERROR] at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:134)

[ERROR] at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:207)

[ERROR] at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:153)

[ERROR] at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:145)

[ERROR] at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:116)

[ERROR] at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:80)

[ERROR] at org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder.build(SingleThreadedBuilder.java:51)

[ERROR] at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:128)

[ERROR] at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:307)

[ERROR] at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:193)

[ERROR] at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:106)

[ERROR] at org.apache.maven.cli.MavenCli.execute(MavenCli.java:863)

[ERROR] at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:288)

[ERROR] at org.apache.maven.cli.MavenCli.main(MavenCli.java:199)

[ERROR] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

[ERROR] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)

[ERROR] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)

[ERROR] at java.lang.reflect.Method.invoke(Method.java:498)

[ERROR] at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:289)

[ERROR] at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:229)

[ERROR] at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:415)

[ERROR] at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:356)

[ERROR] -> [Help 1]re...

Kindly help me out in resolving this issue.


--
You received this message because you are subscribed to the Google Groups "testng-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at https://groups.google.com/group/testng-users.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: depends on nonexistent group "homePage" error

Krishnan Mahadevan

Karthik,

 

I am not able to reproduce your issue. FWIW I am running on TestNG 6.11

 

Here’s what I have:

 

UntilLogin.java

 

public class UntilLogin {
   
@Test(groups = "preSetup1")
   
public void test_setup1() {
        System.
out.println("test_setup1");
    }

   
@Test(dependsOnGroups = "preSetup1", groups = "preSetup2")
   
public void test_setup2() {
        System.
out.println("test_setup2");
    }

   
@Test(dependsOnGroups = "preSetup2", groups = "preSetup3")
   
public void test_setup3() {
        System.
out.println("test_setup3");
    }

   
@Test(dependsOnGroups = "preSetup3", groups = "preSetup4")
   
public void test_setup4() {
        System.
out.println("test_setup4");
    }

   
@Test(dependsOnGroups = "preSetup4", groups = "preSetup5")
   
public void test_setup5() {
        System.
out.println("test_setup5");
    }

   
@Test(dependsOnGroups = "preSetup5", groups = "homePage")
   
public void test_homePage() {
        System.
out.println("test_homePage");
    }

}

 

PostLogin.java

 

public class PostLogin {
   
@Test(dependsOnGroups="homePage", groups="postgroup")
   
public void test_postLogin() {
        System.
out.println("test_postLogin");
    }
}

 

Here’s my suite xml file

 

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE suite SYSTEM "http://testng.org/testng-1.0.dtd">
<suite name="Suite" parallel="none">
    <
test name="Login_ClickLists_SelectListSelectItemAndOrderTest" verbose="3">
        <
classes>
            <
class name="com.rationaleemotions.testng.UntilLogin">
                <
methods>
                    <
include name="test_setup1"/>
                    <
include name="test_setup2"/>
                    <
include name="test_setup3"/>
                    <
include name="test_setup4"/>
                    <
include name="test_setup5"/>
                    <
include name="test_homePage"/>
                </
methods>
            </
class>
            <
class name="com.rationaleemotions.testng.PostLogin">
                <
methods>
                    <
include name="test_postLogin"/>
                </
methods>
            </
class>
        </
classes>
    </
test>
</
suite>

 

Here’s the output:

 

[INFO] --- maven-surefire-plugin:2.19.1:test (default-test) @ testbed ---

 

-------------------------------------------------------

T E S T S

-------------------------------------------------------

Running TestSuite

test_setup1

test_setup2

test_setup3

test_setup4

test_setup5

test_homePage

test_postLogin

===== Invoked methods

    UntilLogin.test_setup1()[pri:0, instance:com.rationaleemotions.testng.UntilLogin@36f6e879] 922151033

    UntilLogin.test_setup2()[pri:0, instance:com.rationaleemotions.testng.UntilLogin@36f6e879] 922151033

    UntilLogin.test_setup3()[pri:0, instance:com.rationaleemotions.testng.UntilLogin@36f6e879] 922151033

    UntilLogin.test_setup4()[pri:0, instance:com.rationaleemotions.testng.UntilLogin@36f6e879] 922151033

    UntilLogin.test_setup5()[pri:0, instance:com.rationaleemotions.testng.UntilLogin@36f6e879] 922151033

    UntilLogin.test_homePage()[pri:0, instance:com.rationaleemotions.testng.UntilLogin@36f6e879] 922151033

    PostLogin.test_postLogin()[pri:0, instance:com.rationaleemotions.testng.PostLogin@735b478] 120960120

=====

PASSED: test_setup1

PASSED: test_setup2

PASSED: test_setup3

PASSED: test_setup4

PASSED: test_setup5

PASSED: test_homePage

PASSED: test_postLogin

 

===============================================

    Login_ClickLists_SelectListSelectItemAndOrderTest

    Tests run: 7, Failures: 0, Skips: 0

===============================================

 

Tests run: 7, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 15.323 sec - in TestSuite

 

Results :

 

Tests run: 7, Failures: 0, Errors: 0, Skipped: 0

 

[INFO] ------------------------------------------------------------------------

[INFO] BUILD SUCCESS

[INFO] ------------------------------------------------------------------------

[INFO] Total time: 19.565 s

[INFO] Finished at: 2017-05-25T20:21:44+05:30

[INFO] Final Memory: 28M/318M

[INFO] ------------------------------------------------------------------------

 

 

 

 

Thanks & Regards

Krishnan Mahadevan

 

"All the desirable things in life are either illegal, expensive, fattening or in love with someone else!"

My Scribblings @ http://wakened-cognition.blogspot.com/

My Technical Scribbings @ http://rationaleemotions.wordpress.com/

 

From: <[hidden email]> on behalf of Settaluri Karthik Sriharsha <[hidden email]>
Reply-To: <[hidden email]>
Date: Thursday, May 25, 2017 at 4:07 PM
To: testng-users <[hidden email]>
Subject: [testng-users] Re: depends on nonexistent group "homePage" error

 

Hoang Nguyen , 

 

Thanks for your wonderful response. I'm currently modifying the test annotations at class level instead of method level and trying out the same. 

 

I've one qq here though.

 

Lets say if "preConfig" has "10 tests" to run of which I need only say "first 4" and proceed with second classes test methods there after. How do i achieve that ?

 



On Thursday, May 25, 2017 at 3:38:27 PM UTC+5:30, Hoang Nguyen wrote:

Hi,

 

In my case, I didn't declare dependsOnGroups in the @Test as you as below:

 

@Test(dependsOnGroups=preSetup2, groups=preSetup3)

 

 

My way is declare only group in the @Test, then in the TestNGTestSuite.xml, I define the group dependency

 

 

Class Preconfig1.java

 

package TestLab.Interagtion.UploadPayment;

import Libs.Utils.*;
import FrameWork.*;

@Test(groups = {"PreConfig_1"})
public class PreConfig_1
{
    @Test(alwaysRun = false)
    public void PreConfig_1() throws Exception
    {
        Code....
    }
}
 
Class Upload01.java
 
package TestLab.Interagtion.UploadPayment;

import Libs.Utils.*;
import FrameWork.*;


@Test(groups = {"Upload01"})
public class Upload01
{
    @Test(alwaysRun = false)
    public void Upload01() throws Exception
    {
        Code....
    }
}
 
 
 
Class Upload02.java
 
 
package TestLab.Interagtion.UploadPayment;

import Libs.Utils.*;
import FrameWork.*;
 
@Test(groups = {"Upload02"})
public class Upload02
{
    @Test(alwaysRun = false)
    public void Upload01() throws Exception
    {
        Code....
    }
}
 
TestNG TestSuite
 
<?xml version="1.0" encoding="utf-8" standalone="no"?>
<!DOCTYPE suite SYSTEM "http://testng.org/testng-1.0.dtd">
<suite name="UploadPayment" verbose="10">
    <
test name="Test_1">
        <
groups>
            <
dependencies>
                <
group name="Upload01" depends-on="PreConfig_1" />
                <
group name="Upload02" depends-on="PreConfig_1" />
            </
dependencies>
        </
groups>
        <
classes>
            <
class name="TestLab.Interagtion.UploadPayment.PreConfig_1" />
            <
class name="TestLab.Interagtion.UploadPayment.Upload01" />
            <
class name="TestLab.Interagtion.UploadPayment.Upload02" />
        </
classes>
    </
test>
</
suite>

 

 

If @Test PreConfig_1 failed --> skip running @Test Upload01 and @Test Upload02

 

 

Hope it help,

 

 



Vào 09:32:10 UTC+7 Thứ Năm, ngày 25 tháng 5 năm 2017, Settaluri Karthik Sriharsha đã viết:

Say for example I've a UntilLogin, PostLogin classes containing the following piece of code : 

 

class UntilLogin() {


@Test(groups=preSetup1)
public void test_setup1() {
button
.click() // some action 1
}


@Test(dependsOnGroups=preSetup1, groups=preSetup2)
public void test_setup2() {
button
.click()  // some action 2
}


@Test(dependsOnGroups=preSetup2, groups=preSetup3)
public void test_setup3() {
button
.click() // some action 3
}


@Test(dependsOnGroups=preSetup3, groups=preSetup4)
public void test_setup4() {
// perform login
}


@Test(dependsOnGroups=preSetup4, groups=preSetup5)
public void test_setup5() {
// wait for splash screen to appear and click
}


@Test(dependsOnGroups=preSetup5, groups=homePage)
public void test_homePage() {
// wait for the elements to appears
}


 

 

class PostLogin() {


@Test(dependOnGroups=homePage, groups=postgroup)
public void test_postLogin() {
//
}

 

 

When i try to do maven install on this - I get the following error "of Nonexistent Group" 

 

Enter code he[INFO] Results:

[INFO] 

[INFO] Tests run: 0, Failures: 0, Errors: 0, Skipped: 0

[INFO] 

[INFO] ------------------------------------------------------------------------

[INFO] BUILD FAILURE

[INFO] ------------------------------------------------------------------------

[INFO] Total time: 3.564 s

[INFO] Finished at: 2017-05-25T01:57:42+05:30

[INFO] Final Memory: 25M/278M

[INFO] ------------------------------------------------------------------------

[ERROR] Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.20:test (default-test) on project android: There are test failures.

[ERROR] 

[ERROR] Please refer to /Users/ssrihar/Documents/workspace/android/testapp/relay/android/target/surefire-reports for the individual test results.

[ERROR] Please refer to dump files (if any exist) [date]-jvmRun[N].dump, [date].dumpstream and [date]-jvmRun[N].dumpstream.

[ERROR] There was an error in the forked process

[ERROR] 

[ERROR] DependencyMap::Method "ListsTest.test_listsHomePage()[pri:0, instance:com.sears.relay.android.ListsTest@5a61f5df]" depends on nonexistent group "HomePageGroup"

[ERROR] org.apache.maven.surefire.booter.SurefireBooterForkException: There was an error in the forked process

[ERROR] 

[ERROR] DependencyMap::Method "PostLogin.test_postLogin()[pri:0. PostLogin@5a61f5df]" depends on nonexistent group "homePage"

[ERROR] at org.apache.maven.plugin.surefire.booterclient.ForkStarter.fork(ForkStarter.java:665)

[ERROR] at org.apache.maven.plugin.surefire.booterclient.ForkStarter.fork(ForkStarter.java:533)

[ERROR] at org.apache.maven.plugin.surefire.booterclient.ForkStarter.run(ForkStarter.java:279)

[ERROR] at org.apache.maven.plugin.surefire.booterclient.ForkStarter.run(ForkStarter.java:243)

[ERROR] at org.apache.maven.plugin.surefire.AbstractSurefireMojo.executeProvider(AbstractSurefireMojo.java:1077)

[ERROR] at org.apache.maven.plugin.surefire.AbstractSurefireMojo.executeAfterPreconditionsChecked(AbstractSurefireMojo.java:907)

[ERROR] at org.apache.maven.plugin.surefire.AbstractSurefireMojo.execute(AbstractSurefireMojo.java:785)

[ERROR] at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:134)

[ERROR] at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:207)

[ERROR] at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:153)

[ERROR] at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:145)

[ERROR] at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:116)

[ERROR] at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:80)

[ERROR] at org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder.build(SingleThreadedBuilder.java:51)

[ERROR] at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:128)

[ERROR] at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:307)

[ERROR] at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:193)

[ERROR] at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:106)

[ERROR] at org.apache.maven.cli.MavenCli.execute(MavenCli.java:863)

[ERROR] at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:288)

[ERROR] at org.apache.maven.cli.MavenCli.main(MavenCli.java:199)

[ERROR] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

[ERROR] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)

[ERROR] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)

[ERROR] at java.lang.reflect.Method.invoke(Method.java:498)

[ERROR] at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:289)

[ERROR] at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:229)

[ERROR] at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:415)

[ERROR] at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:356)

[ERROR] -> [Help 1]re...


Kindly help me out in resolving this issue.

 

 

--
You received this message because you are subscribed to the Google Groups "testng-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at https://groups.google.com/group/testng-users.
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "testng-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
Visit this group at https://groups.google.com/group/testng-users.
For more options, visit https://groups.google.com/d/optout.
Loading...