@@ -0,0 +1,1371 @@
+/*%0A * Cloud Foundry 2012.02.03 Beta%0A * Copyright (c) %5B2009-2012%5D VMware, Inc. All Rights Reserved.%0A *%0A * This product is licensed to you under the Apache License, Version 2.0 (the %22License%22).%0A * You may not use this product except in compliance with the License.%0A *%0A * This product includes a number of subcomponents with%0A * separate copyright notices and license terms. Your use of these%0A * subcomponents is subject to the terms and conditions of the%0A * subcomponent's license, as noted in the LICENSE file.%0A */%0A%0Apackage org.springframework.security.oauth2.provider.code;%0A%0Aimport static org.junit.Assert.assertEquals;%0A%0Aimport java.util.Arrays;%0A%0Aimport org.junit.Test;%0Aimport org.springframework.security.authentication.UsernamePasswordAuthenticationToken;%0Aimport org.springframework.security.oauth2.common.util.SerializationUtils;%0Aimport org.springframework.security.oauth2.provider.DefaultAuthorizationRequest;%0A%0A/**%0A * @author Dave Syer%0A * %0A */%0Apublic class TestAuthorizationRequestHolder %7B%0A%0A%09private AuthorizationRequestHolder holder = new AuthorizationRequestHolder(new DefaultAuthorizationRequest(%0A%09%09%09%22client%22, Arrays.asList(%22read%22)), new UsernamePasswordAuthenticationToken(%22user%22, %22pwd%22));%0A%0A%09@Test%0A%09public void test() %7B%0A%09%09AuthorizationRequestHolder other = SerializationUtils.deserialize(SerializationUtils.serialize(holder));%0A%09%09assertEquals(holder, other);%0A%09%7D%0A%0A%7D%0A

add serialization test