Skip to Content
author's profile photo Former Member
Former Member

Junit Testing

I am new to Hybris.
I am trying to set up junit testing.The unit test that I am trying to set up involves invoking cmssiteservice to get site configurations. I would like to know, how can I configure cmssiteservice to return the details of the site that I am interested in.. Where can i specify the site it has to pull ?

How versatile is Junit in testing site functionality,can it be used to test all of the functionality or are there scenarios which can only done by bringing up the server?

Add a comment
10|10000 characters needed characters exceeded

Related questions

1 Answer

  • Best Answer
    Posted on Oct 25, 2014 at 02:56 AM

    Test class source code is included in the hybris binary distribution for the purposes of helping document the usage of the hybris APIs. Take a look at de.hybris.platform.cms2.servicelayer.services.impl.DefaultCMSSiteServiceIntegrationTest in the ext-content/cms2 extension.

    Also take a look at Wiki documentation : https://wiki.hybris.com/display/release5/Testing+in+the+hybris+Commerce+Suite

    I also wrote a brief list of Intellij tips which includes Junit testing: https://wiki.hybris.com/display/~arthur.perry%40hybris.com/Intellij+Observations

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.