// Path: behaviors/behavior-tutorial/behavior-tutorial-platform/src/main/java/com/someco/model/SomeCoRatingsModel.java
// public interface SomeCoRatingsModel {
//     // Namespaces
//     public static final String NAMESPACE_SOMECO_RATINGS_CONTENT_MODEL  = "http://www.someco.com/model/ratings/1.0";
// 
//     // Types
//     public static final String TYPE_SCR_RATING = "rating";
// 
//     // Aspects
//     public static final String ASPECT_SCR_RATEABLE = "rateable";
// 
//     // Properties
//     public static final String PROP_RATING = "rating";
//     public static final String PROP_RATER = "rater";
//     public static final String PROP_AVERAGE_RATING= "averageRating";
//     public static final String PROP_TOTAL_RATING= "totalRating";
//     public static final String PROP_RATING_COUNT= "ratingCount";
// 
//     // Associations
//     public static final String ASSN_SCR_RATINGS = "ratings";
// }


import static org.alfresco.service.namespace.QName.createQName;
import static org.junit.Assert.assertEquals;
import java.io.Serializable;
import java.util.HashMap;
import java.util.Map;
import com.someco.model.SomeCoRatingsModel;
import org.alfresco.model.ContentModel;
import org.alfresco.rad.test.AlfrescoTestRunner;
import org.alfresco.service.cmr.repository.ChildAssociationRef;
import org.alfresco.service.cmr.repository.NodeRef;
import org.alfresco.service.cmr.repository.NodeService;
import org.alfresco.service.namespace.NamespaceService;
import org.alfresco.service.namespace.QName;
import org.apache.log4j.Logger;
import org.junit.Test;
import org.junit.runner.RunWith;
package com.someco.test;





@RunWith(value = AlfrescoTestRunner.class)
public class RatingBehaviorIT extends BaseIT {

    static Logger log = Logger.getLogger(RatingBehaviorIT.class);

    @Test
    public void ratingTypeTest() {
        final String RATER = "jpotts";

        NodeService nodeService = getServiceRegistry().getNodeService();

        Map<QName, Serializable> nodeProperties = new HashMap<>();
        this.nodeRef = createNode(getFilename(), ContentModel.TYPE_CONTENT, nodeProperties);

// Path: behaviors/behavior-tutorial/behavior-tutorial-platform/src/main/java/com/someco/model/SomeCoRatingsModel.java
// public interface SomeCoRatingsModel {
//     // Namespaces
//     public static final String NAMESPACE_SOMECO_RATINGS_CONTENT_MODEL  = "http://www.someco.com/model/ratings/1.0";
// 
//     // Types
//     public static final String TYPE_SCR_RATING = "rating";
// 
//     // Aspects
//     public static final String ASPECT_SCR_RATEABLE = "rateable";
// 
//     // Properties
//     public static final String PROP_RATING = "rating";
//     public static final String PROP_RATER = "rater";
//     public static final String PROP_AVERAGE_RATING= "averageRating";
//     public static final String PROP_TOTAL_RATING= "totalRating";
//     public static final String PROP_RATING_COUNT= "ratingCount";
// 
//     // Associations
//     public static final String ASSN_SCR_RATINGS = "ratings";
// }


// Path: behaviors/behavior-tutorial/behavior-tutorial-integration-tests/src/test/java/com/someco/test/RatingBehaviorIT.java
import static org.alfresco.service.namespace.QName.createQName;
import static org.junit.Assert.assertEquals;
import java.io.Serializable;
import java.util.HashMap;
import java.util.Map;
import com.someco.model.SomeCoRatingsModel;
import org.alfresco.model.ContentModel;
import org.alfresco.rad.test.AlfrescoTestRunner;
import org.alfresco.service.cmr.repository.ChildAssociationRef;
import org.alfresco.service.cmr.repository.NodeRef;
import org.alfresco.service.cmr.repository.NodeService;
import org.alfresco.service.namespace.NamespaceService;
import org.alfresco.service.namespace.QName;
import org.apache.log4j.Logger;
import org.junit.Test;
import org.junit.runner.RunWith;

package com.someco.test;





@RunWith(value = AlfrescoTestRunner.class)
public class RatingBehaviorIT extends BaseIT {

    static Logger log = Logger.getLogger(RatingBehaviorIT.class);

    @Test
    public void ratingTypeTest() {
        final String RATER = "jpotts";

        NodeService nodeService = getServiceRegistry().getNodeService();

        Map<QName, Serializable> nodeProperties = new HashMap<>();
        this.nodeRef = createNode(getFilename(), ContentModel.TYPE_CONTENT, nodeProperties);

        QName aspectQName = createQName(SomeCoRatingsModel.NAMESPACE_SOMECO_RATINGS_CONTENT_MODEL, SomeCoRatingsModel.ASPECT_SCR_RATEABLE);