/*
 * The Gemma project
 * 
 * Copyright (c) 2006 University of British Columbia
 * 
 * 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 ubic.gemma.web.controller.expression.experiment;

import static org.junit.Assert.assertEquals;

import org.junit.Test;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.mock.web.MockHttpServletRequest;
import org.springframework.mock.web.MockHttpServletResponse;
import org.springframework.web.servlet.ModelAndView;

import ubic.gemma.testing.BaseSpringWebTest;

/**
 * @author pavlidis
 * @version $Id$
 */
public class ExpressionExperimentLoadControllerTest extends BaseSpringWebTest {

    @Autowired
    private ExpressionExperimentLoadController controller;

    @Override
    public MockHttpServletRequest newGet( String url ) {
        return new MockHttpServletRequest( "GET", url );
    }

    @Override
    public MockHttpServletRequest newPost( String url ) {
        return new MockHttpServletRequest( "POST", url );
    }

    @Test
    public final void testShowForm() throws Exception {
        MockHttpServletResponse response = new MockHttpServletResponse();
        MockHttpServletRequest request = newGet( "/loadExpressionExperiment.html" );

        ModelAndView mv = controller.handleRequest( request, response );
        assertEquals( "Returned incorrect view name", "loadExpressionExperimentForm", mv.getViewName() );

    }

}
@@ -1258,280 +1258,8 @@
 r;%0A%0A
-    @Override%0A    public MockHttpServletRequest newGet( String url ) %7B%0A        return new MockHttpServletRequest( %22GET%22, url );%0A    %7D%0A%0A    @Override%0A    public MockHttpServletRequest newPost( String url ) %7B%0A        return new MockHttpServletRequest( %22POST%22, url );%0A    %7D%0A%0A
     
@@ -1264,16 +1264,16 @@
   @Test%0A
+
     publ
@@ -1394,16 +1394,16 @@
 onse();%0A
-
         
@@ -1445,16 +1445,22 @@
 wGet( %22/
+admin/
 loadExpr

fix test