[CVS spice] Remove thinking tests now that we have stuff that works

proyal-yCVjj/[email protected] 25 Oct 2005 17:52:18 -0000
Newsgroups gmane.comp.java.spice.cvs
Message-ID <[email protected]>
<html>
<head>
<style><!--
  body {background-color:#ffffff;}
  .file {border:1px solid #eeeeee;margin-top:1em;margin-bottom:1em;}
  .pathname {font-family:monospace; float:right;}
  .fileheader {margin-bottom:.5em;}
  .diff {margin:0;}
  .tasklist {padding:4px;border:1px dashed #000000;margin-top:1em;}
  .tasklist ul {margin-top:0;margin-bottom:0;}
  tr.alt {background-color:#eeeeee}
  #added {background-color:#ddffdd;}
  #addedchars {background-color:#99ff99;font-weight:bolder;}
  tr.alt #added {background-color:#ccf7cc;}
  #removed {background-color:#ffdddd;}
  #removedchars {background-color:#ff9999;font-weight:bolder;}
  tr.alt #removed {background-color:#f7cccc;}
  #info {color:#888888;}
  #context {background-color:#eeeeee;}
  td {padding-left:.3em;padding-right:.3em;}
  tr.head {border-bottom-width:1px;border-bottom-style:solid;}
  tr.head td {padding:0;padding-top:.2em;}
  .task {background-color:#ffff00;}
  .comment {padding:4px;border:1px dashed #000000;background-color:#ffffdd}
  .error {color:red;}
  hr {border-width:0px;height:2px;background:black;}
--></style>
</head>
<body>
<table cellspacing="0" cellpadding="0" border="0" rules="cols">
<tr class="head"><td colspan="4">Commit in <b><tt>spice/components/jervlet/src/test/org/codehaus/spice/jervlet/impl/pico</tt></b><span id="info"> on MAIN</span></td></tr>
<tr><td><tt><a href="#file1"><span id="removed">AnotherTestCase.java</span></a></tt></td><td></td><td align="right" id="removed">-83</td><td nowrap="nowrap">1.6 removed</td></tr>
<tr class="alt"><td><tt><a href="#file2"><span id="removed">ThinkingOutLoudNanoJervletTestCase.groovy</span></a></tt></td><td></td><td align="right" id="removed">-28</td><td nowrap="nowrap">1.1 removed</td></tr>
<tr><td><tt><a href="#file3"><span id="removed">delegate.groovy</span></a></tt></td><td></td><td align="right" id="removed">-10</td><td nowrap="nowrap">1.2 removed</td></tr>
<tr><td></td><td></td><td align="right" id="removed">-121</td><td></td></tr>
</table>
<small id="info">3 removed files</small><br />
<pre class="comment">
Remove thinking tests now that we have stuff that works
</pre>
<hr /><a name="file1" /><div class="file">
<span class="pathname" id="removed">spice/components/jervlet/src/test/org/codehaus/spice/jervlet/impl/pico<br /></span>
<div class="fileheader" id="removed"><big><b>AnotherTestCase.java</b></big> <small id="info">removed after 1.6</small></div>
<pre class="diff"><small id="info">diff -N AnotherTestCase.java
--- AnotherTestCase.java	23 Sep 2005 01:22:09 -0000	1.6
+++ /dev/null	1 Jan 1970 00:00:00 -0000
@@ -1,83 +0,0 @@
</small></pre><pre class="diff" id="removed">-package org.codehaus.spice.jervlet.impl.pico;
-
-import groovy.lang.Binding;
-import groovy.lang.GroovyClassLoader;
-import groovy.lang.GroovyCodeSource;
-import groovy.lang.Script;
-import junit.framework.TestCase;
-import org.codehaus.groovy.control.CompilationFailedException;
-import org.codehaus.groovy.runtime.InvokerHelper;
-import org.codehaus.spice.jervlet.ContextHandler;
-import org.nanocontainer.script.groovy.GroovyContainerBuilder;
-import org.picocontainer.PicoContainer;
-import org.picocontainer.defaults.DefaultPicoContainer;
-import org.picocontainer.defaults.ObjectReference;
-import org.picocontainer.defaults.SimpleReference;
-
-import java.io.*;
-
-public class AnotherTestCase extends TestCase
-{
-    // This will not work because of http://jira.codehaus.org/browse/GROOVY-991
-    // when JSR-04 is released, try this test again.
-    public void doNot_testJervletNodeBuilderDecorationDelegate() throws Exception
-    {
-        InputStream script = getClass().getResourceAsStream( "delegate.groovy" );
-        PicoContainer pico = createContainer( new InputStreamReader( script ) );
-        assertNotNull("expected ContextHandler in picocontainer", pico.getComponentInstanceOfType( ContextHandler.class));
-    }
-
-    protected PicoContainer createContainer( Reader reader ) throws CompilationFailedException
-    {
-        ObjectReference containerRef = new SimpleReference();
-        ObjectReference parentContainerRef = new SimpleReference();
-        PicoContainer parent = new DefaultPicoContainer();
-        GroovyContainerBuilder builder = new GroovyContainerBuilder( reader, getClass().getClassLoader() );
-
-        parentContainerRef.set( parent );
-        builder.buildContainer( containerRef, parentContainerRef, "SOME_SCOPE", true );
-
-        return (PicoContainer)containerRef.get();
-    }
-
-    public void testContainerCanBeBuiltWithParent() throws CompilationFailedException
-    {
-        final Reader script = new StringReader(
-            "package org.codehaus.spice.jervlet.impl.pico\n" +
-            "import org.codehaus.spice.jervlet.impl.pico.NanoGroovyWebContainerBuilder\n"
-            +
-            "import org.picocontainer.defaults.DefaultPicoContainer\n" +
-            "def pc = new DefaultPicoContainer()\n" +
-            "pc.registerComponentInstance(String.class, 'Foo')\n" +
-            "def builder = new NanoGroovyWebContainerBuilder()\n" +
-            "def webServer = builder.picoEnabledWebServer(pico:pc, host:'localhost', port:8099) {\n" +
-            "    webApp(warPath:'foo/bar')\n" +
-            "    webApp {\n" +
-            "      servlet(context:'/foo', servletClass:'foo.bar.AServlet')\n" +
-            "    }\n" +
-            "}\n" +
-            "//webServer.start()\n");
-        doGroovy( new InputStream()
-        {
-            public int read() throws IOException
-            {
-                return script.read();
-            }
-        } );
-        assertEquals( "", "" );
-    }
-
-    protected void doGroovy( InputStream is ) throws CompilationFailedException
-    {
-        GroovyClassLoader loader = new GroovyClassLoader( getClass().getClassLoader() );
-
-        GroovyCodeSource groovyCodeSource = new GroovyCodeSource( is,
-                                                                  "nanocontainer.groovy",
-                                                                  "groovyGeneratedForNanoContainer" );
-        Class scriptClass = loader.parseClass( groovyCodeSource );
-        Script groovyScript = InvokerHelper.createScript( scriptClass, null );
-        Binding binding = new Binding();
-        groovyScript.setBinding( binding );
-        groovyScript.run();
-    }
-}
</pre></div>
<hr /><a name="file2" /><div class="file">
<span class="pathname" id="removed">spice/components/jervlet/src/test/org/codehaus/spice/jervlet/impl/pico<br /></span>
<div class="fileheader" id="removed"><big><b>ThinkingOutLoudNanoJervletTestCase.groovy</b></big> <small id="info">removed after 1.1</small></div>
<pre class="diff"><small id="info">diff -N ThinkingOutLoudNanoJervletTestCase.groovy
--- ThinkingOutLoudNanoJervletTestCase.groovy	27 Jul 2005 03:36:56 -0000	1.1
+++ /dev/null	1 Jan 1970 00:00:00 -0000
@@ -1,28 +0,0 @@
</small></pre><pre class="diff" id="removed">-package org.codehaus.spice.jervlet.impl.pico
-
-//import org.codehaus.spice.jervlet.impl.pico.NanoGroovyWebContainerBuilder
-//import org.picocontainer.defaults.DefaultPicoContainer
-
-class ThinkingOutLoudNanoJervletTestCase extends GroovyTestCase {
-
-    void testSomething() {
-
-//        pc = new DefaultPicoContainer()
-//        pc.registerComponentInstance(String.class, "Foo")
-
-//        builder = new NanoGroovyWebContainerBuilder()
-
-//        webServer = builder.picoEnabledWebServer(pico:pc, host:"localhost", port:8099) {
-//            webApp(warPath:"foo/bar")
-//            webApp {
-//              servlet(context:"/foo", servletClass:"foo.bar.AServlet")
-//            }
-//        }
-
-//        webServer.start()
-
-//        assertEquals("?","?")
-    }
-
-
-}
</pre><pre class="diff"><small id="info">\ No newline at end of file
</small></pre></div>
<hr /><a name="file3" /><div class="file">
<span class="pathname" id="removed">spice/components/jervlet/src/test/org/codehaus/spice/jervlet/impl/pico<br /></span>
<div class="fileheader" id="removed"><big><b>delegate.groovy</b></big> <small id="info">removed after 1.2</small></div>
<pre class="diff"><small id="info">diff -N delegate.groovy
--- delegate.groovy	8 Aug 2005 03:01:44 -0000	1.2
+++ /dev/null	1 Jan 1970 00:00:00 -0000
@@ -1,10 +0,0 @@
</small></pre><pre class="diff" id="removed">-package org.codehaus.spice.jervlet.impl.pico
-
-import org.nanocontainer.script.groovy.NanoContainerBuilder;
-
-builder = new NanoContainerBuilder( new JervletNanoContainerBuilderDecorationDelegate() );
-pico = builder.container {
-     webserver()
-     webapp( context : "foo/", warPath : "foo.war" )
-     component( StringBuffer )
-}
</pre><pre class="diff"><small id="info">\ No newline at end of file
</small></pre></div>
<center><small><a href="http://www.badgers-in-foil.co.uk/projects/cvsspam/" title="commit -&gt; email">CVSspam</a> 0.2.8</small></center>
</body></html>