This is the mail archive of the
mauve-patches@sourceware.org
mailing list for the Mauve project.
FYI: New TextHitInfo tests
- From: Tania Bento <tbento at redhat dot com>
- To: mauve-patches at sources dot redhat dot com
- Date: Fri, 24 Nov 2006 16:15:19 -0500
- Subject: FYI: New TextHitInfo tests
Hey,
This patches adds a new test for each of the methods in
java.awt.font.TextHitInfo. I will be committing the regressions
shortly.
Cheers,
Tania
2006-11-24 Tania Bento <tbento@redhat.com>
* gnu/testlet/java/awt/font/TextHitInfo/afterOffset.java: New
file.
* gnu/testlet/java/awt/font/TextHitInfo/beforeOffset.java: New
file.
* gnu/testlet/java/awt/font/TextHitInfo/equals.java: New file.
* gnu/testlet/java/awt/font/TextHitInfo/getCharIndex: New file.
* gnu/testlet/java/awt/font/TextHitInfo/getInsertionIndex: New
file.
* gnu/testlet/java/awt/font/TextHitInfo/getOtherHit: New file.
* gnu/testlet/java/awt/font/TextHitInfo/getoffsetHit: New file.
* gnu/testlet/java/awt/font/TextHitInfo/hashCode: New file.
* gnu/testlet/java/awt/font/TextHitInfo/isLeadingEdge.java: New
file.
* gnu/testlet/java/awt/font/TextHitInfo/leading.java: New file.
* gnu/testlet/java/awt/font/TextHitInfo/toString.java: New file.
* gnu/testlet/java/awt/font/TextHitInfo/trailing.java: New file.
Index: gnu/testlet/java/awt/font/TextHitInfo/afterOffset.class
===================================================================
RCS file: gnu/testlet/java/awt/font/TextHitInfo/afterOffset.java
diff -N gnu/testlet/java/awt/font/TextHitInfo/afterOffset.java
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ gnu/testlet/java/awt/font/TextHitInfo/afterOffset.java 24 Nov 2006 21:11:48 -0000
@@ -0,0 +1,44 @@
+/* afterOffset.java
+ Copyright (C) 2006 Red Hat
+This file is part of Mauve.
+
+Mauve is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+Mauve is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with Mauve; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+*/
+
+// Tags: JDK1.2
+
+package gnu.testlet.java.awt.font.TextHitInfo;
+
+import java.awt.font.TextHitInfo;
+
+import gnu.testlet.TestHarness;
+import gnu.testlet.Testlet;
+
+public class afterOffset implements Testlet
+{
+
+ public void test(TestHarness harness)
+ {
+ harness.check(TextHitInfo.afterOffset(-6).toString(),
+ "TextHitInfo[-6L]");
+ harness.check(TextHitInfo.afterOffset(0).toString(),
+ "TextHitInfo[0L]");
+ harness.check(TextHitInfo.afterOffset(2).toString(),
+ "TextHitInfo[2L]");
+ }
+
+}
Index: gnu/testlet/java/awt/font/TextHitInfo/beforeOffset.class
===================================================================
RCS file: gnu/testlet/java/awt/font/TextHitInfo/beforeOffset.java
diff -N gnu/testlet/java/awt/font/TextHitInfo/beforeOffset.java
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ gnu/testlet/java/awt/font/TextHitInfo/beforeOffset.java 24 Nov 2006 21:11:48 -0000
@@ -0,0 +1,44 @@
+/* beforeOffset.java
+ Copyright (C) 2006 Red Hat
+This file is part of Mauve.
+
+Mauve is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+Mauve is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with Mauve; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+*/
+
+// Tags: JDK1.2
+
+package gnu.testlet.java.awt.font.TextHitInfo;
+
+import java.awt.font.TextHitInfo;
+
+import gnu.testlet.TestHarness;
+import gnu.testlet.Testlet;
+
+public class beforeOffset implements Testlet
+{
+
+ public void test(TestHarness harness)
+ {
+ harness.check(TextHitInfo.beforeOffset(-6).toString(),
+ "TextHitInfo[-7T]");
+ harness.check(TextHitInfo.beforeOffset(0).toString(),
+ "TextHitInfo[-1T]");
+ harness.check(TextHitInfo.beforeOffset(2).toString(),
+ "TextHitInfo[1T]");
+ }
+
+}
Index: gnu/testlet/java/awt/font/TextHitInfo/equals.java
===================================================================
RCS file: gnu/testlet/java/awt/font/TextHitInfo/equals.java
diff -N gnu/testlet/java/awt/font/TextHitInfo/equals.java
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ gnu/testlet/java/awt/font/TextHitInfo/equals.java 24 Nov 2006 21:11:48 -0000
@@ -0,0 +1,61 @@
+/* equals.java
+ Copyright (C) 2006 Red Hat
+This file is part of Mauve.
+
+Mauve is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+Mauve is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with Mauve; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+*/
+
+// Tags: JDK1.2
+
+package gnu.testlet.java.awt.font.TextHitInfo;
+
+import java.awt.font.TextHitInfo;
+
+import gnu.testlet.TestHarness;
+import gnu.testlet.Testlet;
+
+public class equals implements Testlet
+{
+
+ public void test(TestHarness harness)
+ {
+ equalsObject(harness);
+ equalsTextHitInfo(harness);
+ }
+
+ public void equalsObject(TestHarness harness)
+ {
+ TextHitInfo info = TextHitInfo.trailing(0);
+ harness.check(info.equals((Object) null), false);
+
+ harness.check(info.equals((Object) TextHitInfo.trailing(0)), true);
+
+ String a = "Some String";
+ harness.check(info.equals(a), false);
+ }
+
+ public void equalsTextHitInfo(TestHarness harness)
+ {
+ TextHitInfo info = TextHitInfo.trailing(0);
+ harness.check(info.equals((TextHitInfo) null), false);
+
+ harness.check(info.equals(TextHitInfo.trailing(0)), true);
+ harness.check(info.equals(TextHitInfo.trailing(1)), false);
+ harness.check(info.equals(TextHitInfo.leading(0)), false);
+ harness.check(info.equals(TextHitInfo.leading(1)), false);
+ }
+}
Index: gnu/testlet/java/awt/font/TextHitInfo/getCharIndex.java
===================================================================
RCS file: gnu/testlet/java/awt/font/TextHitInfo/getCharIndex.java
diff -N gnu/testlet/java/awt/font/TextHitInfo/getCharIndex.java
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ gnu/testlet/java/awt/font/TextHitInfo/getCharIndex.java 24 Nov 2006 21:11:48 -0000
@@ -0,0 +1,55 @@
+/* getCharIndex.java
+ Copyright (C) 2006 Red Hat
+This file is part of Mauve.
+
+Mauve is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+Mauve is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with Mauve; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+*/
+
+// Tags: JDK1.2
+
+package gnu.testlet.java.awt.font.TextHitInfo;
+
+import java.awt.font.TextHitInfo;
+
+import gnu.testlet.TestHarness;
+import gnu.testlet.Testlet;
+
+public class getCharIndex implements Testlet
+{
+
+ public void test(TestHarness harness)
+ {
+ TextHitInfo info = TextHitInfo.leading(-2);
+ harness.check(info.getCharIndex(), -2);
+
+ info = TextHitInfo.leading(0);
+ harness.check(info.getCharIndex(), 0);
+
+ info = TextHitInfo.leading(4);
+ harness.check(info.getCharIndex(), 4);
+
+ info = TextHitInfo.trailing(-2);
+ harness.check(info.getCharIndex(), -2);
+
+ info = TextHitInfo.trailing(0);
+ harness.check(info.getCharIndex(), 0);
+
+ info = TextHitInfo.trailing(4);
+ harness.check(info.getCharIndex(), 4);
+ }
+
+}
Index: gnu/testlet/java/awt/font/TextHitInfo/getInsertionIndex.java
===================================================================
RCS file: gnu/testlet/java/awt/font/TextHitInfo/getInsertionIndex.java
diff -N gnu/testlet/java/awt/font/TextHitInfo/getInsertionIndex.java
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ gnu/testlet/java/awt/font/TextHitInfo/getInsertionIndex.java 24 Nov 2006 21:11:48 -0000
@@ -0,0 +1,58 @@
+/* getInsertionIndex.java -
+ Copyright (C) 2006 Red Hat
+This file is part of Mauve.
+
+Mauve is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+Mauve is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with Mauve; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+*/
+
+// Tags: JDK1.2
+
+package gnu.testlet.java.awt.font.TextHitInfo;
+
+import java.awt.font.TextHitInfo;
+
+import gnu.testlet.TestHarness;
+import gnu.testlet.Testlet;
+
+public class getInsertionIndex implements Testlet
+{
+
+ public void test(TestHarness harness)
+ {
+ TextHitInfo info = TextHitInfo.leading(-2);
+ harness.check(info.getInsertionIndex(), -2);
+
+ info = TextHitInfo.leading(0);
+ harness.check(info.getInsertionIndex(), 0);
+
+ info = TextHitInfo.leading(4);
+ harness.check(info.getInsertionIndex(), 4);
+
+ info = TextHitInfo.trailing(-2);
+ harness.check(info.getInsertionIndex(), -1);
+
+ info = TextHitInfo.trailing(0);
+ harness.check(info.getInsertionIndex(), 1);
+
+ info = TextHitInfo.trailing(4);
+ harness.check(info.getInsertionIndex(), 5);
+
+ harness.check(TextHitInfo.leading(1).getInsertionIndex(), 1);
+ harness.check(TextHitInfo.trailing(1).getInsertionIndex(), 2);
+ }
+
+}
Index: gnu/testlet/java/awt/font/TextHitInfo/getOtherHit.java
===================================================================
RCS file: gnu/testlet/java/awt/font/TextHitInfo/getOtherHit.java
diff -N gnu/testlet/java/awt/font/TextHitInfo/getOtherHit.java
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ gnu/testlet/java/awt/font/TextHitInfo/getOtherHit.java 24 Nov 2006 21:11:48 -0000
@@ -0,0 +1,43 @@
+/* getOtherHit.java
+ Copyright (C) 2006 Red Hat
+This file is part of Mauve.
+
+Mauve is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+Mauve is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with Mauve; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+*/
+
+// Tags: JDK1.2
+
+package gnu.testlet.java.awt.font.TextHitInfo;
+
+import java.awt.font.TextHitInfo;
+
+import gnu.testlet.TestHarness;
+import gnu.testlet.Testlet;
+
+public class getOtherHit implements Testlet
+{
+
+ public void test(TestHarness harness)
+ {
+ TextHitInfo info = TextHitInfo.leading(0);
+ harness.check(info.getOtherHit().toString(), "TextHitInfo[-1T]");
+
+ info = TextHitInfo.trailing(0);
+ harness.check(info.getOtherHit().toString(), "TextHitInfo[1L]");
+ }
+
+}
Index: gnu/testlet/java/awt/font/TextHitInfo/getoffsetHit.java
===================================================================
RCS file: gnu/testlet/java/awt/font/TextHitInfo/getoffsetHit.java
diff -N gnu/testlet/java/awt/font/TextHitInfo/getoffsetHit.java
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ gnu/testlet/java/awt/font/TextHitInfo/getoffsetHit.java 24 Nov 2006 21:11:48 -0000
@@ -0,0 +1,61 @@
+/* getoffsetHit.java
+ Copyright (C) 2006 Red Hat
+This file is part of Mauve.
+
+Mauve is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+Mauve is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with Mauve; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+*/
+
+// Tags: JDK1.2
+
+package gnu.testlet.java.awt.font.TextHitInfo;
+
+import java.awt.font.TextHitInfo;
+
+import gnu.testlet.TestHarness;
+import gnu.testlet.Testlet;
+
+public class getoffsetHit implements Testlet
+{
+
+ public void test(TestHarness harness)
+ {
+ TextHitInfo info = TextHitInfo.leading(0);
+ harness.check(info.getOffsetHit(0).toString(), "TextHitInfo[0L]");
+ harness.check(info.isLeadingEdge(), true);
+
+ info = TextHitInfo.leading(0);
+ harness.check(info.getOffsetHit(-2).toString(), "TextHitInfo[-2L]");
+ harness.check(info.isLeadingEdge(), true);
+
+ info = TextHitInfo.leading(0);
+ harness.check(info.getOffsetHit(2).toString(), "TextHitInfo[2L]");
+ harness.check(info.isLeadingEdge(), true);
+
+ info = TextHitInfo.trailing(0);
+ harness.check(info.getOffsetHit(0).toString(), "TextHitInfo[0T]");
+ harness.check(info.isLeadingEdge(), false);
+
+ info = TextHitInfo.trailing(0);
+ harness.check(info.getOffsetHit(-2).toString(), "TextHitInfo[-2T]");
+ harness.check(info.isLeadingEdge(), false);
+
+ info = TextHitInfo.trailing(0);
+ harness.check(info.getOffsetHit(2).toString(), "TextHitInfo[2T]");
+ harness.check(info.isLeadingEdge(), false);
+ }
+
+}
Index: gnu/testlet/java/awt/font/TextHitInfo/hashCode.java
===================================================================
RCS file: gnu/testlet/java/awt/font/TextHitInfo/hashCode.java
diff -N gnu/testlet/java/awt/font/TextHitInfo/hashCode.java
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ gnu/testlet/java/awt/font/TextHitInfo/hashCode.java 24 Nov 2006 21:11:48 -0000
@@ -0,0 +1,58 @@
+/* hashCode.java
+ Copyright (C) 2006 Red Hat
+This file is part of Mauve.
+
+Mauve is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+Mauve is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with Mauve; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+*/
+
+// Tags: JDK1.2
+
+package gnu.testlet.java.awt.font.TextHitInfo;
+
+import java.awt.font.TextHitInfo;
+
+import gnu.testlet.TestHarness;
+import gnu.testlet.Testlet;
+
+public class hashCode implements Testlet
+{
+
+ public void test(TestHarness harness)
+ {
+ TextHitInfo info = TextHitInfo.leading(-2);
+ harness.check(info.hashCode(), -2);
+
+ info = TextHitInfo.leading(0);
+ harness.check(info.hashCode(), 0);
+
+ info = TextHitInfo.leading(4);
+ harness.check(info.hashCode(), 4);
+
+ info = TextHitInfo.trailing(-2);
+ harness.check(info.hashCode(), -2);
+
+ info = TextHitInfo.trailing(0);
+ harness.check(info.hashCode(), 0);
+
+ info = TextHitInfo.trailing(4);
+ harness.check(info.hashCode(), 4);
+
+ harness.check(TextHitInfo.leading(1).hashCode(), 1);
+ harness.check(TextHitInfo.trailing(1).hashCode(), 1);
+ }
+
+}
Index: gnu/testlet/java/awt/font/TextHitInfo/isLeadingEdge.java
===================================================================
RCS file: gnu/testlet/java/awt/font/TextHitInfo/isLeadingEdge.java
diff -N gnu/testlet/java/awt/font/TextHitInfo/isLeadingEdge.java
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ gnu/testlet/java/awt/font/TextHitInfo/isLeadingEdge.java 24 Nov 2006 21:11:48 -0000
@@ -0,0 +1,58 @@
+/* isLeadingEdge.java
+ Copyright (C) 2006 Red Hat
+This file is part of Mauve.
+
+Mauve is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+Mauve is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with Mauve; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+*/
+
+// Tags: JDK1.2
+
+package gnu.testlet.java.awt.font.TextHitInfo;
+
+import java.awt.font.TextHitInfo;
+
+import gnu.testlet.TestHarness;
+import gnu.testlet.Testlet;
+
+public class isLeadingEdge implements Testlet
+{
+
+ public void test(TestHarness harness)
+ {
+ TextHitInfo info = TextHitInfo.leading(-2);
+ harness.check(info.isLeadingEdge(), true);
+
+ info = TextHitInfo.leading(0);
+ harness.check(info.isLeadingEdge(), true);
+
+ info = TextHitInfo.leading(4);
+ harness.check(info.isLeadingEdge(), true);
+
+ info = TextHitInfo.trailing(-2);
+ harness.check(info.isLeadingEdge(), false);
+
+ info = TextHitInfo.trailing(0);
+ harness.check(info.isLeadingEdge(), false);
+
+ info = TextHitInfo.trailing(4);
+ harness.check(info.isLeadingEdge(), false);
+
+ harness.check(TextHitInfo.leading(1).isLeadingEdge(), true);
+ harness.check(TextHitInfo.trailing(1).isLeadingEdge(), false);
+ }
+
+}
Index: gnu/testlet/java/awt/font/TextHitInfo/leading.java
===================================================================
RCS file: gnu/testlet/java/awt/font/TextHitInfo/leading.java
diff -N gnu/testlet/java/awt/font/TextHitInfo/leading.java
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ gnu/testlet/java/awt/font/TextHitInfo/leading.java 24 Nov 2006 21:11:48 -0000
@@ -0,0 +1,44 @@
+/* leading.java
+ Copyright (C) 2006 Red Hat
+This file is part of Mauve.
+
+Mauve is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+Mauve is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with Mauve; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+*/
+
+// Tags: JDK1.2
+
+package gnu.testlet.java.awt.font.TextHitInfo;
+
+import java.awt.font.TextHitInfo;
+
+import gnu.testlet.TestHarness;
+import gnu.testlet.Testlet;
+
+public class leading implements Testlet
+{
+
+ public void test(TestHarness harness)
+ {
+ harness.check(TextHitInfo.leading(-1).toString(),
+ "TextHitInfo[-1L]");
+ harness.check(TextHitInfo.leading(0).toString(),
+ "TextHitInfo[0L]");
+ harness.check(TextHitInfo.leading(1).toString(),
+ "TextHitInfo[1L]");
+ }
+
+}
Index: gnu/testlet/java/awt/font/TextHitInfo/toString.java
===================================================================
RCS file: gnu/testlet/java/awt/font/TextHitInfo/toString.java
diff -N gnu/testlet/java/awt/font/TextHitInfo/toString.java
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ gnu/testlet/java/awt/font/TextHitInfo/toString.java 24 Nov 2006 21:11:48 -0000
@@ -0,0 +1,43 @@
+/* toString.java
+ Copyright (C) 2006 Red Hat
+This file is part of Mauve.
+
+Mauve is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+Mauve is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with Mauve; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+*/
+
+// Tags: JDK1.2
+
+package gnu.testlet.java.awt.font.TextHitInfo;
+
+import java.awt.font.TextHitInfo;
+
+import gnu.testlet.TestHarness;
+import gnu.testlet.Testlet;
+
+public class toString implements Testlet
+{
+
+ public void test(TestHarness harness)
+ {
+ TextHitInfo info = TextHitInfo.leading(0);
+ harness.check(info.toString(), "TextHitInfo[0L]");
+
+ info = TextHitInfo.trailing(5);
+ harness.check(info.toString(), "TextHitInfo[5T]");
+ }
+
+}
Index: gnu/testlet/java/awt/font/TextHitInfo/trailing.java
===================================================================
RCS file: gnu/testlet/java/awt/font/TextHitInfo/trailing.java
diff -N gnu/testlet/java/awt/font/TextHitInfo/trailing.java
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ gnu/testlet/java/awt/font/TextHitInfo/trailing.java 24 Nov 2006 21:11:48 -0000
@@ -0,0 +1,44 @@
+/* trailing.java
+ Copyright (C) 2006 Red Hat
+This file is part of Mauve.
+
+Mauve is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+Mauve is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with Mauve; see the file COPYING. If not, write to the
+Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+02110-1301 USA.
+
+*/
+
+// Tags: JDK1.2
+
+package gnu.testlet.java.awt.font.TextHitInfo;
+
+import java.awt.font.TextHitInfo;
+
+import gnu.testlet.TestHarness;
+import gnu.testlet.Testlet;
+
+public class trailing implements Testlet
+{
+
+ public void test(TestHarness harness)
+ {
+ harness.check(TextHitInfo.trailing(-1).toString(),
+ "TextHitInfo[-1T]");
+ harness.check(TextHitInfo.trailing(0).toString(),
+ "TextHitInfo[0T]");
+ harness.check(TextHitInfo.trailing(1).toString(),
+ "TextHitInfo[1T]");
+ }
+
+}