Commit e349dbd3 authored by Matija Obreza's avatar Matija Obreza

Make asciidocs run before packaging (after tests)

parent 33b371f6
...@@ -672,7 +672,7 @@ ...@@ -672,7 +672,7 @@
<executions> <executions>
<execution> <execution>
<id>output-html</id> <id>output-html</id>
<phase>generate-resources</phase> <phase>prepare-package</phase>
<goals> <goals>
<goal>process-asciidoc</goal> <goal>process-asciidoc</goal>
</goals> </goals>
......
/*
* Copyright 2016 Global Crop Diversity Trust
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.genesys2.tests.resttests; package org.genesys2.tests.resttests;
import com.fasterxml.jackson.databind.DeserializationFeature;
import com.fasterxml.jackson.databind.SerializationFeature;
import com.hazelcast.core.HazelcastInstance; import com.hazelcast.core.HazelcastInstance;
import com.hazelcast.core.IQueue; import com.hazelcast.core.IQueue;
import org.apache.http.impl.client.HttpClientBuilder; import org.apache.http.impl.client.HttpClientBuilder;
import org.apache.velocity.app.VelocityEngine; import org.apache.velocity.app.VelocityEngine;
import org.genesys2.server.aspect.AsAdminAspect; import org.genesys2.server.aspect.AsAdminAspect;
...@@ -40,9 +59,6 @@ import org.genesys2.server.persistence.domain.UserPersistence; ...@@ -40,9 +59,6 @@ import org.genesys2.server.persistence.domain.UserPersistence;
import org.genesys2.server.persistence.domain.kpi.KPIParameterRepository; import org.genesys2.server.persistence.domain.kpi.KPIParameterRepository;
import org.genesys2.server.persistence.domain.kpi.ObservationRepository; import org.genesys2.server.persistence.domain.kpi.ObservationRepository;
import org.genesys2.server.persistence.domain.mock.TraitServiceMock; import org.genesys2.server.persistence.domain.mock.TraitServiceMock;
import org.genesys2.server.service.worker.ElasticUpdater;
import org.genesys2.server.service.ElasticSearchManagementService;
import org.genesys2.server.service.impl.ElasticSearchManagementServiceImpl;
import org.genesys2.server.service.AclService; import org.genesys2.server.service.AclService;
import org.genesys2.server.service.BatchRESTService; import org.genesys2.server.service.BatchRESTService;
import org.genesys2.server.service.ContentService; import org.genesys2.server.service.ContentService;
...@@ -51,6 +67,7 @@ import org.genesys2.server.service.DatasetService; ...@@ -51,6 +67,7 @@ import org.genesys2.server.service.DatasetService;
import org.genesys2.server.service.EMailService; import org.genesys2.server.service.EMailService;
import org.genesys2.server.service.EMailVerificationService; import org.genesys2.server.service.EMailVerificationService;
import org.genesys2.server.service.EasySMTA; import org.genesys2.server.service.EasySMTA;
import org.genesys2.server.service.ElasticSearchManagementService;
import org.genesys2.server.service.ElasticService; import org.genesys2.server.service.ElasticService;
import org.genesys2.server.service.GenesysFilterService; import org.genesys2.server.service.GenesysFilterService;
import org.genesys2.server.service.GenesysRESTService; import org.genesys2.server.service.GenesysRESTService;
...@@ -77,6 +94,7 @@ import org.genesys2.server.service.impl.CropServiceImpl; ...@@ -77,6 +94,7 @@ import org.genesys2.server.service.impl.CropServiceImpl;
import org.genesys2.server.service.impl.EMailServiceImpl; import org.genesys2.server.service.impl.EMailServiceImpl;
import org.genesys2.server.service.impl.EMailVerificationServiceImpl; import org.genesys2.server.service.impl.EMailVerificationServiceImpl;
import org.genesys2.server.service.impl.EasySMTAMockConnector; import org.genesys2.server.service.impl.EasySMTAMockConnector;
import org.genesys2.server.service.impl.ElasticSearchManagementServiceImpl;
import org.genesys2.server.service.impl.ElasticsearchSearchServiceImpl; import org.genesys2.server.service.impl.ElasticsearchSearchServiceImpl;
import org.genesys2.server.service.impl.FilterHandler; import org.genesys2.server.service.impl.FilterHandler;
import org.genesys2.server.service.impl.GenesysFilterServiceImpl; import org.genesys2.server.service.impl.GenesysFilterServiceImpl;
...@@ -97,6 +115,7 @@ import org.genesys2.server.service.impl.TaxonomyServiceImpl; ...@@ -97,6 +115,7 @@ import org.genesys2.server.service.impl.TaxonomyServiceImpl;
import org.genesys2.server.service.impl.TeamServiceImpl; import org.genesys2.server.service.impl.TeamServiceImpl;
import org.genesys2.server.service.impl.TokenVerificationServiceImpl; import org.genesys2.server.service.impl.TokenVerificationServiceImpl;
import org.genesys2.server.service.impl.UserServiceImpl; import org.genesys2.server.service.impl.UserServiceImpl;
import org.genesys2.server.service.worker.ElasticUpdater;
import org.genesys2.server.servlet.controller.rest.AccessionController; import org.genesys2.server.servlet.controller.rest.AccessionController;
import org.genesys2.server.servlet.controller.rest.CacheController; import org.genesys2.server.servlet.controller.rest.CacheController;
import org.genesys2.server.servlet.controller.rest.CropsController; import org.genesys2.server.servlet.controller.rest.CropsController;
...@@ -137,9 +156,6 @@ import org.springframework.test.context.junit4.SpringJUnit4ClassRunner; ...@@ -137,9 +156,6 @@ import org.springframework.test.context.junit4.SpringJUnit4ClassRunner;
import org.springframework.test.context.web.WebAppConfiguration; import org.springframework.test.context.web.WebAppConfiguration;
import org.springframework.web.servlet.config.annotation.EnableWebMvc; import org.springframework.web.servlet.config.annotation.EnableWebMvc;
import com.fasterxml.jackson.databind.DeserializationFeature;
import com.fasterxml.jackson.databind.SerializationFeature;
@RunWith(SpringJUnit4ClassRunner.class) @RunWith(SpringJUnit4ClassRunner.class)
@ContextHierarchy(@ContextConfiguration(name = "this", classes = { ElasticsearchConfig.class, AbstractRestTest.Config.class }, initializers = PropertyPlacholderInitializer.class)) @ContextHierarchy(@ContextConfiguration(name = "this", classes = { ElasticsearchConfig.class, AbstractRestTest.Config.class }, initializers = PropertyPlacholderInitializer.class))
@ActiveProfiles("dev") @ActiveProfiles("dev")
......
/*
* Copyright 2016 Global Crop Diversity Trust
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.genesys2.tests.resttests; package org.genesys2.tests.resttests;
import static org.hamcrest.Matchers.greaterThan; import static org.hamcrest.Matchers.*;
import static org.hamcrest.Matchers.hasSize; import static org.springframework.test.web.servlet.request.MockMvcRequestBuilders.*;
import static org.hamcrest.Matchers.is; import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.*;
import static org.hamcrest.Matchers.notNullValue;
import static org.springframework.test.web.servlet.request.MockMvcRequestBuilders.get;
import static org.springframework.test.web.servlet.request.MockMvcRequestBuilders.post;
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.content;
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.jsonPath;
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.status;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.HashMap; import java.util.HashMap;
...@@ -16,6 +26,10 @@ import java.util.HashSet; ...@@ -16,6 +26,10 @@ import java.util.HashSet;
import java.util.List; import java.util.List;
import java.util.Map; import java.util.Map;
import com.fasterxml.jackson.core.JsonProcessingException;
import com.fasterxml.jackson.databind.JsonNode;
import com.fasterxml.jackson.databind.ObjectMapper;
import org.apache.commons.logging.Log; import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory; import org.apache.commons.logging.LogFactory;
import org.genesys2.server.exception.UserException; import org.genesys2.server.exception.UserException;
...@@ -58,10 +72,6 @@ import org.springframework.test.web.servlet.MockMvc; ...@@ -58,10 +72,6 @@ import org.springframework.test.web.servlet.MockMvc;
import org.springframework.test.web.servlet.setup.MockMvcBuilders; import org.springframework.test.web.servlet.setup.MockMvcBuilders;
import org.springframework.web.context.WebApplicationContext; import org.springframework.web.context.WebApplicationContext;
import com.fasterxml.jackson.core.JsonProcessingException;
import com.fasterxml.jackson.databind.JsonNode;
import com.fasterxml.jackson.databind.ObjectMapper;
@Ignore @Ignore
public class AccessionControllerTest extends AbstractRestTest { public class AccessionControllerTest extends AbstractRestTest {
......
package org.genesys2.tests.resttests; package org.genesys2.tests.resttests;
import static org.hamcrest.Matchers.greaterThan; import static org.hamcrest.Matchers.*;
import static org.hamcrest.Matchers.hasSize; import static org.springframework.test.web.servlet.request.MockMvcRequestBuilders.*;
import static org.springframework.test.web.servlet.request.MockMvcRequestBuilders.get; import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.*;
import static org.springframework.test.web.servlet.request.MockMvcRequestBuilders.post;
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.content; import com.fasterxml.jackson.databind.JsonNode;
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.jsonPath; import com.fasterxml.jackson.databind.ObjectMapper;
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.status;
import org.apache.commons.logging.Log; import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory; import org.apache.commons.logging.LogFactory;
...@@ -20,9 +19,6 @@ import org.springframework.test.web.servlet.MockMvc; ...@@ -20,9 +19,6 @@ import org.springframework.test.web.servlet.MockMvc;
import org.springframework.test.web.servlet.setup.MockMvcBuilders; import org.springframework.test.web.servlet.setup.MockMvcBuilders;
import org.springframework.web.context.WebApplicationContext; import org.springframework.web.context.WebApplicationContext;
import com.fasterxml.jackson.databind.JsonNode;
import com.fasterxml.jackson.databind.ObjectMapper;
@EnableCaching @EnableCaching
public class CacheControllerTest extends AbstractRestTest { public class CacheControllerTest extends AbstractRestTest {
......
...@@ -10,6 +10,12 @@ import static org.springframework.test.web.servlet.result.MockMvcResultMatchers. ...@@ -10,6 +10,12 @@ import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.
import java.util.ArrayList; import java.util.ArrayList;
import java.util.List; import java.util.List;
import com.fasterxml.jackson.annotation.JsonInclude.Include;
import com.fasterxml.jackson.databind.DeserializationFeature;
import com.fasterxml.jackson.databind.JsonNode;
import com.fasterxml.jackson.databind.ObjectMapper;
import com.fasterxml.jackson.databind.SerializationFeature;
import org.apache.commons.logging.Log; import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory; import org.apache.commons.logging.LogFactory;
import org.genesys2.server.model.impl.Crop; import org.genesys2.server.model.impl.Crop;
...@@ -23,19 +29,11 @@ import org.springframework.beans.factory.annotation.Autowired; ...@@ -23,19 +29,11 @@ import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.http.MediaType; import org.springframework.http.MediaType;
import org.springframework.restdocs.RestDocumentation; import org.springframework.restdocs.RestDocumentation;
import org.springframework.restdocs.payload.JsonFieldType; import org.springframework.restdocs.payload.JsonFieldType;
import org.springframework.test.annotation.Commit;
import org.springframework.test.annotation.Rollback;
import org.springframework.test.web.servlet.MockMvc; import org.springframework.test.web.servlet.MockMvc;
import org.springframework.test.web.servlet.setup.MockMvcBuilders; import org.springframework.test.web.servlet.setup.MockMvcBuilders;
import org.springframework.transaction.annotation.Transactional; import org.springframework.transaction.annotation.Transactional;
import org.springframework.web.context.WebApplicationContext; import org.springframework.web.context.WebApplicationContext;
import com.fasterxml.jackson.annotation.JsonInclude.Include;
import com.fasterxml.jackson.databind.DeserializationFeature;
import com.fasterxml.jackson.databind.JsonNode;
import com.fasterxml.jackson.databind.ObjectMapper;
import com.fasterxml.jackson.databind.SerializationFeature;
@Transactional(transactionManager = "transactionManager") @Transactional(transactionManager = "transactionManager")
public class CropsControllerTest extends AbstractRestTest { public class CropsControllerTest extends AbstractRestTest {
......
...@@ -10,6 +10,9 @@ import java.util.HashSet; ...@@ -10,6 +10,9 @@ import java.util.HashSet;
import java.util.List; import java.util.List;
import java.util.Map; import java.util.Map;
import com.fasterxml.jackson.core.JsonProcessingException;
import com.fasterxml.jackson.databind.ObjectMapper;
import org.apache.commons.logging.Log; import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory; import org.apache.commons.logging.LogFactory;
import org.genesys2.server.exception.UserException; import org.genesys2.server.exception.UserException;
...@@ -50,9 +53,6 @@ import org.springframework.test.web.servlet.MockMvc; ...@@ -50,9 +53,6 @@ import org.springframework.test.web.servlet.MockMvc;
import org.springframework.test.web.servlet.setup.MockMvcBuilders; import org.springframework.test.web.servlet.setup.MockMvcBuilders;
import org.springframework.web.context.WebApplicationContext; import org.springframework.web.context.WebApplicationContext;
import com.fasterxml.jackson.core.JsonProcessingException;
import com.fasterxml.jackson.databind.ObjectMapper;
@Ignore @Ignore
public class DatasetControllerTest extends AbstractRestTest { public class DatasetControllerTest extends AbstractRestTest {
......
package org.genesys2.tests.resttests; package org.genesys2.tests.resttests;
import static org.hamcrest.Matchers.hasSize; import static org.hamcrest.Matchers.*;
import static org.hamcrest.Matchers.is; import static org.springframework.test.web.servlet.request.MockMvcRequestBuilders.*;
import static org.hamcrest.Matchers.isEmptyOrNullString; import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.*;
import static org.hamcrest.Matchers.notNullValue;
import static org.hamcrest.Matchers.nullValue;
import static org.springframework.test.web.servlet.request.MockMvcRequestBuilders.delete;
import static org.springframework.test.web.servlet.request.MockMvcRequestBuilders.get;
import static org.springframework.test.web.servlet.request.MockMvcRequestBuilders.post;
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.content;
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.jsonPath;
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.status;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.Date; import java.util.Date;
...@@ -18,6 +10,8 @@ import java.util.HashSet; ...@@ -18,6 +10,8 @@ import java.util.HashSet;
import java.util.List; import java.util.List;
import java.util.Set; import java.util.Set;
import com.fasterxml.jackson.databind.ObjectMapper;
import org.apache.commons.logging.Log; import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory; import org.apache.commons.logging.LogFactory;
import org.genesys2.server.model.kpi.BooleanDimension; import org.genesys2.server.model.kpi.BooleanDimension;
...@@ -38,8 +32,6 @@ import org.springframework.test.web.servlet.MockMvc; ...@@ -38,8 +32,6 @@ import org.springframework.test.web.servlet.MockMvc;
import org.springframework.test.web.servlet.setup.MockMvcBuilders; import org.springframework.test.web.servlet.setup.MockMvcBuilders;
import org.springframework.web.context.WebApplicationContext; import org.springframework.web.context.WebApplicationContext;
import com.fasterxml.jackson.databind.ObjectMapper;
// FIXME tearDown() method not using @Transactional // FIXME tearDown() method not using @Transactional
@Ignore @Ignore
public class KPIControllerTest extends AbstractRestTest { public class KPIControllerTest extends AbstractRestTest {
......
package org.genesys2.tests.resttests; package org.genesys2.tests.resttests;
import static org.springframework.test.web.servlet.request.MockMvcRequestBuilders.get; import static org.springframework.test.web.servlet.request.MockMvcRequestBuilders.*;
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.content; import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.*;
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.status;
import java.util.HashMap; import java.util.HashMap;
import java.util.Map; import java.util.Map;
import com.fasterxml.jackson.databind.ObjectMapper;
import org.apache.commons.logging.Log; import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory; import org.apache.commons.logging.LogFactory;
import org.genesys2.server.exception.UserException; import org.genesys2.server.exception.UserException;
...@@ -21,8 +22,6 @@ import org.springframework.test.web.servlet.MockMvc; ...@@ -21,8 +22,6 @@ import org.springframework.test.web.servlet.MockMvc;
import org.springframework.test.web.servlet.setup.MockMvcBuilders; import org.springframework.test.web.servlet.setup.MockMvcBuilders;
import org.springframework.web.context.WebApplicationContext; import org.springframework.web.context.WebApplicationContext;
import com.fasterxml.jackson.databind.ObjectMapper;
public class LookupControllerTest extends AbstractRestTest { public class LookupControllerTest extends AbstractRestTest {
private static final Log LOG = LogFactory.getLog(LookupControllerTest.class); private static final Log LOG = LogFactory.getLog(LookupControllerTest.class);
......
package org.genesys2.tests.resttests; package org.genesys2.tests.resttests;
import static org.hamcrest.Matchers.hasSize; import static org.hamcrest.Matchers.*;
import static org.hamcrest.Matchers.is; import static org.springframework.test.web.servlet.request.MockMvcRequestBuilders.*;
import static org.springframework.test.web.servlet.request.MockMvcRequestBuilders.delete; import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.*;
import static org.springframework.test.web.servlet.request.MockMvcRequestBuilders.get;
import static org.springframework.test.web.servlet.request.MockMvcRequestBuilders.post;
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.content;
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.jsonPath;
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.status;
import java.nio.charset.Charset; import java.nio.charset.Charset;
import java.util.ArrayList; import java.util.ArrayList;
...@@ -16,6 +11,9 @@ import java.util.HashSet; ...@@ -16,6 +11,9 @@ import java.util.HashSet;
import java.util.List; import java.util.List;
import java.util.Map; import java.util.Map;
import com.fasterxml.jackson.databind.JsonNode;
import com.fasterxml.jackson.databind.ObjectMapper;
import org.apache.commons.logging.Log; import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory; import org.apache.commons.logging.LogFactory;
import org.genesys2.server.exception.UserException; import org.genesys2.server.exception.UserException;
...@@ -46,9 +44,6 @@ import org.springframework.test.web.servlet.setup.MockMvcBuilders; ...@@ -46,9 +44,6 @@ import org.springframework.test.web.servlet.setup.MockMvcBuilders;
import org.springframework.transaction.annotation.Transactional; import org.springframework.transaction.annotation.Transactional;
import org.springframework.web.context.WebApplicationContext; import org.springframework.web.context.WebApplicationContext;
import com.fasterxml.jackson.databind.JsonNode;
import com.fasterxml.jackson.databind.ObjectMapper;
@Ignore @Ignore
public class OAuthManagementControllerTest extends AbstractRestTest { public class OAuthManagementControllerTest extends AbstractRestTest {
......
package org.genesys2.tests.resttests; package org.genesys2.tests.resttests;
import static org.springframework.test.web.servlet.request.MockMvcRequestBuilders.delete; import static org.springframework.test.web.servlet.request.MockMvcRequestBuilders.*;
import static org.springframework.test.web.servlet.request.MockMvcRequestBuilders.get; import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.*;
import static org.springframework.test.web.servlet.request.MockMvcRequestBuilders.post;
import static org.springframework.test.web.servlet.request.MockMvcRequestBuilders.put;
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.content;
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.status;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.List; import java.util.List;
import com.fasterxml.jackson.databind.ObjectMapper;
import org.apache.commons.logging.Log; import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory; import org.apache.commons.logging.LogFactory;
import org.genesys2.server.model.impl.Article; import org.genesys2.server.model.impl.Article;
...@@ -27,8 +25,6 @@ import org.springframework.test.web.servlet.setup.MockMvcBuilders; ...@@ -27,8 +25,6 @@ import org.springframework.test.web.servlet.setup.MockMvcBuilders;
import org.springframework.transaction.annotation.Transactional; import org.springframework.transaction.annotation.Transactional;
import org.springframework.web.context.WebApplicationContext; import org.springframework.web.context.WebApplicationContext;
import com.fasterxml.jackson.databind.ObjectMapper;
public class OrganizationControllerTest extends AbstractRestTest { public class OrganizationControllerTest extends AbstractRestTest {
private static final Log LOG = LogFactory.getLog(OrganizationControllerTest.class); private static final Log LOG = LogFactory.getLog(OrganizationControllerTest.class);
......
package org.genesys2.tests.resttests; package org.genesys2.tests.resttests;
import static org.springframework.test.web.servlet.request.MockMvcRequestBuilders.get; import static org.springframework.test.web.servlet.request.MockMvcRequestBuilders.*;
import static org.springframework.test.web.servlet.request.MockMvcRequestBuilders.post; import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.*;
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.content;
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.status;
import java.io.IOException; import java.io.IOException;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.List; import java.util.List;
import com.fasterxml.jackson.databind.JsonNode;
import com.fasterxml.jackson.databind.ObjectMapper;
import org.apache.commons.logging.Log; import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory; import org.apache.commons.logging.LogFactory;
import org.genesys2.server.exception.UserException; import org.genesys2.server.exception.UserException;
...@@ -27,9 +28,6 @@ import org.springframework.test.web.servlet.MockMvc; ...@@ -27,9 +28,6 @@ import org.springframework.test.web.servlet.MockMvc;
import org.springframework.test.web.servlet.setup.MockMvcBuilders; import org.springframework.test.web.servlet.setup.MockMvcBuilders;
import org.springframework.web.context.WebApplicationContext; import org.springframework.web.context.WebApplicationContext;
import com.fasterxml.jackson.databind.JsonNode;
import com.fasterxml.jackson.databind.ObjectMapper;
// FIXME No permissions // FIXME No permissions
@Ignore @Ignore
public class PermissionControllerTest extends AbstractRestTest { public class PermissionControllerTest extends AbstractRestTest {
......
package org.genesys2.tests.resttests; package org.genesys2.tests.resttests;
import static org.springframework.test.web.servlet.request.MockMvcRequestBuilders.get; import static org.springframework.test.web.servlet.request.MockMvcRequestBuilders.*;
import static org.springframework.test.web.servlet.request.MockMvcRequestBuilders.post; import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.*;
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.content;
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.status;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.HashSet; import java.util.HashSet;
import java.util.List; import java.util.List;
import java.util.Set; import java.util.Set;
import com.fasterxml.jackson.core.JsonProcessingException;
import com.fasterxml.jackson.databind.ObjectMapper;
import org.apache.commons.logging.Log; import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory; import org.apache.commons.logging.LogFactory;
import org.genesys2.server.exception.UserException; import org.genesys2.server.exception.UserException;
...@@ -34,9 +35,6 @@ import org.springframework.test.web.servlet.setup.MockMvcBuilders; ...@@ -34,9 +35,6 @@ import org.springframework.test.web.servlet.setup.MockMvcBuilders;
import org.springframework.transaction.annotation.Transactional; import org.springframework.transaction.annotation.Transactional;
import org.springframework.web.context.WebApplicationContext; import org.springframework.web.context.WebApplicationContext;
import com.fasterxml.jackson.core.JsonProcessingException;
import com.fasterxml.jackson.databind.ObjectMapper;
@Transactional @Transactional
@Ignore @Ignore
public class RequestsControllerTest extends AbstractRestTest { public class RequestsControllerTest extends AbstractRestTest {
......
package org.genesys2.tests.resttests; package org.genesys2.tests.resttests;
import static org.hamcrest.Matchers.hasSize; import static org.hamcrest.Matchers.*;
import static org.hamcrest.Matchers.is; import static org.springframework.test.web.servlet.request.MockMvcRequestBuilders.*;
import static org.hamcrest.Matchers.isEmptyOrNullString; import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.*;
import static org.hamcrest.Matchers.isEmptyString;
import static org.hamcrest.Matchers.not;
import static org.springframework.test.web.servlet.request.MockMvcRequestBuilders.delete;
import static org.springframework.test.web.servlet.request.MockMvcRequestBuilders.get;
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.content;
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.jsonPath;
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.status;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.HashMap; import java.util.HashMap;
import java.util.HashSet; import java.util.HashSet;
import java.util.List; import java.util.List;
import com.fasterxml.jackson.databind.ObjectMapper;
import org.apache.commons.logging.Log; import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory; import org.apache.commons.logging.LogFactory;
import org.genesys2.server.exception.UserException; import org.genesys2.server.exception.UserException;
...@@ -42,8 +37,6 @@ import org.springframework.test.web.servlet.MockMvc; ...@@ -42,8 +37,6 @@ import org.springframework.test.web.servlet.MockMvc;
import org.springframework.test.web.servlet.setup.MockMvcBuilders; import org.springframework.test.web.servlet.setup.MockMvcBuilders;
import org.springframework.web.context.WebApplicationContext; import org.springframework.web.context.WebApplicationContext;
import com.fasterxml.jackson.databind.ObjectMapper;