@@ -0,0 +1,765 @@
+package ca.corefacility.bioinformatics.irida.web.controller.test.integration.security;%0A%0Aimport static com.jayway.restassured.RestAssured.expect;%0Aimport static org.hamcrest.CoreMatchers.containsString;%0Aimport static org.hamcrest.CoreMatchers.is;%0A%0Aimport org.apache.http.HttpStatus;%0Aimport org.junit.Test;%0A%0A/**%0A * General tests relating to security for the REST API.%0A * %0A */%0Apublic class SecurityIT %7B%0A%0A%09/**%0A%09 * Test that we get the right type of response when we don't have valid%0A%09 * credentials.%0A%09 */%0A%09@Test%0A%09public void testAccessWithoutAuthentication() %7B%0A%09%09expect().body(%22error%22, is(%22invalid_request%22)).and()%0A%09%09%09%09.body(%22error_description%22, containsString(%22No client credentials were provided%22))%0A%09%09%09%09.statusCode(HttpStatus.SC_UNAUTHORIZED).when().get(%22/api%22);%0A%09%7D%0A%7D%0A

Add a test to verify that we're getting the customized error message when accessing the rest api without credentials.