From: <fwi...@us...> - 2009-09-09 17:28:42
|
Revision: 6776 http://jython.svn.sourceforge.net/jython/?rev=6776&view=rev Author: fwierzbicki Date: 2009-09-09 17:28:32 +0000 (Wed, 09 Sep 2009) Log Message: ----------- Add PyList testing for http://bugs.jython.org/issue1419, but it will also be a good place for testing the Java List interface of PyList in the future. Added Paths: ----------- trunk/jython/tests/java/org/python/core/PyListTest.java Added: trunk/jython/tests/java/org/python/core/PyListTest.java =================================================================== --- trunk/jython/tests/java/org/python/core/PyListTest.java (rev 0) +++ trunk/jython/tests/java/org/python/core/PyListTest.java 2009-09-09 17:28:32 UTC (rev 6776) @@ -0,0 +1,27 @@ +package org.python.core; + +import junit.framework.TestCase; + +/** + * Tests for PyList as Java List. + */ +public class PyListTest extends TestCase { + + @Override + protected void setUp() throws Exception { + } + + @Override + protected void tearDown() throws Exception { + } + + // Test for http://bugs.jython.org/issue1419 + // "Bug in PyTuple.indexOf and PyList.indexOf" + public void testFoo() { + PyList p = new PyList(); + p.add("foo"); + p.add("bar"); + assertEquals(0, p.indexOf("foo")); + assertEquals(1, p.indexOf("bar")); + } +} Property changes on: trunk/jython/tests/java/org/python/core/PyListTest.java ___________________________________________________________________ Added: svn:eol-style + native This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |