Can we import file from src/test to src/main in framework ?

1,213 views
Skip to first unread message

garvita girotra

unread,
Apr 6, 2020, 5:03:54 AM4/6/20
to Selenium Users
Hi,

I am revamping structure of framework. Idea is to keep test java class in src/test package and other is src/main. I am not able to import class from src/test to src/java. 

While i was importing from src/main to src/test, i got dialog box in idea to confirm circular communication between packages and i confirmed that. And i am able to import from test to main package. But vice versa is not happening. 

Do we need to add any new dependency or something else ?

Thanks !!

⇜Krishnan Mahadevan⇝

unread,
Apr 6, 2020, 6:45:55 AM4/6/20
to Selenium Users
Not sure what exactly you are trying to do.

  • src/main/java - Intended to house production code (code that will be part of the jar, if you create one)
  • src/test/java - Intended to house test code (this code will not be part of the jar, if you create one). It will have access to production code but vice versa is NOT true.


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 view this discussion on the web visit https://groups.google.com/d/msgid/selenium-users/8007b7ec-b0b0-4a7f-9e3a-d9cde64eef79%40googlegroups.com.

garvita girotra

unread,
Apr 8, 2020, 3:50:24 AM4/8/20
to Selenium Users
Got that, thanks !!


On Monday, April 6, 2020 at 4:15:55 PM UTC+5:30, Krishnan Mahadevan wrote:
Not sure what exactly you are trying to do.

  • src/main/java - Intended to house production code (code that will be part of the jar, if you create one)
  • src/test/java - Intended to house test code (this code will not be part of the jar, if you create one). It will have access to production code but vice versa is NOT true.


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/


On Mon, Apr 6, 2020 at 2:34 PM garvita girotra <garvitag...@gmail.com> wrote:
Hi,

I am revamping structure of framework. Idea is to keep test java class in src/test package and other is src/main. I am not able to import class from src/test to src/java. 

While i was importing from src/main to src/test, i got dialog box in idea to confirm circular communication between packages and i confirmed that. And i am able to import from test to main package. But vice versa is not happening. 

Do we need to add any new dependency or something else ?

Thanks !!

--
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 seleniu...@googlegroups.com.
Reply all
Reply to author
Forward
0 new messages