Search in sources :

Example 36 with LongParam

use of io.dropwizard.jersey.params.LongParam in project keywhiz by square.

the class MembershipResourceTest method missingSecretAllow.

@Test(expected = NotFoundException.class)
public void missingSecretAllow() {
    doThrow(IllegalStateException.class).when(aclDAO).findAndAllowAccess(3, group.getId(), auditLog, "user", new HashMap<>());
    resource.allowAccess(user, new LongParam("3"), new LongParam(Long.toString(group.getId())));
}
Also used : LongParam(io.dropwizard.jersey.params.LongParam) Test(org.junit.Test)

Aggregations

LongParam (io.dropwizard.jersey.params.LongParam)36 Test (org.junit.Test)34 Response (javax.ws.rs.core.Response)11 SecretDetailResponse (keywhiz.api.SecretDetailResponse)8 ClientDetailResponse (keywhiz.api.ClientDetailResponse)4 Group (keywhiz.api.model.Group)4 GraphHopper (com.graphhopper.GraphHopper)2 Profile (com.graphhopper.config.Profile)2 GHPointParam (com.graphhopper.http.GHPointParam)2 ShortestPathTree (com.graphhopper.isochrone.algorithm.ShortestPathTree)2 RouteResource.errorIfLegacyParameters (com.graphhopper.resources.RouteResource.errorIfLegacyParameters)2 RouteResource.removeLegacyParameters (com.graphhopper.resources.RouteResource.removeLegacyParameters)2 ProfileResolver (com.graphhopper.routing.ProfileResolver)2 QueryGraph (com.graphhopper.routing.querygraph.QueryGraph)2 DefaultSnapFilter (com.graphhopper.routing.util.DefaultSnapFilter)2 FiniteWeightFilter (com.graphhopper.routing.util.FiniteWeightFilter)2 TraversalMode (com.graphhopper.routing.util.TraversalMode)2 EDGE_BASED (com.graphhopper.routing.util.TraversalMode.EDGE_BASED)2 NODE_BASED (com.graphhopper.routing.util.TraversalMode.NODE_BASED)2 BlockAreaWeighting (com.graphhopper.routing.weighting.BlockAreaWeighting)2