Issue regarding WebDriver Manager

569 views
Skip to first unread message

sachin patil

unread,
Feb 11, 2019, 8:20:01 AM2/11/19
to seleniu...@googlegroups.com
When i run my script from TestNG.xml file it works fine.

But i run it as Maven Test i get the below error.

                  <dependency>

<groupId>io.github.bonigarcia</groupId>

Dependency <artifactId>webdrivermanager</artifactId>

<version>3.3.0</version>

<scope>test</scope>

   </dependency>


[ERROR] COMPILATION ERROR : 

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

[ERROR] /Users/rahul.kardel/Documents/TorenzoWebSite/src/main/java/com/torenzosite/qa/base/TestBase.java:[35,32] package io.github.bonigarcia.wdm does not exist

[ERROR] /Users/rahul.kardel/Documents/TorenzoWebSite/src/main/java/com/torenzosite/qa/base/TestBase.java:[36,32] package io.github.bonigarcia.wdm does not exist

[ERROR] /Users/rahul.kardel/Documents/TorenzoWebSite/src/main/java/com/torenzosite/qa/base/TestBase.java:[79,41] cannot find symbol

  symbol:   variable WebDriverManager

  location: class com.torenzosite.qa.base.TestBase

[ERROR] /Users/rahul.kardel/Documents/TorenzoWebSite/src/main/java/com/torenzosite/qa/base/TestBase.java:[87,41] cannot find symbol

  symbol:   variable WebDriverManager

  location: class com.torenzosite.qa.base.TestBase

[ERROR] /Users/rahul.kardel/Documents/TorenzoWebSite/src/main/java/com/torenzosite/qa/base/TestBase.java:[94,41] cannot find symbol

  symbol:   variable WebDriverManager

  location: class com.torenzosite.qa.base.TestBase

[ERROR] /Users/rahul.kardel/Documents/TorenzoWebSite/src/main/java/com/torenzosite/qa/base/TestBase.java:[101,41] cannot find symbol

  symbol:   variable WebDriverManager

  location: class com.torenzosite.qa.base.TestBase

[ERROR] /Users/rahul.kardel/Documents/TorenzoWebSite/src/main/java/com/torenzosite/qa/base/TestBase.java:[111,33] cannot find symbol

  symbol:   variable WebDriverManager

  location: class com.torenzosite.qa.base.TestBase

[INFO] 7 errors 

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

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

[INFO] BUILD FAILURE

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

[INFO] Total time: 7.212 s

[INFO] Finished at: 2019-02-11T18:41:57+05:30

[INFO] Final Memory: 25M/179M

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

[ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.7.0:compile (default-compile) on project torenzowebsite: Compilation failure: Compilation failure:

[ERROR] /Users/rahul.kardel/Documents/TorenzoWebSite/src/main/java/com/torenzosite/qa/base/TestBase.java:[35,32] package io.github.bonigarcia.wdm does not exist

[ERROR] /Users/rahul.kardel/Documents/TorenzoWebSite/src/main/java/com/torenzosite/qa/base/TestBase.java:[36,32] package io.github.bonigarcia.wdm does not exist

[ERROR] /Users/rahul.kardel/Documents/TorenzoWebSite/src/main/java/com/torenzosite/qa/base/TestBase.java:[79,41] cannot find symbol

[ERROR] symbol:   variable WebDriverManager

[ERROR] location: class com.torenzosite.qa.base.TestBase

[ERROR] /Users/rahul.kardel/Documents/TorenzoWebSite/src/main/java/com/torenzosite/qa/base/TestBase.java:[87,41] cannot find symbol

[ERROR] symbol:   variable WebDriverManager

[ERROR] location: class com.torenzosite.qa.base.TestBase

[ERROR] /Users/rahul.kardel/Documents/TorenzoWebSite/src/main/java/com/torenzosite/qa/base/TestBase.java:[94,41] cannot find symbol

[ERROR] symbol:   variable WebDriverManager

[ERROR] location: class com.torenzosite.qa.base.TestBase

[ERROR] /Users/rahul.kardel/Documents/TorenzoWebSite/src/main/java/com/torenzosite/qa/base/TestBase.java:[101,41] cannot find symbol

[ERROR] symbol:   variable WebDriverManager

[ERROR] location: class com.torenzosite.qa.base.TestBase

[ERROR] /Users/rahul.kardel/Documents/TorenzoWebSite/src/main/java/com/torenzosite/qa/base/TestBase.java:[111,33] cannot find symbol

[ERROR] symbol:   variable WebDriverManager

[ERROR] location: class com.torenzosite.qa.base.TestBase

[ERROR] -> [Help 1]

[ERROR] 

[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.

[ERROR] Re-run Maven using the -X switch to enable full debug logging.

[ERROR] 

[ERROR] For more information about the errors and possible solutions, please read the following articles:

[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException





Best Regard
Sachin Patil
+91-9552619077

⇜Krishnan Mahadevan⇝

unread,
Feb 11, 2019, 11:10:27 AM2/11/19
to Selenium Users
The issue is because you have added the dependency with its scope as "test" [ which means its visible only to src/test/java ] and your code is trying access those classes under src/main/java.

Please change your dependency entry to as below

<dependency>
    <groupId>io.github.bonigarcia</groupId>
    <artifactId>webdrivermanager</artifactId>
    <version>3.3.0</version>
</dependency>

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 Scribblings @ https://rationaleemotions.com/


--
You received this message because you are subscribed to the Google Groups "Selenium Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to selenium-user...@googlegroups.com.
To post to this group, send email to seleniu...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/selenium-users/CAA_T2rH%2BfLJRObD%2BixM502UC%3DwLbGZSAz71V3m6X0BmAc60mAw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

sachin patil

unread,
Feb 11, 2019, 11:23:16 AM2/11/19
to seleniu...@googlegroups.com
Thanks.


Its working fine now

Best Regard
Sachin Patil
+91-9552619077


Reply all
Reply to author
Forward
0 new messages