REPO-437: Audit REST API

- fixed Audit tests by creating the private site in the AuditTest class
This commit is contained in:
Andrei Forascu
2017-08-03 18:00:26 +03:00
parent 8e0834ceac
commit de775c64b2
2 changed files with 3 additions and 3 deletions
@@ -66,15 +66,12 @@ public abstract class RestTest extends AbstractTestNGSpringContextTests
protected SiteModel testSite;
protected SiteModel privateTestSite;
@BeforeSuite(alwaysRun = true)
public void checkServerHealth() throws Exception
{
super.springTestContextPrepareTestInstance();
serverHealth.assertServerIsOnline();
testSite = dataSite.createPublicRandomSite();
privateTestSite = dataSite.createPrivateRandomSite();
}
@BeforeMethod(alwaysRun=true)
@@ -45,6 +45,7 @@ public abstract class AuditTest extends RestTest
protected RestAuditAppModel taggingRestAuditAppModel;
protected RestNodeModel node;
protected FileModel file;
protected SiteModel privateTestSite;
@BeforeClass(alwaysRun = true)
public void dataPreparation() throws Exception
@@ -54,6 +55,8 @@ public abstract class AuditTest extends RestTest
userModel = dataUser.createRandomTestUser();
userModel1 = dataUser.createRandomTestUser();
adminUser = dataUser.getAdminUser();
privateTestSite = dataSite.createPrivateRandomSite();
dataUser.addUserToSite(userModel, privateTestSite, UserRole.SiteCollaborator);
userModel.setUserRole(UserRole.SiteCollaborator);