@@ -0,0 +1,3589 @@
+/*%0A * Licensed to the Apache Software Foundation (ASF) under one%0A * or more contributor license agreements.  See the NOTICE file%0A * distributed with this work for additional information%0A * regarding copyright ownership.  The ASF licenses this file%0A * to you under the Apache License, Version 2.0 (the%0A * %22License%22); you may not use this file except in compliance%0A * with the License.  You may obtain a copy of the License at%0A *  %0A *   http://www.apache.org/licenses/LICENSE-2.0%0A *  %0A *  Unless required by applicable law or agreed to in writing,%0A *  software distributed under the License is distributed on an%0A *  %22AS IS%22 BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY%0A *  KIND, either express or implied.  See the License for the%0A *  specific language governing permissions and limitations%0A *  under the License.%0A */%0Apackage org.apache.wink.server.internal.providers.entity;%0A%0Aimport java.util.logging.Handler;%0Aimport java.util.logging.Level;%0Aimport java.util.logging.Logger;%0A%0Aimport javax.ws.rs.POST;%0Aimport javax.ws.rs.Path;%0Aimport javax.ws.rs.core.MediaType;%0Aimport javax.xml.bind.annotation.XmlRootElement;%0A%0Aimport org.apache.wink.logging.InMemoryHandler;%0Aimport org.apache.wink.server.internal.servlet.MockServletInvocationTest;%0Aimport org.apache.wink.test.mock.MockRequestConstructor;%0Aimport org.springframework.mock.web.MockHttpServletRequest;%0Aimport org.springframework.mock.web.MockHttpServletResponse;%0A%0Apublic class JAXBNoEntityLogTest extends MockServletInvocationTest %7B%0A%0A    @Override%0A    protected Class%3C?%3E%5B%5D getClasses() %7B%0A        return new Class%3C?%3E%5B%5D %7BMyResource1.class%7D;%0A    %7D%0A%0A    @XmlRootElement%0A    public static class Book %7B%0A%0A        private String name;%0A%0A        public String getName() %7B%0A            return name;%0A        %7D%0A%0A        public void setName(String s) %7B%0A            name = s;%0A        %7D%0A    %7D%0A%0A    @Path(%22res1%22)%0A    public static class MyResource1 %7B%0A%0A        @POST%0A        public Book get(Book b) %7B%0A            return b;%0A        %7D%0A%0A    %7D%0A%0A    private InMemoryHandler handler;%0A%0A    private Logger          winkLogger = Logger.getLogger(%22org.apache.wink%22);%0A%0A    private Handler         consoleHandler;%0A%0A    @Override%0A    protected void setUp() throws Exception %7B%0A        super.setUp();%0A%0A        Handler%5B%5D defaultHandlers = Logger.getLogger(%22%22).getHandlers();%0A        if (defaultHandlers.length == 1) %7B%0A            consoleHandler = defaultHandlers%5B0%5D;%0A            consoleHandler.setLevel(Level.FINE);%0A        %7D%0A%0A        handler = new InMemoryHandler();%0A        handler.setLevel(Level.INFO);%0A%0A        winkLogger.setLevel(Level.INFO);%0A        winkLogger.addHandler(handler);%0A    %7D%0A%0A    @Override%0A    protected void tearDown() throws Exception %7B%0A        if (consoleHandler != null) %7B%0A            consoleHandler.setLevel(Level.INFO);%0A        %7D%0A        winkLogger.removeHandler(handler);%0A        winkLogger.setLevel(Level.INFO);%0A        super.tearDown();%0A    %7D%0A%0A    /**%0A     * Tests that a Provider is logged at the debug level.%0A     */%0A    public void testNoEntityRefLog() throws Exception %7B%0A        MockHttpServletRequest request =%0A            MockRequestConstructor.constructMockRequest(%22POST%22,%0A                                                        %22res1%22,%0A                                                        MediaType.WILDCARD,%0A                                                        MediaType.APPLICATION_XML,%0A                                                        %22%22.getBytes());%0A        MockHttpServletResponse response = invoke(request);%0A        assertEquals(400, response.getStatus());%0A%0A        assertEquals(0, handler.getRecords().size());%0A    %7D%0A%7D%0A

Add JAXB logging test