Search in sources :

Example 51 with ByteChunk

use of org.apache.tomcat.util.buf.ByteChunk in project tomcat by apache.

the class TestELInJsp method testBug42565.

@Test
public void testBug42565() throws Exception {
    getTomcatInstanceTestWebapp(false, true);
    ByteChunk res = getUrl("http://localhost:" + getPort() + "/test/bug42565.jsp");
    String result = res.toString();
    assertEcho(result, "00-false");
    assertEcho(result, "01-false");
    assertEcho(result, "02-false");
    assertEcho(result, "03-false");
    assertEcho(result, "04-false");
    assertEcho(result, "05-false");
    assertEcho(result, "06-false");
    assertEcho(result, "07-false");
    assertEcho(result, "08-false");
    assertEcho(result, "09-false");
    assertEcho(result, "10-false");
    assertEcho(result, "11-false");
    assertEcho(result, "12-false");
    assertEcho(result, "13-false");
    assertEcho(result, "14-false");
    assertEcho(result, "15-false");
}
Also used : ByteChunk(org.apache.tomcat.util.buf.ByteChunk) TomcatBaseTest(org.apache.catalina.startup.TomcatBaseTest) Test(org.junit.Test)

Example 52 with ByteChunk

use of org.apache.tomcat.util.buf.ByteChunk in project tomcat by apache.

the class TestELInJsp method testBug44994.

@Test
public void testBug44994() throws Exception {
    getTomcatInstanceTestWebapp(false, true);
    ByteChunk res = getUrl("http://localhost:" + getPort() + "/test/bug44994.jsp");
    String result = res.toString();
    assertEcho(result, "00-none");
    assertEcho(result, "01-one");
    assertEcho(result, "02-many");
}
Also used : ByteChunk(org.apache.tomcat.util.buf.ByteChunk) TomcatBaseTest(org.apache.catalina.startup.TomcatBaseTest) Test(org.junit.Test)

Example 53 with ByteChunk

use of org.apache.tomcat.util.buf.ByteChunk in project tomcat by apache.

the class TestELInJsp method testBug48112.

@Test
public void testBug48112() throws Exception {
    getTomcatInstanceTestWebapp(false, true);
    ByteChunk res = getUrl("http://localhost:" + getPort() + "/test/bug48nnn/bug48112.jsp");
    String result = res.toString();
    assertEcho(result, "{OK}");
}
Also used : ByteChunk(org.apache.tomcat.util.buf.ByteChunk) TomcatBaseTest(org.apache.catalina.startup.TomcatBaseTest) Test(org.junit.Test)

Example 54 with ByteChunk

use of org.apache.tomcat.util.buf.ByteChunk in project tomcat by apache.

the class TestELInJsp method testBug47413.

@Test
public void testBug47413() throws Exception {
    getTomcatInstanceTestWebapp(false, true);
    ByteChunk res = getUrl("http://localhost:" + getPort() + "/test/bug47413.jsp");
    String result = res.toString();
    assertEcho(result, "00-hello world");
    assertEcho(result, "01-hello world");
    assertEcho(result, "02-3.22");
    assertEcho(result, "03-3.22");
    assertEcho(result, "04-17");
    assertEcho(result, "05-17");
    assertEcho(result, "06-hello world");
    assertEcho(result, "07-hello world");
    assertEcho(result, "08-0.0");
    assertEcho(result, "09-0.0");
    assertEcho(result, "10-0");
    assertEcho(result, "11-0");
}
Also used : ByteChunk(org.apache.tomcat.util.buf.ByteChunk) TomcatBaseTest(org.apache.catalina.startup.TomcatBaseTest) Test(org.junit.Test)

Example 55 with ByteChunk

use of org.apache.tomcat.util.buf.ByteChunk in project tomcat by apache.

the class TestELInJsp method testBug36923.

@Test
public void testBug36923() throws Exception {
    getTomcatInstanceTestWebapp(false, true);
    ByteChunk res = getUrl("http://localhost:" + getPort() + "/test/bug36923.jsp");
    String result = res.toString();
    assertEcho(result, "00-${hello world}");
}
Also used : ByteChunk(org.apache.tomcat.util.buf.ByteChunk) TomcatBaseTest(org.apache.catalina.startup.TomcatBaseTest) Test(org.junit.Test)

Aggregations

ByteChunk (org.apache.tomcat.util.buf.ByteChunk)274 Test (org.junit.Test)201 TomcatBaseTest (org.apache.catalina.startup.TomcatBaseTest)180 Tomcat (org.apache.catalina.startup.Tomcat)129 Context (org.apache.catalina.Context)98 File (java.io.File)49 List (java.util.List)48 AsyncContext (javax.servlet.AsyncContext)40 HashMap (java.util.HashMap)35 Wrapper (org.apache.catalina.Wrapper)22 StandardContext (org.apache.catalina.core.StandardContext)21 ArrayList (java.util.ArrayList)20 TesterContext (org.apache.tomcat.unittest.TesterContext)18 SecurityConstraint (org.apache.tomcat.util.descriptor.web.SecurityConstraint)16 ServletRequestWrapper (javax.servlet.ServletRequestWrapper)13 ServletResponseWrapper (javax.servlet.ServletResponseWrapper)13 ServletContext (javax.servlet.ServletContext)10 WsContextListener (org.apache.tomcat.websocket.server.WsContextListener)10 TesterAccessLogValve (org.apache.catalina.valves.TesterAccessLogValve)9 InitialContext (javax.naming.InitialContext)8