From 48e40e17a6d5f2309d53637e09a9556e74d35c05 Mon Sep 17 00:00:00 2001 From: Tom Copeland Date: Wed, 31 Jul 2002 16:26:13 +0000 Subject: [PATCH] *** empty log message *** git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@569 51baf565-9d33-0410-a72c-fc3788e3496d --- .../sourceforge/pmd/cpd/OccurrenceTest.java | 23 +++++++++++++++++++ 1 file changed, 23 insertions(+) create mode 100644 pmd/regress/test/net/sourceforge/pmd/cpd/OccurrenceTest.java diff --git a/pmd/regress/test/net/sourceforge/pmd/cpd/OccurrenceTest.java b/pmd/regress/test/net/sourceforge/pmd/cpd/OccurrenceTest.java new file mode 100644 index 0000000000..5f8dcc0d7f --- /dev/null +++ b/pmd/regress/test/net/sourceforge/pmd/cpd/OccurrenceTest.java @@ -0,0 +1,23 @@ +/* + * User: tom + * Date: Jul 31, 2002 + * Time: 12:20:23 PM + */ +package test.net.sourceforge.pmd.cpd; + +import junit.framework.TestCase; +import net.sourceforge.pmd.cpd.Occurrence; +import net.sourceforge.pmd.cpd.Token; + +public class OccurrenceTest extends TestCase { + public OccurrenceTest(String name) { + super(name); + } + + public void testBasic() { + Occurrence occ = new Occurrence("foo", new Token('h',0,"foo")); + assertEquals("foo", occ.getTokenSetID()); + assertEquals(0, occ.getIndex()); + assertEquals(occ, new Occurrence("foo", new Token('a', 0, "bar"))); + } +}