mirror of
https://github.com/Alfresco/SearchServices.git
synced 2026-09-16 18:12:56 +00:00
update test with the new ContentModel
This commit is contained in:
@@ -6,6 +6,7 @@ import org.alfresco.rest.model.RestCommentModel;
|
||||
import org.alfresco.rest.model.SiteMember;
|
||||
import org.alfresco.utility.exception.DataPreparationException;
|
||||
import org.alfresco.utility.model.FileModel;
|
||||
import org.alfresco.utility.model.FolderModel;
|
||||
import org.alfresco.utility.model.SiteModel;
|
||||
import org.alfresco.utility.model.UserModel;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
@@ -67,7 +68,7 @@ public class RestDemoTest extends RestTest
|
||||
@Test
|
||||
public void adminCanPostAndUpdateComments() throws Exception
|
||||
{
|
||||
FileModel fileModel = dataContent.usingResource("Shared")
|
||||
FileModel fileModel = dataContent.usingResource(new FolderModel("Shared"))
|
||||
.usingUser(userModel)
|
||||
.createContent(DocumentType.TEXT_PLAIN);
|
||||
// add new comment
|
||||
|
||||
@@ -5,6 +5,7 @@ import org.alfresco.rest.exception.JsonToModelConversionException;
|
||||
import org.alfresco.rest.model.RestCommentModel;
|
||||
import org.alfresco.utility.data.DataUser;
|
||||
import org.alfresco.utility.model.FileModel;
|
||||
import org.alfresco.utility.model.FolderModel;
|
||||
import org.alfresco.utility.model.UserModel;
|
||||
import org.alfresco.utility.testrail.ExecutionType;
|
||||
import org.alfresco.utility.testrail.annotation.TestRail;
|
||||
@@ -32,7 +33,7 @@ public class SampleCommentsTest extends RestTest
|
||||
restClient.authenticateUser(userModel);
|
||||
commentsAPI.useRestClient(restClient);
|
||||
|
||||
document = dataContent.usingResource("Shared").usingUser(userModel).createContent(DocumentType.TEXT_PLAIN);
|
||||
document = dataContent.usingResource(new FolderModel("Shared")).usingUser(userModel).createContent(DocumentType.TEXT_PLAIN);
|
||||
}
|
||||
|
||||
@TestRail(section={"rest-api", "comments"}, executionType= ExecutionType.SANITY,
|
||||
|
||||
Reference in New Issue
Block a user