// Path: content/content-tutorial/content-tutorial-platform/src/main/java/com/someco/model/SomeCoModel.java
// public interface SomeCoModel {
// 
//     // Types
//     public static final String NAMESPACE_SOMECO_CONTENT_MODEL  = "http://www.someco.com/model/content/1.0";
//     public static final String TYPE_SC_DOC = "doc";
//     public static final String TYPE_SC_WHITEPAPER = "whitepaper";
// 
//     // Aspects
//     public static final String ASPECT_SC_WEBABLE = "webable";
//     public static final String ASPECT_SC_PRODUCT_RELATED = "productRelated";
// 
//     // Properties
//     public static final String PROP_PRODUCT = "product";
//     public static final String PROP_VERSION = "version";
//     public static final String PROP_PUBLISHED = "published";
//     public static final String PROP_IS_ACTIVE = "isActive";
// 
//     // Associations
//     public static final String ASSN_RELATED_DOCUMENTS = "relatedDocuments";
// }


import com.someco.model.SomeCoModel;
import org.alfresco.model.ContentModel;
import org.alfresco.rad.test.AbstractAlfrescoIT;
import org.alfresco.rad.test.AlfrescoTestRunner;
import org.alfresco.repo.content.MimetypeMap;
import org.alfresco.repo.nodelocator.CompanyHomeNodeLocator;
import org.alfresco.service.cmr.repository.ChildAssociationRef;
import org.alfresco.service.cmr.repository.ContentReader;
import org.alfresco.service.cmr.repository.ContentWriter;
import org.alfresco.service.cmr.repository.NodeRef;
import org.alfresco.service.namespace.NamespaceService;
import org.alfresco.service.namespace.QName;
import org.apache.commons.io.IOUtils;
import org.junit.After;
import org.junit.Test;
import org.junit.runner.RunWith;
import java.io.IOException;
import java.io.InputStream;
import java.io.Serializable;
import java.util.Collection;
import java.util.Date;
import java.util.HashMap;
import java.util.Map;
import static org.alfresco.service.namespace.QName.createQName;
import static org.junit.Assert.assertEquals;
import static org.junit.Assert.assertTrue;
package com.someco.test;




/**
 * Created by jpotts, Metaversant on 4/11/18.
 */
@RunWith(value = AlfrescoTestRunner.class)
public class SomecoContentModelIT extends AbstractAlfrescoIT {

    private NodeRef nodeRef;

    @After
    public void teardown() {
        // Clean up node
        if (nodeRef != null) {
            getServiceRegistry().getNodeService().deleteNode(nodeRef);
        }
    }

    @Test
    public void testSomeCoContentModel() {
        Collection<QName> allContentModels = getServiceRegistry().getDictionaryService().getAllModels();
// Path: content/content-tutorial/content-tutorial-platform/src/main/java/com/someco/model/SomeCoModel.java
// public interface SomeCoModel {
// 
//     // Types
//     public static final String NAMESPACE_SOMECO_CONTENT_MODEL  = "http://www.someco.com/model/content/1.0";
//     public static final String TYPE_SC_DOC = "doc";
//     public static final String TYPE_SC_WHITEPAPER = "whitepaper";
// 
//     // Aspects
//     public static final String ASPECT_SC_WEBABLE = "webable";
//     public static final String ASPECT_SC_PRODUCT_RELATED = "productRelated";
// 
//     // Properties
//     public static final String PROP_PRODUCT = "product";
//     public static final String PROP_VERSION = "version";
//     public static final String PROP_PUBLISHED = "published";
//     public static final String PROP_IS_ACTIVE = "isActive";
// 
//     // Associations
//     public static final String ASSN_RELATED_DOCUMENTS = "relatedDocuments";
// }


// Path: content/content-tutorial/content-tutorial-integration-tests/src/test/java/com/someco/test/SomecoContentModelIT.java
import com.someco.model.SomeCoModel;
import org.alfresco.model.ContentModel;
import org.alfresco.rad.test.AbstractAlfrescoIT;
import org.alfresco.rad.test.AlfrescoTestRunner;
import org.alfresco.repo.content.MimetypeMap;
import org.alfresco.repo.nodelocator.CompanyHomeNodeLocator;
import org.alfresco.service.cmr.repository.ChildAssociationRef;
import org.alfresco.service.cmr.repository.ContentReader;
import org.alfresco.service.cmr.repository.ContentWriter;
import org.alfresco.service.cmr.repository.NodeRef;
import org.alfresco.service.namespace.NamespaceService;
import org.alfresco.service.namespace.QName;
import org.apache.commons.io.IOUtils;
import org.junit.After;
import org.junit.Test;
import org.junit.runner.RunWith;
import java.io.IOException;
import java.io.InputStream;
import java.io.Serializable;
import java.util.Collection;
import java.util.Date;
import java.util.HashMap;
import java.util.Map;
import static org.alfresco.service.namespace.QName.createQName;
import static org.junit.Assert.assertEquals;
import static org.junit.Assert.assertTrue;

package com.someco.test;




/**
 * Created by jpotts, Metaversant on 4/11/18.
 */
@RunWith(value = AlfrescoTestRunner.class)
public class SomecoContentModelIT extends AbstractAlfrescoIT {

    private NodeRef nodeRef;

    @After
    public void teardown() {
        // Clean up node
        if (nodeRef != null) {
            getServiceRegistry().getNodeService().deleteNode(nodeRef);
        }
    }

    @Test
    public void testSomeCoContentModel() {
        Collection<QName> allContentModels = getServiceRegistry().getDictionaryService().getAllModels();
        QName scModelQName = createQName(SomeCoModel.NAMESPACE_SOMECO_CONTENT_MODEL, "somecomodel");