diff options
Diffstat (limited to 'luni')
38 files changed, 29 insertions, 7777 deletions
diff --git a/luni/src/test/java/libcore/java/util/regex/OldMatcherTest.java b/luni/src/test/java/libcore/java/util/regex/OldMatcherTest.java index 549a9ca..450b8d9 100644 --- a/luni/src/test/java/libcore/java/util/regex/OldMatcherTest.java +++ b/luni/src/test/java/libcore/java/util/regex/OldMatcherTest.java @@ -17,35 +17,14 @@ package libcore.java.util.regex; -import dalvik.annotation.TestLevel; -import dalvik.annotation.TestTargetClass; -import dalvik.annotation.TestTargetNew; import java.util.regex.Matcher; import java.util.regex.Pattern; import junit.framework.TestCase; -@TestTargetClass( - value = Matcher.class, - untestedMethods= { - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "finalize is hard to test since the implementation only calls a native function", - method = "finalize", - args = {} - ) - } - -) public class OldMatcherTest extends TestCase { String[] groupPatterns = { "(a|b)*aabb", "((a)|b)*aabb", "((a|b)*)a(abb)", "(((a)|(b))*)aabb", "(((a)|(b))*)aa(b)b", "(((a)|(b))*)a(a(b)b)" }; - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "", - method = "appendReplacement", - args = {java.lang.StringBuffer.class, java.lang.String.class} - ) public void testAppendReplacement() { Pattern pat = Pattern.compile("XX"); Matcher m = pat.matcher("Today is XX-XX-XX ..."); @@ -78,16 +57,6 @@ public class OldMatcherTest extends TestCase { assertNotNull(t); } - /** - * @test java.util.regex.Matcher#reset(String) - * test reset(String) method. - */ - @TestTargetNew( - level = TestLevel.COMPLETE, - notes = "Verifies the reset(CharSequence input) method.", - method = "reset", - args = {java.lang.CharSequence.class} - ) public void test_resetLjava_lang_String() { String testPattern = "(abb)"; String testString1 = "babbabbcccabbabbabbabbabb"; @@ -102,12 +71,6 @@ public class OldMatcherTest extends TestCase { assertTrue("After reset matcher should find pattern in given input", mat.find()); } - @TestTargetNew( - level = TestLevel.COMPLETE, - notes = "", - method = "appendTail", - args = {java.lang.StringBuffer.class} - ) public void testAppendTail() { Pattern p = Pattern.compile("cat"); Matcher m = p.matcher("one-cat-two-cats-in-the-yard"); @@ -143,16 +106,6 @@ public class OldMatcherTest extends TestCase { assertNotNull(t); } - /** - * @test java.util.regex.Matcher#reset() - * test reset() method. - */ - @TestTargetNew( - level = TestLevel.COMPLETE, - notes = "Verifies the reset() method. ", - method = "reset", - args = {} - ) public void test_reset() { String testPattern = "(abb)"; String testString = "babbabbcccabbabbabbabbabb"; @@ -164,16 +117,6 @@ public class OldMatcherTest extends TestCase { assertTrue("After reset matcher should find pattern in given input", mat.find()); } - /** - * @test java.util.regex.Matcher#hasAnchoringBounds() - * test hasAnchoringBounds() method. - */ - @TestTargetNew( - level = TestLevel.COMPLETE, - notes = "Verifies that hasAnchoringBounds method returns correct value.", - method = "hasAnchoringBounds", - args = {} - ) public void test_hasAnchoringBounds() { String testPattern = "abb"; String testString = "abb"; @@ -192,16 +135,6 @@ public class OldMatcherTest extends TestCase { mu.hasAnchoringBounds()); } - /** - * @test java.util.regex.Matcher#hasTransparentBounds() - * test hasTransparentBounds() method. - */ - @TestTargetNew( - level = TestLevel.COMPLETE, - notes = "Verifies that hasTransparentBound method returns correct value.", - method = "hasTransparentBounds", - args = {} - ) public void test_hasTransparentBounds() { String testPattern = "abb"; String testString = "ab\nb"; @@ -220,16 +153,6 @@ public class OldMatcherTest extends TestCase { mu.hasTransparentBounds()); } - /** - * @test java.util.regex.Matcher#start(int) - * test start(int) method. - */ - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the start(int group) method.", - method = "start", - args = {int.class} - ) public void test_startI() { String testPattern = "(((abb)a)(bb))"; String testString = "cccabbabbabbabbabb"; @@ -252,16 +175,6 @@ public class OldMatcherTest extends TestCase { } } - /** - * @test java.util.regex.Matcher#end(int) - * test end(int) method. - */ - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the basic functionality of end(int group) method.", - method = "end", - args = {int.class} - ) public void test_endI() { String testPattern = "(((abb)a)(bb))"; String testString = "cccabbabbabbabbabb"; @@ -285,16 +198,6 @@ public class OldMatcherTest extends TestCase { } - /** - * @test java.util.regex.Matcher#lookingAt() - * test lookingAt() method. - */ - @TestTargetNew( - level = TestLevel.COMPLETE, - notes = "Verifies that lookingAt() method returns correct value.", - method = "lookingAt", - args = {} - ) public void test_lookingAt() { String testPattern = "(((abb)a)(bb))"; String testString1 = "babbabbcccabbabbabbabbabb"; @@ -309,16 +212,6 @@ public class OldMatcherTest extends TestCase { assertTrue("Should find given pattern in 2 string", mat2.lookingAt()); } - /** - * @test java.util.regex.Matcher#find(int) - * test find (int) method. Created via modifying method for find - */ - @TestTargetNew( - level = TestLevel.COMPLETE, - notes = "", - method = "find", - args = {int.class} - ) public void test_findI() { String testPattern = "(abb)"; String testString = "cccabbabbabbabbabb"; @@ -368,12 +261,7 @@ public class OldMatcherTest extends TestCase { assertFalse(mat3.find(6)); assertFalse(mat3.find(7)); } - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies matches() method for predefined.", - method = "replaceFirst", - args = {java.lang.String.class} - ) + public void testSEOLsymbols() { Pattern pat = Pattern.compile("^a\\(bb\\[$"); Matcher mat = pat.matcher("a(bb["); @@ -381,16 +269,6 @@ public class OldMatcherTest extends TestCase { assertTrue(mat.matches()); } - /** - * @test java.util.regex.Matcher#start() - * test start() method. - */ - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the start() method.", - method = "start", - args = {} - ) public void test_start() { String testPattern = "(abb)"; String testString = "cccabbabbabbabbabb"; @@ -410,16 +288,6 @@ public class OldMatcherTest extends TestCase { } } - /** - * @test java.util.regex.Matcher#end() - * test end() method. - */ - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the basic functionality of end() method. ", - method = "end", - args = {} - ) public void test_end() { String testPattern = "(abb)"; String testString = "cccabbabbabbabbabb"; @@ -438,12 +306,7 @@ public class OldMatcherTest extends TestCase { } } } - @TestTargetNew( - level = TestLevel.COMPLETE, - notes = "Verifies groupCount() method.", - method = "groupCount", - args = {} - ) + public void testGroupCount() { for (int i = 0; i < groupPatterns.length; i++) { Pattern test = Pattern.compile(groupPatterns[i]); @@ -454,12 +317,6 @@ public class OldMatcherTest extends TestCase { } - @TestTargetNew( - level = TestLevel.COMPLETE, - notes = "", - method = "region", - args = {int.class, int.class} - ) public void testRegion() { Pattern p = Pattern.compile("abba"); Matcher m = p.matcher("Gabba gabba hey"); @@ -495,12 +352,6 @@ public class OldMatcherTest extends TestCase { } - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies matches method for input sequence specified by URL.", - method = "matches", - args = {} - ) public void testMatchesURI() { Pattern pat = Pattern. compile("^(//([^/?#]*))?([^?#]*)(\\?([^#]*))?(#(.*))?"); @@ -511,22 +362,10 @@ public class OldMatcherTest extends TestCase { } - @TestTargetNew( - level = TestLevel.COMPLETE, - notes = "", - method = "quoteReplacement", - args = {java.lang.String.class} - ) public void testQuoteReplacement() { assertEquals("\\$dollar and slash\\\\", Matcher.quoteReplacement("$dollar and slash\\")); } - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "", - method = "matches", - args = {} - ) public void testUnicode() { assertTrue(Pattern.compile("\\x61a").matcher("aa").matches()); @@ -535,12 +374,7 @@ public class OldMatcherTest extends TestCase { assertTrue(Pattern.compile("\\0777").matcher("?7").matches()); } - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "", - method = "matches", - args = {} - ) + public void testUnicodeCategory() { assertTrue(Pattern.compile("\\p{Ll}").matcher("k").matches()); // Unicode lower case assertTrue(Pattern.compile("\\P{Ll}").matcher("K").matches()); // Unicode non-lower @@ -572,13 +406,6 @@ public class OldMatcherTest extends TestCase { // BEGIN android-note // Test took ages, now going in steps of 16 code points to speed things up. // END android-note - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "The stress test for matches(String regex) method from String class.", - clazz = String.class, - method = "matches", - args = {java.lang.String.class} - ) public void testAllCodePoints() { // Regression for HARMONY-3145 int[] codePoint = new int[1]; @@ -614,16 +441,6 @@ public class OldMatcherTest extends TestCase { assertEquals(0x110000 / 0x10, cnt); } - /** - * @test java.util.regex.Matcher#regionStart() - * test regionStart() method. - */ - @TestTargetNew( - level = TestLevel.COMPLETE, - notes = "Verifies the regionStart() method.", - method = "regionStart", - args = {} - ) public void test_regionStart() { String testPattern = "(abb)"; String testString = "cccabbabbabbabbabb"; @@ -637,16 +454,6 @@ public class OldMatcherTest extends TestCase { assertEquals("Region sould start from 0 position after reset", 0, mat.regionStart()); } - /** - * @test java.util.regex.Matcher#regionEnd() - * test regionEnd() method. - */ - @TestTargetNew( - level = TestLevel.COMPLETE, - notes = "Verifies the regionEnd() method.", - method = "regionEnd", - args = {} - ) public void test_regionEnd() { String testPattern = "(abb)"; String testString = "cccabbabbabbabbabb"; @@ -660,16 +467,6 @@ public class OldMatcherTest extends TestCase { assertEquals("Region end value should be equal to string length after reset", testString.length(), mat.regionEnd()); } - /** - * @test java.util.regex.Matcher#toMatchResult() - * test toMatchResult() method. - */ - @TestTargetNew( - level = TestLevel.COMPLETE, - notes = "Verifies the toMatchResult method.", - method = "toMatchResult", - args = {} - ) public void test_toMatchResult() { String testPattern = "(((abb)a)(bb))"; String testString = "babbabbcccabbabbabbabbabb"; @@ -687,16 +484,6 @@ public class OldMatcherTest extends TestCase { assertEquals("Total number of groups does not matched with given pattern", 4, mat.toMatchResult().groupCount()); } - /** - * @test java.util.regex.Matcher#usePattern(Pattern newPattern) - * test usePattern(Pattern newPattern) method. - */ - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the usePattern(Pattern newPattern) method.", - method = "usePattern", - args = {java.util.regex.Pattern.class} - ) public void test_usePatternLjava_util_regex_Pattern() { String testPattern1 = "(((abb)a)(bb))"; String testPattern2 = "(abbabb)"; @@ -713,16 +500,6 @@ public class OldMatcherTest extends TestCase { assertFalse("matcher should not find pattern in given region", mat.matches()); } - /** - * @test java.util.regex.Matcher#useAchoringBounds() - * test useAchoringBounds() method. - */ - @TestTargetNew( - level = TestLevel.COMPLETE, - notes = "", - method = "useAnchoringBounds", - args = {boolean.class} - ) public void test_anchoringBounds() { String testPattern = "^ro$"; String testString = "android"; @@ -738,16 +515,6 @@ public class OldMatcherTest extends TestCase { assertFalse("Should find pattern with anchoring bounds", mat.find(0)); } - /** - * @test java.util.regex.Matcher#useTransparentBounds() - * test useTransparentBounds() method. - */ - @TestTargetNew( - level = TestLevel.COMPLETE, - notes = "Verifies the useTransparentBounds(boolean b) method.", - method = "useTransparentBounds", - args = {boolean.class} - ) public void test_transparentBounds() { String testPattern = "and(?=roid)"; String testString = "android"; @@ -774,16 +541,6 @@ public class OldMatcherTest extends TestCase { assertFalse("Shouldn't find pattern transparent bounds", mat.matches()); // *** } - /** - * @test java.util.regex.Matcher#hitEnd() - * test hitEnd() method. - */ - @TestTargetNew( - level = TestLevel.COMPLETE, - notes = "Verifies that hitEnd() method returns correct value. ", - method = "hitEnd", - args = {} - ) public void test_hitEnd() { String testPattern = "abb"; String testString = "babbabbcccabbabbabbabbabb"; @@ -796,16 +553,6 @@ public class OldMatcherTest extends TestCase { assertTrue("hitEnd should return true after finding last match", mat.hitEnd()); // *** } - /** - * @test java.util.regex.Matcher#requireEnd() - * test requireEnd() method. - */ - @TestTargetNew( - level = TestLevel.COMPLETE, - notes = "Verifies the requireEnd() method.", - method = "requireEnd", - args = {} - ) public void test_requireEnd() { String testPattern = "bba"; String testString = "abbbbba"; @@ -827,12 +574,6 @@ public class OldMatcherTest extends TestCase { /* * Regression test for HARMONY-674 */ - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Special regression test for matches() method.", - method = "matches", - args = {} - ) public void testPatternMatcher() throws Exception { Pattern pattern = Pattern.compile("(?:\\d+)(?:pt)"); assertTrue(pattern.matcher("14pt").matches()); diff --git a/luni/src/test/java/org/apache/harmony/regex/tests/java/util/regex/PatternTest.java b/luni/src/test/java/org/apache/harmony/regex/tests/java/util/regex/PatternTest.java index 9dafd23..ffbdf9e 100644 --- a/luni/src/test/java/org/apache/harmony/regex/tests/java/util/regex/PatternTest.java +++ b/luni/src/test/java/org/apache/harmony/regex/tests/java/util/regex/PatternTest.java @@ -27,22 +27,6 @@ import junit.framework.TestCase; import org.apache.harmony.testframework.serialization.SerializationTest; import org.apache.harmony.testframework.serialization.SerializationTest.SerializableAssert; -import dalvik.annotation.TestLevel; -import dalvik.annotation.TestTargetClass; -import dalvik.annotation.TestTargetNew; -import dalvik.annotation.TestTargets; - -@TestTargetClass( - value = Pattern.class, - untestedMethods= { - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "finalize is hard to test since the implementation only calls a native function", - method = "finalize", - args = {} - ) - } -) public class PatternTest extends TestCase { String[] testPatterns = { "(a|b)*abb", @@ -85,12 +69,6 @@ public class PatternTest extends TestCase { final static int DEFAULT_FLAGS = 0; - @TestTargetNew( - level = TestLevel.ADDITIONAL, - notes = "", - method = "!", - args = {} - ) public void testMatcher() { // some very simple test Pattern p = Pattern.compile("a"); @@ -98,15 +76,6 @@ public class PatternTest extends TestCase { assertNotSame(p.matcher("a"), p.matcher("a")); } - /* - * Class under test for String[] split(CharSequence, int) - */ - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of splitsplit(java.lang.String, int) method.", - method = "split", - args = {CharSequence.class, int.class} - ) public void testSplitCharSequenceint() { // splitting CharSequence which ends with pattern // bug6193 @@ -181,15 +150,6 @@ public class PatternTest extends TestCase { assertEquals(s.length, 5); } - /* - * Class under test for String[] split(CharSequence) - */ - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of splitsplit(java.lang.String) method.", - method = "split", - args = {CharSequence.class} - ) public void testSplitCharSequence() { String s[]; Pattern pat = Pattern.compile("b"); @@ -209,12 +169,6 @@ public class PatternTest extends TestCase { // bug6544 } - @TestTargetNew( - level = TestLevel.COMPLETE, - notes = "Verifies the functionality of pattern() method.", - method = "pattern", - args = {} - ) public void testPattern() { /* Positive assertion test. */ for (String aPattern : testPatterns) { @@ -227,12 +181,6 @@ public class PatternTest extends TestCase { } } - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile(java.lang.String) method.", - method = "compile", - args = {java.lang.String.class} - ) public void testCompile() { /* Positive assertion test. */ for (String aPattern : testPatterns) { @@ -265,12 +213,6 @@ public class PatternTest extends TestCase { } } - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile(java.lang.String) method for different flags.", - method = "compile", - args = {java.lang.String.class} - ) public void testFlags() { String baseString; String testString; @@ -443,13 +385,6 @@ public class PatternTest extends TestCase { * Check default flags when they are not specified in pattern. Based on RI * since could not find that info */ - - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of flags() method for default flags.", - method = "flags", - args = {} - ) public void testFlagsCompileDefault() { for (String pat : testPatternsAlt) { try { @@ -466,21 +401,6 @@ public class PatternTest extends TestCase { * simple implementation that does not use flags combinations. Need to * improve. */ - - @TestTargets({ - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile(java.lang.String, int) & flags() methods. Checks that compilation was corect.", - method = "flags", - args = {} - ), - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile(java.lang.String, int) & flags() methods. Checks that compilation was corect.", - method = "compile", - args = {java.lang.String.class, int.class} - ) - }) public void testFlagsCompileValid() { for (String pat : testPatternsAlt) { for (int flags : flagsSet) { @@ -494,16 +414,6 @@ public class PatternTest extends TestCase { } } - /* - * Class under test for Pattern compile(String, int) - */ - - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile(java.lang.String) method.Checks that correct exceptions were thrown.", - method = "compile", - args = {java.lang.String.class} - ) public void testCompileStringint() { /* * these tests are needed to verify that appropriate exceptions are @@ -559,12 +469,6 @@ public class PatternTest extends TestCase { /* * Class under test for Pattern compile(String) */ - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile(java.lang.String) method.Checks that correct exceptions were thrown.", - method = "compile", - args = {java.lang.String.class} - ) public void testQuantCompileNeg() { String[] patterns = { "5{,2}", "{5asd", "{hgdhg", "{5,hjkh", "{,5hdsh", "{5,3shdfkjh}" }; @@ -587,12 +491,6 @@ public class PatternTest extends TestCase { assertNotNull(Pattern.compile(pattern)); } - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile(java.lang.String) method.", - method = "compile", - args = {java.lang.String.class} - ) public void testQuantCompilePos() { String[] patterns = {/* "(abc){1,3}", */"abc{2,}", "abc{5}" }; for (String element : patterns) { @@ -600,12 +498,6 @@ public class PatternTest extends TestCase { } } - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile() method. Also tested methods from matcher: matches(), start(int), group(int)", - method = "compile", - args = {java.lang.String.class} - ) public void testQuantComposition() { String pattern = "(a{1,3})aab"; java.util.regex.Pattern pat = java.util.regex.Pattern.compile(pattern); @@ -615,12 +507,6 @@ public class PatternTest extends TestCase { mat.group(1); } - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "", - method = "matches", - args = {java.lang.String.class, java.lang.CharSequence.class} - ) public void testMatches() { String[][] posSeq = { { "abb", "ababb", "abababbababb", "abababbababbabababbbbbabb" }, @@ -649,12 +535,6 @@ public class PatternTest extends TestCase { } } - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies exception", - method = "matches", - args = {java.lang.String.class, java.lang.CharSequence.class} - ) public void testMatchesException() { /* Negative assertion test. */ for (String aPattern : wrongTestPatterns) { @@ -669,12 +549,6 @@ public class PatternTest extends TestCase { } } - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "The test verifies the functionality of matches(java.lang.String,java.lang.CharSequence) method.", - method = "matches", - args = {java.lang.String.class, java.lang.CharSequence.class} - ) public void testTimeZoneIssue() { Pattern p = Pattern.compile("GMT(\\+|\\-)(\\d+)(:(\\d+))?"); Matcher m = p.matcher("GMT-9:45"); @@ -687,12 +561,6 @@ public class PatternTest extends TestCase { // BEGIN android-changed // Removed one pattern that is buggy on the JDK. We don't want to duplicate that. - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of matches(java.lang.String,java.lang.CharSequence) method.", - method = "matches", - args = {java.lang.String.class, java.lang.CharSequence.class} - ) public void testCompileRanges() { String[] correctTestPatterns = { "[^]*abb]*", /* "[^a-d[^m-p]]*abb", */ "[a-d\\d]*abb", "[abc]*abb", "[a-e&&[de]]*abb", "[^abc]*abb", @@ -726,12 +594,6 @@ public class PatternTest extends TestCase { } } - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of matches(java.lang.String,java.lang.CharSequence) method for ranged patterns.", - method = "matches", - args = {java.lang.String.class, java.lang.CharSequence.class} - ) public void testRangesSpecialCases() { String neg_patterns[] = { "[a-&&[b-c]]", "[a-\\w]", "[b-a]", "[]" }; @@ -755,22 +617,10 @@ public class PatternTest extends TestCase { } // END android-changed - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "The test verifies the functionality of matches(java.lang.String,java.lang.CharSequence) method.", - method = "matches", - args = {java.lang.String.class, java.lang.CharSequence.class} - ) -public void testZeroSymbols() { + public void testZeroSymbols() { assertTrue(Pattern.matches("[\0]*abb", "\0\0\0\0\0\0abb")); } - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of matcher(java.lang.String) method.", - method = "matcher", - args = {CharSequence.class} - ) public void testEscapes() { Pattern pat = Pattern.compile("\\Q{]()*?"); Matcher mat = pat.matcher("{]()*?"); @@ -778,22 +628,10 @@ public void testZeroSymbols() { assertTrue(mat.matches()); } - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile(java.lang.String) method.", - method = "compile", - args = {java.lang.String.class} - ) public void testBug181() { Pattern.compile("[\\t-\\r]"); } - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile(java.lang.String) method.", - method = "compile", - args = {java.lang.String.class} - ) public void testOrphanQuantifiers() { try { Pattern.compile("+++++"); @@ -802,12 +640,6 @@ public void testZeroSymbols() { } } - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile(java.lang.String) method.", - method = "compile", - args = {java.lang.String.class} - ) public void testOrphanQuantifiers2() { try { Pattern pat = Pattern.compile("\\d+*"); @@ -816,21 +648,6 @@ public void testZeroSymbols() { } } - - @TestTargets({ - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile(java.lang.String) method.", - method = "compile", - args = {java.lang.String.class} - ), - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile(java.lang.String) method.", - method = "compile", - args = {java.lang.String.class} - ) - }) public void testBug197() { Object[] vals = { ":", new Integer(2), new String[] { "boo", "and:foo" }, ":", new Integer(5), @@ -856,13 +673,6 @@ public void testZeroSymbols() { } } - - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "The test verifies the functionality of compile(java.lang.String) method.", - method = "compile", - args = {java.lang.String.class} - ) public void testURIPatterns() { String URI_REGEXP_STR = "^(([^:/?#]+):)?(//([^/?#]*))?([^?#]*)(\\?([^#]*))?(#(.*))?"; String SCHEME_REGEXP_STR = "^[a-zA-Z]{1}[\\w+-.]+$"; @@ -881,12 +691,6 @@ public void testZeroSymbols() { Pattern HOSTNAME_REGEXP = Pattern.compile(HOSTNAME_REGEXP_STR); } - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile(java.lang.String) method.", - method = "compile", - args = {java.lang.String.class} - ) public void testFindBoundaryCases1() { Pattern pat = Pattern.compile(".*\n"); Matcher mat = pat.matcher("a\n"); @@ -895,12 +699,6 @@ public void testZeroSymbols() { assertEquals("a\n", mat.group()); } - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile(java.lang.String) method.", - method = "compile", - args = {java.lang.String.class} - ) public void testFindBoundaryCases2() { Pattern pat = Pattern.compile(".*A"); Matcher mat = pat.matcher("aAa"); @@ -909,12 +707,6 @@ public void testZeroSymbols() { assertEquals("aA", mat.group()); } - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile(java.lang.String) method.", - method = "compile", - args = {java.lang.String.class} - ) public void testFindBoundaryCases3() { Pattern pat = Pattern.compile(".*A"); Matcher mat = pat.matcher("a\naA\n"); @@ -923,12 +715,6 @@ public void testZeroSymbols() { assertEquals("aA", mat.group()); } - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile(java.lang.String) method.", - method = "compile", - args = {java.lang.String.class} - ) public void testFindBoundaryCases4() { Pattern pat = Pattern.compile("A.*"); Matcher mat = pat.matcher("A\n"); @@ -937,12 +723,6 @@ public void testZeroSymbols() { assertEquals("A", mat.group()); } - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile(java.lang.String) method.", - method = "compile", - args = {java.lang.String.class} - ) public void testFindBoundaryCases5() { Pattern pat = Pattern.compile(".*A.*"); Matcher mat = pat.matcher("\nA\naaa\nA\naaAaa\naaaA\n"); @@ -954,12 +734,6 @@ public void testZeroSymbols() { } } - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile(java.lang.String) method.", - method = "compile", - args = {java.lang.String.class} - ) public void testFindBoundaryCases6() { String[] res = { "", "a", "", "" }; Pattern pat = Pattern.compile(".*"); @@ -971,20 +745,6 @@ public void testZeroSymbols() { } } - @TestTargets({ - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile(java.lang.String) & matcher(java.lang.CharSequence) methods.", - method = "compile", - args = {java.lang.String.class} - ), - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile(java.lang.String) & matcher(java.lang.CharSequence) methods.", - method = "matcher", - args = {java.lang.CharSequence.class} - ) - }) public void testBackReferences() { Pattern pat = Pattern.compile("(\\((\\w*):(.*):(\\2)\\))"); Matcher mat = pat @@ -1002,20 +762,6 @@ public void testZeroSymbols() { assertTrue(mat.matches()); } - @TestTargets({ - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile(java.lang.String, int) & matcher(java.lang.CharSequence) methods.", - method = "compile", - args = {java.lang.String.class, int.class} - ), - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile(java.lang.String, int) & matcher(java.lang.CharSequence) methods.", - method = "matcher", - args = {java.lang.CharSequence.class} - ) - }) public void testNewLine() { Pattern pat = Pattern.compile("(^$)*\n", Pattern.MULTILINE); Matcher mat = pat.matcher("\r\n\n"); @@ -1026,40 +772,13 @@ public void testZeroSymbols() { assertEquals(2, counter); } - @TestTargets({ - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile(java.lang.String, int) & matcher(java.lang.CharSequence) methods.", - method = "compile", - args = {java.lang.String.class, int.class} - ), - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile(java.lang.String, int) & matcher(java.lang.CharSequence) methods.", - method = "matcher", - args = {java.lang.CharSequence.class} - ) - }) public void testFindGreedy() { Pattern pat = Pattern.compile(".*aaa", Pattern.DOTALL); Matcher mat = pat.matcher("aaaa\naaa\naaaaaa"); mat.matches(); assertEquals(15, mat.end()); } - @TestTargets({ - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies serialization/deserialization.", - method = "!SerializationSelf", - args = {} - ), - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies serialization/deserialization.", - method = "!SerializationGolden", - args = {} - ) - }) + public void testSerialization() throws Exception { Pattern pat = Pattern.compile("a*bc"); SerializableAssert comparator = new SerializableAssert() { @@ -1073,20 +792,6 @@ public void testZeroSymbols() { SerializationTest.verifySelf(pat, comparator); } - @TestTargets({ - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile(java.lang.String, int) & matcher(java.lang.CharSequence) methods.", - method = "compile", - args = {java.lang.String.class, int.class} - ), - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile(java.lang.String, int) & matcher(java.lang.CharSequence) methods.", - method = "matcher", - args = {java.lang.CharSequence.class} - ) - }) public void testSOLQuant() { Pattern pat = Pattern.compile("$*", Pattern.MULTILINE); Matcher mat = pat.matcher("\n\n"); @@ -1098,12 +803,6 @@ public void testZeroSymbols() { assertEquals(3, counter); } - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile(java.lang.String) method.", - method = "compile", - args = {java.lang.String.class} - ) public void testIllegalEscape() { try { Pattern.compile("\\y"); @@ -1112,31 +811,11 @@ public void testZeroSymbols() { } } - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile(java.lang.String) method.", - method = "compile", - args = {java.lang.String.class} - ) public void testEmptyFamily() { Pattern.compile("\\p{Lower}"); String a = "*"; } - @TestTargets({ - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile(java.lang.String) & matcher(java.lang.CharSequence) methods.", - method = "compile", - args = {java.lang.String.class} - ), - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile(java.lang.String) & matcher(java.lang.CharSequence) methods.", - method = "matcher", - args = {java.lang.CharSequence.class} - ) - }) public void testNonCaptConstr() { // Flags Pattern pat = Pattern.compile("(?i)b*(?-i)a*"); @@ -1206,12 +885,6 @@ public void testZeroSymbols() { } - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile(java.lang.String) method.", - method = "compile", - args = {java.lang.String.class} - ) public void testCorrectReplacementBackreferencedJointSet() { Pattern pat = Pattern.compile("ab(a)*\\1"); pat = Pattern.compile("abc(cd)fg"); @@ -1230,40 +903,12 @@ public void testZeroSymbols() { pat = Pattern.compile("ab(a){1,3}?(c)d"); } - @TestTargets({ - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile(java.lang.String) & matcher(java.lang.CharSequence) methods.", - method = "compile", - args = {java.lang.String.class} - ), - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile(java.lang.String) & matcher(java.lang.CharSequence) methods.", - method = "matcher", - args = {java.lang.CharSequence.class} - ) - }) public void testCompilePatternWithTerminatorMark() { Pattern pat = Pattern.compile("a\u0000\u0000cd"); Matcher mat = pat.matcher("a\u0000\u0000cd"); assertTrue(mat.matches()); } - @TestTargets({ - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile(java.lang.String) & matcher(java.lang.CharSequence) methods.", - method = "compile", - args = {java.lang.String.class} - ), - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile(java.lang.String) & matcher(java.lang.CharSequence) methods.", - method = "matcher", - args = {java.lang.CharSequence.class} - ) - }) public void testAlternations() { String baseString = "|a|bc"; Pattern pat = Pattern.compile(baseString); @@ -1332,20 +977,6 @@ public void testZeroSymbols() { assertTrue(mat.matches()); } - @TestTargets({ - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile(java.lang.String) & matcher(java.lang.CharSequence) methods.", - method = "compile", - args = {java.lang.String.class} - ), - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile(java.lang.String) & matcher(java.lang.CharSequence) methods.", - method = "matcher", - args = {java.lang.CharSequence.class} - ) - }) public void testMatchWithGroups() { String baseString = "jwkerhjwehrkwjehrkwjhrwkjehrjwkehrjkwhrkwehrkwhrkwrhwkhrwkjehr"; String pattern = ".*(..).*\\1.*"; @@ -1357,32 +988,12 @@ public void testZeroSymbols() { assertTrue(Pattern.compile(pattern).matcher(baseString).find()); } - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies split method for empty string.", - method = "split", - args = {java.lang.CharSequence.class} - ) public void testSplitEmptyCharSequence() { String s1 = ""; String[] arr = s1.split(":"); assertEquals(arr.length, 1); } - @TestTargets({ - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "The test verifies the functionality of compile(java.lang.String) & split(java.lang.CharSequence, int) methods.", - method = "compile", - args = {java.lang.String.class} - ), - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "The test verifies the functionality of compile(java.lang.String) & split(java.lang.CharSequence, int) methods.", - method = "split", - args = {java.lang.CharSequence.class, int.class} - ) - }) public void testSplitEndsWithPattern() { assertEquals(",,".split(",", 3).length, 3); assertEquals(",,".split(",", 4).length, 3); @@ -1391,30 +1002,10 @@ public void testZeroSymbols() { assertEquals(Pattern.compile("b").split("ab", -1).length, 2); } - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "The test verifies the functionality of matches(java.lang.String), java.lang.CharSequence) method for case insensitive flags.", - method = "matches", - args = {java.lang.String.class, java.lang.CharSequence.class} - ) public void testCaseInsensitiveFlag() { assertTrue(Pattern.matches("(?i-:AbC)", "ABC")); } - @TestTargets({ - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile(java.lang.String) & matcher(java.lang.CharSequence) methods.", - method = "compile", - args = {java.lang.String.class} - ), - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile(java.lang.String) & matcher(java.lang.CharSequence) methods.", - method = "matcher", - args = {java.lang.CharSequence.class} - ) - }) public void testEmptyGroups() { Pattern pat = Pattern.compile("ab(?>)cda"); Matcher mat = pat.matcher("abcda"); @@ -1429,20 +1020,6 @@ public void testZeroSymbols() { assertTrue(mat.matches()); } - @TestTargets({ - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile(java.lang.String) & compile(java.lang.String, int) methods.", - method = "compile", - args = {java.lang.String.class} - ), - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile(java.lang.String) & compile(java.lang.String, int) methods.", - method = "compile", - args = {java.lang.String.class, int.class} - ) - }) public void testCompileNonCaptGroup() { boolean isCompiled = false; @@ -1461,20 +1038,6 @@ public void testZeroSymbols() { assertTrue(isCompiled); } - @TestTargets({ - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile(java.lang.String) & matcher(java.lang.CharSequence) methods.", - method = "compile", - args = {java.lang.String.class} - ), - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile(java.lang.String) & matcher(java.lang.CharSequence) methods.", - method = "matcher", - args = {java.lang.CharSequence.class} - ) - }) public void testEmbeddedFlags() { String baseString = "(?i)((?s)a)"; String testString = "A"; @@ -1507,12 +1070,6 @@ public void testZeroSymbols() { assertTrue(mat.matches()); } - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile(java.lang.String) method.", - method = "compile", - args = {java.lang.String.class} - ) public void testAltWithFlags() { boolean isCompiled = false; @@ -1525,21 +1082,7 @@ public void testZeroSymbols() { assertTrue(isCompiled); } - @TestTargets({ - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile(java.lang.String) & matcher(java.lang.CharSequence) methods.", - method = "compile", - args = {java.lang.String.class} - ), - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile(java.lang.String) & matcher(java.lang.CharSequence) methods.", - method = "matcher", - args = {java.lang.CharSequence.class} - ) - }) -public void testRestoreFlagsAfterGroup() { + public void testRestoreFlagsAfterGroup() { String baseString = "abc((?x)d) a"; String testString = "abcd a"; Pattern pat = Pattern.compile(baseString); @@ -1552,12 +1095,6 @@ public void testRestoreFlagsAfterGroup() { * Verify if the Pattern support the following character classes: * \p{javaLowerCase} \p{javaUpperCase} \p{javaWhitespace} \p{javaMirrored} */ - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile(java.lang.String) method.", - method = "compile", - args = {java.lang.String.class} - ) public void testCompileCharacterClass() { // Regression for HARMONY-606, 696 Pattern pattern = Pattern.compile("\\p{javaLowerCase}"); @@ -1879,20 +1416,6 @@ public void testRestoreFlagsAfterGroup() { // */} // END android-removed - @TestTargets({ - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile(java.lang.String) & matcher(java.lang.CharSequence) methods.", - method = "compile", - args = {java.lang.String.class} - ), - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile(java.lang.String) & matcher(java.lang.CharSequence) methods.", - method = "matcher", - args = {java.lang.CharSequence.class} - ) - }) public void testRangesWithSurrogatesSupplementary() { String patString = "[abc\uD8D2]"; String testString = "\uD8D2"; @@ -1959,20 +1482,6 @@ public void testRestoreFlagsAfterGroup() { assertTrue(mat.matches()); } - @TestTargets({ - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile(java.lang.String) & matcher(java.lang.CharSequence) methods.", - method = "compile", - args = {java.lang.String.class} - ), - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile(java.lang.String) & matcher(java.lang.CharSequence) methods.", - method = "matcher", - args = {java.lang.CharSequence.class} - ) - }) public void testSequencesWithSurrogatesSupplementary() { String patString = "abcd\uD8D3"; String testString = "abcd\uD8D3\uDFFC"; @@ -2011,24 +1520,6 @@ public void testRestoreFlagsAfterGroup() { assertTrue(mat.find()); } - /** - * s original test was fixed to pass on RI - */ - - @TestTargets({ - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile(java.lang.String) & matcher(java.lang.CharSequence) methods.", - method = "compile", - args = {java.lang.String.class} - ), - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile(java.lang.String) & matcher(java.lang.CharSequence) methods.", - method = "matcher", - args = {java.lang.CharSequence.class} - ) - }) public void testPredefinedClassesWithSurrogatesSupplementary() { String patString = "[123\\D]"; String testString = "a"; @@ -2130,26 +1621,6 @@ public void testRestoreFlagsAfterGroup() { assertTrue(mat.matches()); } - @TestTargets({ - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile(java.lang.String) & compile(java.lang.String, int) matcher(java.lang.CharSequence) methods.", - method = "compile", - args = {java.lang.String.class} - ), - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile(java.lang.String) & compile(java.lang.String, int) matcher(java.lang.CharSequence) methods.", - method = "compile", - args = {java.lang.String.class, int.class} - ), - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile(java.lang.String) & compile(java.lang.String, int) matcher(java.lang.CharSequence) methods.", - method = "matcher", - args = {java.lang.CharSequence.class} - ) - }) public void testDotConstructionWithSurrogatesSupplementary() { String patString = "."; String testString = "\uD9A0\uDE81"; @@ -2186,15 +1657,6 @@ public void testRestoreFlagsAfterGroup() { assertTrue(mat.matches()); } - /** - * s java.util.regex.Pattern.quote(String) - */ - @TestTargetNew( - level = TestLevel.COMPLETE, - notes = "", - method = "quote", - args = {java.lang.String.class} - ) public void test_quoteLjava_lang_String() { for (String aPattern : testPatterns) { Pattern p = Pattern.compile(aPattern); @@ -2211,25 +1673,6 @@ public void testRestoreFlagsAfterGroup() { } } - /** - * s java.util.regex.Pattern.matcher(String, CharSequence) - * coped from test for matches method - */ - - @TestTargets({ - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile(java.lang.String) & matcher(java.lang.CharSequence) methods.", - method = "compile", - args = {java.lang.String.class} - ), - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile(java.lang.String) & matcher(java.lang.CharSequence) methods.", - method = "matcher", - args = {java.lang.CharSequence.class} - ) - }) public void test_matcherLjava_lang_StringLjava_lang_CharSequence() { String[][] posSeq = { { "abb", "ababb", "abababbababb", "abababbababbabababbbbbabb" }, @@ -2258,20 +1701,6 @@ public void testRestoreFlagsAfterGroup() { } } - @TestTargets({ - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile(java.lang.String) & matcher(java.lang.CharSequence) methods.", - method = "compile", - args = {java.lang.String.class} - ), - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile(java.lang.String) & matcher(java.lang.CharSequence) methods.", - method = "matcher", - args = {java.lang.CharSequence.class} - ) - }) public void testQuantifiersWithSurrogatesSupplementary() { String patString = "\uD9A0\uDE81*abc"; String testString = "\uD9A0\uDE81\uD9A0\uDE81abc"; @@ -2284,20 +1713,6 @@ public void testRestoreFlagsAfterGroup() { assertTrue(mat.matches()); } - @TestTargets({ - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile(java.lang.String) & matcher(java.lang.CharSequence) methods.", - method = "compile", - args = {java.lang.String.class} - ), - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile(java.lang.String) & matcher(java.lang.CharSequence) methods.", - method = "matcher", - args = {java.lang.CharSequence.class} - ) - }) public void testAlternationsWithSurrogatesSupplementary() { String patString = "\uDE81|\uD9A0\uDE81|\uD9A0"; String testString = "\uD9A0"; @@ -2318,26 +1733,6 @@ public void testRestoreFlagsAfterGroup() { assertFalse(mat.matches()); } - @TestTargets({ - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile(java.lang.String) & compile(java.lang.String, int) & matcher(java.lang.CharSequence) methods.", - method = "compile", - args = {java.lang.String.class} - ), - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile(java.lang.String) & compile(java.lang.String, int) & matcher(java.lang.CharSequence) methods.", - method = "compile", - args = {java.lang.String.class, int.class} - ), - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "Verifies the functionality of compile(java.lang.String) & compile(java.lang.String, int) & matcher(java.lang.CharSequence) methods.", - method = "matcher", - args = {java.lang.CharSequence.class} - ) - }) public void testGroupsWithSurrogatesSupplementary() { //this pattern matches nothing @@ -2357,32 +1752,12 @@ public void testRestoreFlagsAfterGroup() { /* * Regression test for HARMONY-688 */ - @TestTargets({ - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "The test verifies the functionality of compile(java.lang.String) & matcher(java.lang.CharSequence) methods.", - method = "compile", - args = {java.lang.String.class} - ), - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "The test verifies the functionality of compile(java.lang.String) & matcher(java.lang.CharSequence) methods.", - method = "matcher", - args = {java.lang.CharSequence.class} - ) - }) public void testUnicodeCategoryWithSurrogatesSupplementary() { Pattern p = Pattern.compile("\\p{javaLowerCase}"); Matcher matcher = p.matcher("\uD801\uDC28"); assertTrue(matcher.find()); } - @TestTargetNew( - level = TestLevel.PARTIAL_COMPLETE, - notes = "The test doesn't verify Matcher and should be moved to PatterTest.", - method = "split", - args = {java.lang.CharSequence.class, int.class} - ) public void testSplitEmpty() { Pattern pat = Pattern.compile(""); @@ -2392,12 +1767,6 @@ public void testRestoreFlagsAfterGroup() { assertEquals("", s[0]); } - @TestTargetNew( - level = TestLevel.COMPLETE, - notes = "", - method = "toString", - args = {} - ) public void testToString() { for (int i = 0; i < testPatterns.length; i++) { Pattern p = Pattern.compile(testPatterns[i]); diff --git a/luni/src/test/java/tests/SQLite/BlobTest.java b/luni/src/test/java/tests/SQLite/BlobTest.java index 353916f..8b78550 100644 --- a/luni/src/test/java/tests/SQLite/BlobTest.java +++ b/luni/src/test/java/tests/SQLite/BlobTest.java @@ -103,31 +103,6 @@ public class BlobTest extends SQLiteTest { super.tearDown(); } - /** - * @throws Exception - * @throws IOException - * @tests Blob#Blob() - */ - @TestTargets ( { - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "db.open_blob is not supported also for Stmt, therefore cannot test Blobs", - method = "Blob", - args = {} - ), - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "functional test", - method = "getOutputStream", - args = {} - ), - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "functional test", - method = "getInputStream", - args = {} - ) - }) @KnownFailure("db.open_blob is not supported.") public void testBlob() throws Exception, IOException { byte[] b = new byte[4]; @@ -152,19 +127,6 @@ public class BlobTest extends SQLiteTest { } /** - * @tests Blob#finalize() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "Can not be checked. Should be tested in DX test package.", - method = "finalize", - args = {} - ) - public void testFinalize() { - - } - - /** * @tests Blob.getInputStream() */ @TestTargetNew( @@ -204,26 +166,16 @@ public class BlobTest extends SQLiteTest { } } - /** - * @tests Blob#close() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not clear from spec what should happen when Blob is closed.", - method = "close", - args = {} - ) -// @KnownFailure("Blob does not clean up inputStream.") public void testClose() { - assertNotNull(testBlob); - - testBlob.close(); - // inputStream either null or some error occurs - try { - // TODO This does look a bit weird. Revisit later. - assertNull(testBlob.getInputStream()); - } catch (Throwable e) { - //ok - } + assertNotNull(testBlob); + + testBlob.close(); + // inputStream either null or some error occurs + try { + // TODO This does look a bit weird. Revisit later. + assertNull(testBlob.getInputStream()); + } catch (Throwable e) { + //ok + } } } diff --git a/luni/src/test/java/tests/SQLite/DatabaseTest.java b/luni/src/test/java/tests/SQLite/DatabaseTest.java index f04266b..0422d5e 100644 --- a/luni/src/test/java/tests/SQLite/DatabaseTest.java +++ b/luni/src/test/java/tests/SQLite/DatabaseTest.java @@ -171,18 +171,6 @@ public class DatabaseTest extends SQLiteTest { } /** - * @tests Database#finalize() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "method test", - method = "finalize", - args = {} - ) - public void testFinalize() { - } - - /** * @tests {@link Database#open(String, int)}. */ @TestTargetNew( @@ -512,21 +500,6 @@ public class DatabaseTest extends SQLiteTest { * @throws Exception * @tests {@link Database#busy_handler(BusyHandler)} */ - @TestTargets({ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "method test fails once in a while. Cannot be sure that exception is thrown every time.", - method = "busy_handler", - args = {BusyHandler.class} - ), - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "method test fails once in a while. Cannot be sure that exception is thrown every time.", - method = "busy", - clazz = BusyHandler.class, - args = {java.lang.String.class, int.class} - ) - }) @KnownFailure("method test fails once in a while. "+ "Cannot be sure that exception is thrown in every test execution.") public void testBusy_handler() throws SQLException, Exception { @@ -643,17 +616,7 @@ public class DatabaseTest extends SQLiteTest { } } - /** - * @throws Exception - * @throws SQLException - * @tests {@link Database#busy_timeout(int)} - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "test fails. Cannot be sure that exception is thrown every time.", - method = "busy_timeout", - args = {int.class} - ) + // test fails. Cannot be sure that exception is thrown every time. @KnownFailure("Database does not lock values") public void testBusy_timeout() throws Exception, SQLException { int counter = 0; diff --git a/luni/src/test/java/tests/SQLite/ShellTest.java b/luni/src/test/java/tests/SQLite/ShellTest.java deleted file mode 100644 index f0f4f7c..0000000 --- a/luni/src/test/java/tests/SQLite/ShellTest.java +++ /dev/null @@ -1,147 +0,0 @@ -/* - * Copyright (C) 2008 The Android Open Source Project - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package tests.SQLite; - -import SQLite.Shell; -import dalvik.annotation.TestLevel; -import dalvik.annotation.TestTargetClass; -import dalvik.annotation.TestTargetNew; - -import junit.framework.TestCase; - -import java.io.PrintStream; -import java.io.PrintWriter; - -@TestTargetClass(Shell.class) -public class ShellTest extends TestCase { - - /** - * Test method for {@link SQLite.Shell#Shell(java.io.PrintWriter, java.io.PrintWriter)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "Shell", - args = {PrintWriter.class, PrintWriter.class} - ) - public void testShellPrintWriterPrintWriter() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link SQLite.Shell#Shell(java.io.PrintStream, java.io.PrintStream)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "Shell", - args = {PrintStream.class, PrintStream.class} - ) - public void testShellPrintStreamPrintStream() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link SQLite.Shell#clone()}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "clone", - args = {} - ) - public void testClone() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link SQLite.Shell#sql_quote_dbl(java.lang.String)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "sql_quote_dbl", - args = {String.class} - ) - public void testSql_quote_dbl() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link SQLite.Shell#sql_quote(java.lang.String)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "sql_quote", - args = {String.class} - ) - public void testSql_quote() { - fail("Not yet implemented"); - } - - - /** - * Test method for {@link SQLite.Shell#columns(java.lang.String[])}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "columns", - args = {String[].class} - ) - public void testColumns() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link SQLite.Shell#types(java.lang.String[])}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "types", - args = {String[].class} - ) - public void testTypes() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link SQLite.Shell#newrow(java.lang.String[])}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "newrow", - args = {String[].class} - ) - public void testNewrow() { - fail("Not yet implemented"); - } - - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "main", - args = {String[].class} - ) - public void testMain() { - - } - -} diff --git a/luni/src/test/java/tests/SQLite/StmtTest.java b/luni/src/test/java/tests/SQLite/StmtTest.java index 1dc8552..d512325 100644 --- a/luni/src/test/java/tests/SQLite/StmtTest.java +++ b/luni/src/test/java/tests/SQLite/StmtTest.java @@ -149,19 +149,6 @@ public class StmtTest extends SQLiteTest { } /** - * @tests {@link Stmt#finalize()} - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "method test", - method = "finalize", - args = {} - ) - public void testFinalize() { - - } - - /** * @tests {@link Stmt#prepare()} */ @TestTargetNew( @@ -639,15 +626,6 @@ public class StmtTest extends SQLiteTest { } - /** - * @tests {@link Stmt#bind_zeroblob(int, int)} - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "bind_zeroblob", - args = {int.class, int.class} - ) public void testBind_zeroblob() { try { st.bind_zeroblob(1, 128); @@ -917,16 +895,6 @@ public class StmtTest extends SQLiteTest { } - /** - * @throws Exception - * @tests {@link Stmt#column_bytes(int)} - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "column_bytes", - args = {int.class} - ) public void testColumn_bytes() throws Exception { db.exec("create table B(id integer primary key, val blob)",null); @@ -1126,15 +1094,6 @@ public class StmtTest extends SQLiteTest { } } - /** - * @tests {@link Stmt#column_table_name(int)} - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "column_table_name", - args = {int.class} - ) public void testColumn_table_name() { try { st = db.prepare("select * from " + DatabaseCreator.SIMPLE_TABLE1); @@ -1145,15 +1104,6 @@ public class StmtTest extends SQLiteTest { } } - /** - * @tests {@link Stmt#column_database_name(int)} - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "column_database_name", - args = {int.class} - ) public void testColumn_database_name() { try { st = db.prepare("insert into " + DatabaseCreator.SIMPLE_TABLE1 @@ -1229,15 +1179,6 @@ public class StmtTest extends SQLiteTest { .column_decltype(29))); } - /** - * @tests {@link Stmt#column_origin_name(int)} - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "column_origin_name", - args = {int.class} - ) public void testColumn_origin_name() { try { st = db.prepare("select * from " + DatabaseCreator.SIMPLE_TABLE1); diff --git a/luni/src/test/java/tests/api/java/lang/reflect/ConstructorTest.java b/luni/src/test/java/tests/api/java/lang/reflect/ConstructorTest.java index 35cb92d..932315c 100644 --- a/luni/src/test/java/tests/api/java/lang/reflect/ConstructorTest.java +++ b/luni/src/test/java/tests/api/java/lang/reflect/ConstructorTest.java @@ -17,10 +17,6 @@ package tests.api.java.lang.reflect; -import dalvik.annotation.TestLevel; -import dalvik.annotation.TestTargetNew; -import dalvik.annotation.TestTargetClass; - import java.lang.annotation.Annotation; import java.lang.annotation.ElementType; import java.lang.annotation.Retention; @@ -34,17 +30,6 @@ import java.util.Arrays; import java.util.HashSet; import java.util.Set; -@TestTargetClass( - value = Constructor.class, - untestedMethods = { - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - method = "isSynthetic", - args = {}, - notes = "Since code which relies on synthetic members is not " + - "portable, this should not be tested" - ) - }) public class ConstructorTest extends junit.framework.TestCase { @@ -118,15 +103,6 @@ public class ConstructorTest extends junit.framework.TestCase { // } // } - /** - * @tests java.lang.reflect.Constructor#getDeclaredAnnotations() - */ - @TestTargetNew( - level = TestLevel.COMPLETE, - notes = "", - method = "getParameterAnnotations", - args = {} - ) public void test_getParameterAnnotations() throws Exception { Constructor<ConstructorTestHelper> ctor1 = ConstructorTestHelper.class .getConstructor(Object.class); @@ -147,15 +123,6 @@ public class ConstructorTest extends junit.framework.TestCase { } - /** - * @tests java.lang.reflect.Constructor#getDeclaredAnnotations() - */ - @TestTargetNew( - level = TestLevel.COMPLETE, - notes = "", - method = "getDeclaredAnnotations", - args = {} - ) public void test_getDeclaredAnnotations() throws Exception { Constructor<ConstructorTestHelper> ctor1 = null; ctor1 = ConstructorTestHelper.class.getConstructor(new Class[0]); @@ -172,15 +139,6 @@ public class ConstructorTest extends junit.framework.TestCase { .contains(ConstructorTestAnnotationRuntime1.class)); } - /** - * @tests java.lang.reflect.Constructor#isVarargs() - */ - @TestTargetNew( - level = TestLevel.COMPLETE, - notes = "", - method = "isVarArgs", - args = {} - ) public void test_isVarArgs() throws Exception { Constructor<ConstructorTestHelper> varArgCtor = ConstructorTestHelper.class .getConstructor(String[].class); @@ -192,15 +150,6 @@ public class ConstructorTest extends junit.framework.TestCase { nonVarArgCtor.isVarArgs()); } - /** - * @tests java.lang.reflect.Constructor#hashCode() - */ - @TestTargetNew( - level = TestLevel.COMPLETE, - notes = "", - method = "hashCode", - args = {} - ) public void test_hashCode() throws Exception { Constructor<ConstructorTestHelper> constructor = ConstructorTestHelper.class .getConstructor(); @@ -210,16 +159,7 @@ public class ConstructorTest extends junit.framework.TestCase { .hashCode()); } - /** - * @tests java.lang.reflect.Constructor#toGenericString() - */ @SuppressWarnings("unchecked") - @TestTargetNew( - level = TestLevel.COMPLETE, - notes = "", - method = "toGenericString", - args = {} - ) public void test_toGenericString() throws Exception { Constructor<GenericConstructorTestHelper> genericCtor = GenericConstructorTestHelper.class .getConstructor(Object.class, Object.class); @@ -235,15 +175,6 @@ public class ConstructorTest extends junit.framework.TestCase { ctor.toGenericString()); } - /** - * @tests java.lang.reflect.Constructor#equals(java.lang.Object) - */ - @TestTargetNew( - level = TestLevel.COMPLETE, - notes = "", - method = "equals", - args = {java.lang.Object.class} - ) public void test_equalsLjava_lang_Object() { Constructor<ConstructorTestHelper> ctor1 = null, ctor2 = null; try { @@ -256,15 +187,6 @@ public class ConstructorTest extends junit.framework.TestCase { assertTrue("Different Contructors returned equal", !ctor1.equals(ctor2)); } - /** - * @tests java.lang.reflect.Constructor#getDeclaringClass() - */ - @TestTargetNew( - level = TestLevel.COMPLETE, - notes = "", - method = "getDeclaringClass", - args = {} - ) public void test_getDeclaringClass() { boolean val = false; try { @@ -277,15 +199,6 @@ public class ConstructorTest extends junit.framework.TestCase { assertTrue("Returned incorrect declaring class", val); } - /** - * @tests java.lang.reflect.Constructor#getExceptionTypes() - */ - @TestTargetNew( - level = TestLevel.COMPLETE, - notes = "", - method = "getExceptionTypes", - args = {} - ) public void test_getExceptionTypes() { // Test for method java.lang.Class [] // java.lang.reflect.Constructor.getExceptionTypes() @@ -304,15 +217,6 @@ public class ConstructorTest extends junit.framework.TestCase { assertTrue("Returned incorrect exception", exceptions[0].equals(ex)); } - /** - * @tests java.lang.reflect.Constructor#getModifiers() - */ - @TestTargetNew( - level = TestLevel.COMPLETE, - notes = "", - method = "getModifiers", - args = {} - ) public void test_getModifiers() { // Test for method int java.lang.reflect.Constructor.getModifiers() int mod = 0; @@ -350,15 +254,6 @@ public class ConstructorTest extends junit.framework.TestCase { } } - /** - * @tests java.lang.reflect.Constructor#getName() - */ - @TestTargetNew( - level = TestLevel.COMPLETE, - notes = "", - method = "getName", - args = {} - ) public void test_getName() { // Test for method java.lang.String // java.lang.reflect.Constructor.getName() @@ -376,15 +271,6 @@ public class ConstructorTest extends junit.framework.TestCase { } } - /** - * @tests java.lang.reflect.Constructor#getParameterTypes() - */ - @TestTargetNew( - level = TestLevel.COMPLETE, - notes = "", - method = "getParameterTypes", - args = {} - ) public void test_getParameterTypes() { // Test for method java.lang.Class [] // java.lang.reflect.Constructor.getParameterTypes() @@ -413,15 +299,6 @@ public class ConstructorTest extends junit.framework.TestCase { assertTrue("Incorrect parameter returned", types[0].equals(parms[0])); } - /** - * @tests java.lang.reflect.Constructor#getGenericParameterTypes() - */ - @TestTargetNew( - level = TestLevel.COMPLETE, - notes = "", - method = "getGenericParameterTypes", - args = {} - ) @SuppressWarnings("unchecked") public void test_getGenericParameterTypes() { Type[] types = null; @@ -463,15 +340,6 @@ public class ConstructorTest extends junit.framework.TestCase { ((TypeVariable)types[1]).getName()); } - /** - * @tests java.lang.reflect.Constructor#getGenericParameterTypes() - */ - @TestTargetNew( - level = TestLevel.COMPLETE, - notes = "", - method = "getGenericExceptionTypes", - args = {} - ) @SuppressWarnings("unchecked") public void test_getGenericExceptionTypes() { Type[] types = null; @@ -504,16 +372,6 @@ public class ConstructorTest extends junit.framework.TestCase { } - - /** - * @tests java.lang.reflect.Constructor#newInstance(java.lang.Object[]) - */ - @TestTargetNew( - level = TestLevel.COMPLETE, - notes = "", - method = "newInstance", - args = {java.lang.Object[].class} - ) public void test_newInstance$Ljava_lang_Object() { // Test for method java.lang.Object // java.lang.reflect.Constructor.newInstance(java.lang.Object []) @@ -529,15 +387,6 @@ public class ConstructorTest extends junit.framework.TestCase { assertEquals("improper instance created", 99, test.check()); } - /** - * @tests java.lang.reflect.Constructor#toString() - */ - @TestTargetNew( - level = TestLevel.COMPLETE, - notes = "", - method = "toString", - args = {} - ) public void test_toString() { // Test for method java.lang.String // java.lang.reflect.Constructor.toString() @@ -559,15 +408,6 @@ public class ConstructorTest extends junit.framework.TestCase { "public tests.api.java.lang.reflect.ConstructorTest$ConstructorTestHelper(java.lang.Object)")); } - /** - * @tests java.lang.reflect.Constructor#getConstructor((Class[]) null) - */ - @TestTargetNew( - level = TestLevel.COMPLETE, - notes = "", - method = "getConstructor", - args = {} - ) public void test_getConstructor() throws Exception { // Passing new Class[0] should be equivalent to (Class[]) null. Class<ConstructorTestHelper> c2 = ConstructorTestHelper.class; diff --git a/luni/src/test/java/tests/api/javax/net/ssl/SSLEngineTest.java b/luni/src/test/java/tests/api/javax/net/ssl/SSLEngineTest.java index d8d186e..e2e93ab 100644 --- a/luni/src/test/java/tests/api/javax/net/ssl/SSLEngineTest.java +++ b/luni/src/test/java/tests/api/javax/net/ssl/SSLEngineTest.java @@ -764,12 +764,6 @@ public class SSLEngineTest extends TestCase { * int length, ByteBuffer dst) * Exception case: SSLException should be thrown. */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "wrap cannot be forced to fail", - method = "wrap", - args = {ByteBuffer[].class, int.class, int.class, ByteBuffer.class} - ) public void test_wrap_01() throws IOException, InterruptedException { prepareEngines(); doHandshake(); @@ -780,7 +774,7 @@ public class SSLEngineTest extends TestCase { try { @SuppressWarnings("unused") SSLEngineResult result = clientEngine.engine.wrap(new ByteBuffer[] { bbs }, 0, 1, bbd); - //fail("SSLException wasn't thrown"); + fail("SSLException wasn't thrown"); } catch (SSLException ex) { //expected } @@ -1350,12 +1344,6 @@ public class SSLEngineTest extends TestCase { * @tests javax.net.ssl.SSLEngine#wrap(ByteBuffer src, ByteBuffer dst) * SSLException should be thrown. */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "wrap cannot be forced to produce SSLException", - method = "wrap", - args = {ByteBuffer.class, ByteBuffer.class} - ) public void test_wrap_ByteBuffer_ByteBuffer_01() throws IOException, InterruptedException { prepareEngines(); doHandshake(); @@ -1364,7 +1352,7 @@ public class SSLEngineTest extends TestCase { try { clientEngine.engine.wrap(bbs, bbd); - //fail("SSLException wasn't thrown"); + fail("SSLException wasn't thrown"); } catch (SSLException ex) { //expected } diff --git a/luni/src/test/java/tests/api/javax/security/cert/CertificateTest.java b/luni/src/test/java/tests/api/javax/security/cert/CertificateTest.java index 14417a9..852a052 100644 --- a/luni/src/test/java/tests/api/javax/security/cert/CertificateTest.java +++ b/luni/src/test/java/tests/api/javax/security/cert/CertificateTest.java @@ -40,19 +40,6 @@ import javax.security.cert.Certificate; import javax.security.cert.CertificateEncodingException; import javax.security.cert.CertificateException; -/** - */ -@TestTargetClass( - value = Certificate.class, - untestedMethods = { - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not specific enough for black-box testing", - method = "toString", - args = {} - ) - } -) public class CertificateTest extends TestCase { /** diff --git a/luni/src/test/java/tests/java/security/SecureClassLoaderTest.java b/luni/src/test/java/tests/java/security/SecureClassLoaderTest.java index 5e6c021..9a0761b 100644 --- a/luni/src/test/java/tests/java/security/SecureClassLoaderTest.java +++ b/luni/src/test/java/tests/java/security/SecureClassLoaderTest.java @@ -23,9 +23,6 @@ package tests.java.security; import dalvik.annotation.KnownFailure; -import dalvik.annotation.TestLevel; -import dalvik.annotation.TestTargetClass; -import dalvik.annotation.TestTargetNew; import junit.framework.TestCase; @@ -38,25 +35,7 @@ import java.security.PermissionCollection; import java.security.ProtectionDomain; import java.security.SecureClassLoader; import java.security.cert.Certificate; -@TestTargetClass(value=SecureClassLoader.class, - untestedMethods={ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "cannot be tested", - method = "defineClass", - args = { - java.lang.String.class, byte[].class, int.class, - int.class, java.security.CodeSource.class} - ), - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "cannot be tested", - method = "defineClass", - args = { - java.lang.String.class, java.nio.ByteBuffer.class, - java.security.CodeSource.class} - ) -}) + /** * Unit test for SecureClassLoader. * @@ -186,15 +165,6 @@ public class SecureClassLoaderTest extends TestCase { (byte) 0x00, (byte) 0x00, (byte) 0x00, (byte) 0x02, (byte) 0x00, (byte) 0x21, }; - /** - * Tests SecureClassLoader(ClassLoader) - */ - @TestTargetNew( - level = TestLevel.COMPLETE, - notes = "Verification with null parameter missed", - method = "SecureClassLoader", - args = {java.lang.ClassLoader.class} - ) @KnownFailure("Android doesn't allow null parent.") public void testSecureClassLoaderClassLoader() throws Exception { URL[] urls = new URL[] { new URL("http://localhost") }; @@ -208,15 +178,6 @@ public class SecureClassLoaderTest extends TestCase { } } - /** - * Tests getPermission - */ - @TestTargetNew( - level = TestLevel.SUFFICIENT, - notes = "", - method = "getPermissions", - args = {java.security.CodeSource.class} - ) public void testGetPermissions() throws Exception { URL url = new URL("http://localhost"); CodeSource cs = new CodeSource(url, (Certificate[]) null); @@ -228,12 +189,6 @@ public class SecureClassLoaderTest extends TestCase { // /** // * Tests defineClass(String, byte[], int, int, CodeSource) // */ -// @TestTargetNew( -// level = TestLevel.NOT_FEASIBLE, -// notes = "ClassFormatError, IndexOutOfBoundsException, SecurityException checking missed", -// method = "defineClass", -// args = {java.lang.String.class, byte[].class, int.class, int.class, java.security.CodeSource.class} -// ) // public void _testDefineClassStringbyteArrayintintCodeSource() { // MyClassLoader ldr = new MyClassLoader(); // Class klass = ldr.define(null, klassData, 0, klassData.length, null); @@ -243,12 +198,6 @@ public class SecureClassLoaderTest extends TestCase { // /** // * Tests defineClass(String, ByteBuffer, CodeSource) // */ -// @TestTargetNew( -// level = TestLevel.NOT_FEASIBLE, -// notes = "ClassFormatError, SecurityException checking missed", -// method = "defineClass", -// args = {java.lang.String.class, java.nio.ByteBuffer.class, java.security.CodeSource.class} -// ) // public void _testDefineClassStringByteBufferCodeSource() { // MyClassLoader ldr = new MyClassLoader(); // ByteBuffer bbuf = ByteBuffer.wrap(klassData); diff --git a/luni/src/test/java/tests/java/sql/DatabaseMetaDataNotSupportedTest.java b/luni/src/test/java/tests/java/sql/DatabaseMetaDataNotSupportedTest.java index 459a06e..799ab55 100644 --- a/luni/src/test/java/tests/java/sql/DatabaseMetaDataNotSupportedTest.java +++ b/luni/src/test/java/tests/java/sql/DatabaseMetaDataNotSupportedTest.java @@ -132,28 +132,10 @@ public class DatabaseMetaDataNotSupportedTest extends TestCase { /** * @tests java.sql.DatabaseMetaData#allProceduresAreCallable() */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "Granting not supported.", - method = "allProceduresAreCallable", - args = {} - ) public void test_allProceduresAreCallable() throws SQLException { - // NOT_FEASIBLE: SQLITE does not implement this functionality assertFalse(meta.allProceduresAreCallable()); } - /** - * @tests {@link java.sql.DatabaseMetaData#allTablesAreSelectable()} - * - * // NOT_FEASIBLE GRANT and REVOKE are not supported - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "test fails. GRANT and REVOKE not supported", - method = "allTablesAreSelectable", - args = {} - ) @KnownFailure("Not supported ops applied") public void test_allTablesAreSelectable() throws SQLException { // grant SELECT privileges @@ -198,57 +180,29 @@ public class DatabaseMetaDataNotSupportedTest extends TestCase { /** * @tests java.sql.DatabaseMetaData#dataDefinitionCausesTransactionCommit() */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "dataDefinitionCausesTransactionCommit", - args = {} - ) - public void test_dataDefinitionCausesTransactionCommit() - throws SQLException { + public void test_dataDefinitionCausesTransactionCommit() throws SQLException { // NOT_FEASIBLE: SQLITE does not implement this functionality } /** * @tests java.sql.DatabaseMetaData#dataDefinitionIgnoredInTransactions() */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "dataDefinitionIgnoredInTransactions", - args = {} - ) public void test_dataDefinitionIgnoredInTransactions() throws SQLException { - // NOT_FEASIBLE: SQLITE does not implement this functionality assertFalse(meta.dataDefinitionIgnoredInTransactions()); } /** * @tests java.sql.DatabaseMetaData#deletesAreDetected(int) */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "deletesAreDetected", - args = {int.class} - ) public void test_deletesAreDetectedI() throws SQLException { - // NOT_FEASIBLE: SQLITE does not implement this functionality assertFalse(meta.deletesAreDetected(0)); } /** * @tests java.sql.DatabaseMetaData#doesMaxRowSizeIncludeBlobs() */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "doesMaxRowSizeIncludeBlobs", - args = {} - ) @KnownFailure("not supported") public void test_doesMaxRowSizeIncludeBlobs() throws SQLException { - // NOT_FEASIBLE: SQLITE does not implement this functionality assertFalse(meta.doesMaxRowSizeIncludeBlobs()); } @@ -256,26 +210,10 @@ public class DatabaseMetaDataNotSupportedTest extends TestCase { * @tests java.sql.DatabaseMetaData #getAttributes(java.lang.String, * java.lang.String, java.lang.String, java.lang.String) */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "getAttributes", - args = {java.lang.String.class, java.lang.String.class, java.lang.String.class, java.lang.String.class} - ) public void test_getAttributesLjava_lang_StringLjava_lang_StringLjava_lang_StringLjava_lang_String() throws SQLException { - // NOT_FEASIBLE: SQLITE does not implement this functionality } - /** - * @tests java.sql.DatabaseMetaData#getCatalogs() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported. not supported. Received result wasn't checked.", - method = "getCatalogs", - args = {} - ) public void test_getCatalogs() throws SQLException { ResultSet rs = meta.getCatalogs(); // NOT_FEASIBLE getCatalog is not supported @@ -332,18 +270,6 @@ public class DatabaseMetaDataNotSupportedTest extends TestCase { } - /** - * @tests {@link java.sql.DatabaseMetaData #getIndexInfo(java.lang.String, - * java.lang.String, java.lang.String, boolean, boolean)} - * - * NOT_FEASIBLE getCatalog is not supported - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported. not supported. Received result wasn't checked.", - method = "getIndexInfo", - args = {java.lang.String.class, java.lang.String.class, java.lang.String.class, boolean.class, boolean.class} - ) @KnownFailure("not supported") public void test_getIndexInfoLjava_lang_StringLjava_lang_StringLjava_lang_StringZZ() throws SQLException { @@ -389,18 +315,6 @@ public class DatabaseMetaDataNotSupportedTest extends TestCase { rs.close(); } - /** - * @tests {@link java.sql.DatabaseMetaData #getColumnPrivileges(java.lang.String, - * java.lang.String, java.lang.String, java.lang.String)} - * - * NOT_FEASIBLE GRANT is not supported - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported. Received result wasn't checked.", - method = "getColumnPrivileges", - args = {java.lang.String.class, java.lang.String.class, java.lang.String.class, java.lang.String.class} - ) @KnownFailure("not supported. Privileges are not supported.") public void test_getColumnPrivilegesLjava_lang_StringLjava_lang_StringLjava_lang_StringLjava_lang_String() throws SQLException { @@ -449,18 +363,6 @@ public class DatabaseMetaDataNotSupportedTest extends TestCase { } - /** - * @tests {@link java.sql.DatabaseMetaData #getExportedKeys(java.lang.String, - * java.lang.String, java.lang.String)} - * - * NOT_FEASIBLE foreign keys are not supported - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported. not supported. Received result wasn't checked.", - method = "getExportedKeys", - args = {java.lang.String.class, java.lang.String.class, java.lang.String.class} - ) @KnownFailure("not supported") public void test_getExportedKeysLjava_lang_StringLjava_lang_StringLjava_lang_String() throws SQLException { @@ -513,32 +415,11 @@ public class DatabaseMetaDataNotSupportedTest extends TestCase { rs.close(); } - /** - * @tests java.sql.DatabaseMetaData #getProcedureColumns(java.lang.String, - * java.lang.String, java.lang.String, java.lang.String) - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "getProcedureColumns", - args = {java.lang.String.class, java.lang.String.class, java.lang.String.class, java.lang.String.class} - ) public void test_getProcedureColumnsLjava_lang_StringLjava_lang_StringLjava_lang_StringLjava_lang_String() throws SQLException { - // NOT_FEASIBLE: SQLITE does not implement this functionality meta.getProcedureColumns("", "", "", ""); } - /** - * @tests java.sql.DatabaseMetaData #getProcedures(java.lang.String, - * java.lang.String, java.lang.String) - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "getProcedures", - args = {java.lang.String.class, java.lang.String.class, java.lang.String.class} - ) public void test_getProceduresLjava_lang_StringLjava_lang_StringLjava_lang_String() throws SQLException { // NOT_FEASIBLE: SQLITE does not implement this functionality @@ -596,48 +477,16 @@ public class DatabaseMetaDataNotSupportedTest extends TestCase { } } - /** - * @tests java.sql.DatabaseMetaData #getSuperTables(java.lang.String, - * java.lang.String, java.lang.String) - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "getSuperTables", - args = {java.lang.String.class, java.lang.String.class, java.lang.String.class} - ) public void test_getSuperTablesLjava_lang_StringLjava_lang_StringLjava_lang_String() throws SQLException { // NOT_FEASIBLE: SQLITE does not implement this functionality } - /** - * @tests java.sql.DatabaseMetaData #getSuperTypes(java.lang.String, - * java.lang.String, java.lang.String) - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "getSuperTypes", - args = {java.lang.String.class, java.lang.String.class, java.lang.String.class} - ) public void test_getSuperTypesLjava_lang_StringLjava_lang_StringLjava_lang_String() throws SQLException { // NOT_FEASIBLE: SQLITE does not implement this functionality } - /** - * @tests java.sql.DatabaseMetaData #getTablePrivileges(java.lang.String, - * java.lang.String, java.lang.String) - * - * NOT_FEASIBLE GRANT is not supported - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported. Received result wasn't checked.", - method = "getTablePrivileges", - args = {java.lang.String.class, java.lang.String.class, java.lang.String.class} - ) @KnownFailure("not supported. Privileges are not supported.") public void test_getTablePrivilegesLjava_lang_StringLjava_lang_StringLjava_lang_String() throws SQLException { @@ -734,33 +583,11 @@ public class DatabaseMetaDataNotSupportedTest extends TestCase { privileges.close(); } - /** - * @tests java.sql.DatabaseMetaData #getUDTs(java.lang.String, - * java.lang.String, java.lang.String, int[]) - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "getUDTs", - args = {java.lang.String.class, java.lang.String.class, java.lang.String.class, int[].class} - ) public void test_getUDTsLjava_lang_StringLjava_lang_StringLjava_lang_String$I() throws SQLException { // NOT_FEASIBLE: JDBC does not implement this functionality } - /** - * @tests java.sql.DatabaseMetaData #getVersionColumns(java.lang.String, - * java.lang.String, java.lang.String) - * - * NOT_FEASIBLE trigger is not supported - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported. Received result wasn't checked.Triggers not supported", - method = "getVersionColumns", - args = {java.lang.String.class, java.lang.String.class, java.lang.String.class} - ) @KnownFailure("Not supported ops applied") public void test_getVersionColumnsLjava_lang_StringLjava_lang_StringLjava_lang_String() throws SQLException { @@ -809,88 +636,28 @@ public class DatabaseMetaDataNotSupportedTest extends TestCase { } } - /** - * @tests java.sql.DatabaseMetaData#locatorsUpdateCopy() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "locatorsUpdateCopy", - args = {} - ) @KnownFailure("not supported") public void test_locatorsUpdateCopy() throws SQLException { - // NOT_FEASIBLE: SQLITE does not implement this functionality assertFalse(meta.locatorsUpdateCopy()); } - /** - * @tests java.sql.DatabaseMetaData#nullPlusNonNullIsNull() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "nullPlusNonNullIsNull", - args = {} - ) public void test_nullPlusNonNullIsNull() throws SQLException { - // NOT_FEASIBLE: SQLITE does not implement this functionality assertFalse(meta.nullPlusNonNullIsNull()); } - /** - * @tests java.sql.DatabaseMetaData#nullsAreSortedAtEnd() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "nullsAreSortedAtEnd", - args = {} - ) public void test_nullsAreSortedAtEnd() throws SQLException { - // NOT_FEASIBLE: SQLITE does not implement this functionality assertFalse(meta.nullsAreSortedAtEnd()); } - /** - * @tests java.sql.DatabaseMetaData#nullsAreSortedAtStart() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "nullsAreSortedAtStart", - args = {} - ) public void test_nullsAreSortedAtStart() throws SQLException { - // NOT_FEASIBLE: SQLITE does not implement this functionality assertFalse(meta.nullsAreSortedAtStart()); } - /** - * @tests java.sql.DatabaseMetaData#nullsAreSortedHigh() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "nullsAreSortedHigh", - args = {} - ) public void test_nullsAreSortedHigh() throws SQLException { - // NOT_FEASIBLE: SQLITE does not implement this functionality assertFalse(meta.nullsAreSortedHigh()); } - /** - * @tests java.sql.DatabaseMetaData#nullsAreSortedLow() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "nullsAreSortedLow", - args = {} - ) public void test_nullsAreSortedLow() throws SQLException { - // NOT_FEASIBLE: SQLITE does not implement this functionality assertFalse(meta.nullsAreSortedLow()); } @@ -955,645 +722,191 @@ public class DatabaseMetaDataNotSupportedTest extends TestCase { meta.ownUpdatesAreVisible(100)); } - /** - * @tests java.sql.DatabaseMetaData#storesLowerCaseIdentifiers() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "storesLowerCaseIdentifiers", - args = {} - ) public void test_storesLowerCaseIdentifiers() throws SQLException { assertFalse(meta.storesLowerCaseIdentifiers()); } - /** - * @tests java.sql.DatabaseMetaData#storesLowerCaseQuotedIdentifiers() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "storesLowerCaseQuotedIdentifiers", - args = {} - ) public void test_storesLowerCaseQuotedIdentifiers() throws SQLException { assertFalse(meta.storesLowerCaseQuotedIdentifiers()); } - /** - * @tests java.sql.DatabaseMetaData#storesUpperCaseIdentifiers() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "storesUpperCaseIdentifiers", - args = {} - ) public void test_storesUpperCaseIdentifiers() throws SQLException { - // NOT_FEASIBLE: SQLITE does not implement this functionality assertFalse(meta.storesUpperCaseIdentifiers()); } - /** - * @tests java.sql.DatabaseMetaData#storesUpperCaseQuotedIdentifiers() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "storesUpperCaseQuotedIdentifiers", - args = {} - ) public void test_storesUpperCaseQuotedIdentifiers() throws SQLException { - // NOT_FEASIBLE: SQLITE does not implement this functionality assertFalse(meta.storesUpperCaseQuotedIdentifiers()); } - /** - * @tests java.sql.DatabaseMetaData#supportsANSI92EntryLevelSQL() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "supportsANSI92EntryLevelSQL", - args = {} - ) @KnownFailure("not supported") public void test_supportsANSI92EntryLevelSQL() throws SQLException { - // NOT_FEASIBLE: SQLITE does not implement this functionality assertFalse(meta.supportsANSI92EntryLevelSQL()); } - /** - * @tests java.sql.DatabaseMetaData#supportsANSI92FullSQL() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "supportsANSI92FullSQL", - args = {} - ) public void test_supportsANSI92FullSQL() throws SQLException { - // NOT_FEASIBLE: SQLITE does not implement this functionality assertFalse(meta.supportsANSI92FullSQL()); } - /** - * @tests java.sql.DatabaseMetaData#supportsANSI92IntermediateSQL() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "supportsANSI92IntermediateSQL", - args = {} - ) public void test_supportsANSI92IntermediateSQL() throws SQLException { - // NOT_FEASIBLE: SQLITE does not implement this functionality assertFalse(meta.supportsANSI92IntermediateSQL()); } - /** - * @tests java.sql.DatabaseMetaData#supportsAlterTableWithAddColumn() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "supportsAlterTableWithAddColumn", - args = {} - ) public void test_supportsAlterTableWithAddColumn() throws SQLException { - // NOT_FEASIBLE: SQLITE does not implement this functionality assertFalse(meta.supportsAlterTableWithAddColumn()); } - /** - * @tests java.sql.DatabaseMetaData#supportsAlterTableWithDropColumn() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "supportsAlterTableWithDropColumn", - args = {} - ) public void test_supportsAlterTableWithDropColumn() throws SQLException { - // NOT_FEASIBLE: SQLITE does not implement this functionality assertFalse(meta.supportsAlterTableWithDropColumn()); - } public void test_supportsBatchUpdates() throws SQLException { assertTrue(meta.supportsBatchUpdates()); } - /** - * @tests java.sql.DatabaseMetaData#supportsCatalogsInDataManipulation() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "supportsCatalogsInDataManipulation", - args = {} - ) public void test_supportsCatalogsInDataManipulation() throws SQLException { - // NOT_FEASIBLE: SQLITE does not implement this functionality assertFalse(meta.supportsCatalogsInDataManipulation()); } - /** - * @tests java.sql.DatabaseMetaData#supportsCatalogsInIndexDefinitions() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "supportsCatalogsInIndexDefinitions", - args = {} - ) public void test_supportsCatalogsInIndexDefinitions() throws SQLException { - // NOT_FEASIBLE: SQLITE does not implement this functionality assertFalse(meta.supportsCatalogsInIndexDefinitions()); } - /** - * @tests java.sql.DatabaseMetaData#supportsCatalogsInPrivilegeDefinitions() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "supportsCatalogsInPrivilegeDefinitions", - args = {} - ) - public void test_supportsCatalogsInPrivilegeDefinitions() - throws SQLException { - // NOT_FEASIBLE: SQLITE does not implement this functionality + public void test_supportsCatalogsInPrivilegeDefinitions() throws SQLException { assertFalse(meta.supportsCatalogsInPrivilegeDefinitions()); } - /** - * @tests java.sql.DatabaseMetaData#supportsCatalogsInProcedureCalls() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "supportsCatalogsInProcedureCalls", - args = {} - ) public void test_supportsCatalogsInProcedureCalls() throws SQLException { - // NOT_FEASIBLE: SQLITE does not implement this functionality assertFalse(meta.supportsCatalogsInProcedureCalls()); } - /** - * @tests java.sql.DatabaseMetaData#supportsCatalogsInTableDefinitions() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "supportsCatalogsInTableDefinitions", - args = {} - ) public void test_supportsCatalogsInTableDefinitions() throws SQLException { - // NOT_FEASIBLE: SQLITE does not implement this functionality assertFalse(meta.supportsCatalogsInTableDefinitions()); } - /** - * @tests java.sql.DatabaseMetaData#supportsConvert() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "supportsConvert", - args = {} - ) public void test_supportsConvert() throws SQLException { - // NOT_FEASIBLE: SQLITE does not implement this functionality assertFalse(meta.supportsConvert()); } - /** - * @tests java.sql.DatabaseMetaData#supportsConvert(int, int) - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "supportsConvert", - args = {int.class, int.class} - ) public void test_supportsConvertII() throws SQLException { - // NOT_FEASIBLE: SQLITE does not implement this functionality assertFalse(meta.supportsConvert()); } - /** - * @tests java.sql.DatabaseMetaData#supportsCoreSQLGrammar() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "supportsCoreSQLGrammar", - args = {} - ) public void test_supportsCoreSQLGrammar() throws SQLException { - // NOT_FEASIBLE: SQLITE does not implement this functionality assertFalse(meta.supportsCoreSQLGrammar()); } - /** - * @tests java.sql.DatabaseMetaData#supportsCorrelatedSubqueries() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "supportsCorrelatedSubqueries", - args = {} - ) public void test_supportsCorrelatedSubqueries() throws SQLException { - // NOT_FEASIBLE: SQLITE does not implement this functionality assertFalse(meta.supportsCorrelatedSubqueries()); } - /** - * @tests java.sql.DatabaseMetaData#supportsDataDefinitionAndDataManipulationTransactions() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "supportsDataDefinitionAndDataManipulationTransactions", - args = {} - ) @KnownFailure("not supported") - public void test_supportsDataDefinitionAndDataManipulationTransactions() - throws SQLException { - // NOT_FEASIBLE: SQLITE does not implement this functionality + public void test_supportsDataDefinitionAndDataManipulationTransactions() throws SQLException { assertFalse(meta.supportsDataDefinitionAndDataManipulationTransactions()); } - /** - * @tests java.sql.DatabaseMetaData#supportsDataManipulationTransactionsOnly() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "supportsDataManipulationTransactionsOnly", - args = {} - ) - public void test_supportsDataManipulationTransactionsOnly() - throws SQLException { - // NOT_FEASIBLE: SQLITE does not implement this functionality + public void test_supportsDataManipulationTransactionsOnly() throws SQLException { assertFalse(meta.supportsDataManipulationTransactionsOnly()); } - /** - * @tests java.sql.DatabaseMetaData#supportsDifferentTableCorrelationNames() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "supportsDifferentTableCorrelationNames", - args = {} - ) - public void test_supportsDifferentTableCorrelationNames() - throws SQLException { - // NOT_FEASIBLE: SQLITE does not implement this functionality + public void test_supportsDifferentTableCorrelationNames() throws SQLException { assertFalse(meta.supportsDifferentTableCorrelationNames()); } - - /** - * @tests java.sql.DatabaseMetaData#supportsExtendedSQLGrammar() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "supportsExtendedSQLGrammar", - args = {} - ) public void test_supportsExtendedSQLGrammar() throws SQLException { - // NOT_FEASIBLE: SQLITE does not implement this functionality assertFalse(meta.supportsExtendedSQLGrammar()); } - /** - * @tests java.sql.DatabaseMetaData#supportsFullOuterJoins() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "supportsFullOuterJoins", - args = {} - ) public void test_supportsFullOuterJoins() throws SQLException { - // NOT_FEASIBLE: SQLITE does not implement this functionality assertFalse(meta.supportsFullOuterJoins()); } - /** - * @tests java.sql.DatabaseMetaData#supportsGetGeneratedKeys() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "supportsGetGeneratedKeys", - args = {} - ) public void test_supportsGetGeneratedKeys() throws SQLException { - // NOT_FEASIBLE: SQLITE does not implement this functionality assertFalse(meta.supportsGetGeneratedKeys()); } - /** - * @tests java.sql.DatabaseMetaData#supportsGroupByBeyondSelect() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "supportsGroupByBeyondSelect", - args = {} - ) public void test_supportsGroupByBeyondSelect() throws SQLException { - // NOT_FEASIBLE: SQLITE does not implement this functionality assertFalse(meta.supportsGroupByBeyondSelect()); } - /** - * @tests java.sql.DatabaseMetaData#supportsIntegrityEnhancementFacility() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "supportsIntegrityEnhancementFacility", - args = {} - ) public void test_supportsIntegrityEnhancementFacility() throws SQLException { - // NOT_FEASIBLE: SQLITE does not implement this functionality assertFalse(meta.supportsIntegrityEnhancementFacility()); } - /** - * @tests java.sql.DatabaseMetaData#supportsLikeEscapeClause() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "supportsLikeEscapeClause", - args = {} - ) public void test_supportsLikeEscapeClause() throws SQLException { - // NOT_FEASIBLE: SQLITE does not implement this functionality assertFalse(meta.supportsLikeEscapeClause()); } - /** - * @tests java.sql.DatabaseMetaData#supportsLimitedOuterJoins() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "supportsLimitedOuterJoins", - args = {} - ) public void test_supportsLimitedOuterJoins() throws SQLException { - // NOT_FEASIBLE: SQLITE does not implement this functionality assertFalse(meta.supportsLimitedOuterJoins()); } - /** - * @tests java.sql.DatabaseMetaData#supportsMinimumSQLGrammar() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "supportsMinimumSQLGrammar", - args = {} - ) @KnownFailure("not supported") public void test_supportsMinimumSQLGrammar() throws SQLException { - // NOT_FEASIBLE: SQLITE does not implement this functionality assertFalse(meta.supportsMinimumSQLGrammar()); } - /** - * @tests java.sql.DatabaseMetaData#supportsMixedCaseIdentifiers() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "supportsMixedCaseIdentifiers", - args = {} - ) public void test_supportsMixedCaseIdentifiers() throws SQLException { - // NOT_FEASIBLE: SQLITE does not implement this functionality assertFalse(meta.supportsMixedCaseIdentifiers()); } - /** - * @tests java.sql.DatabaseMetaData#supportsMixedCaseQuotedIdentifiers() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "supportsMixedCaseQuotedIdentifiers", - args = {} - ) public void test_supportsMixedCaseQuotedIdentifiers() throws SQLException { - // NOT_FEASIBLE: SQLITE does not implement this functionality assertFalse(meta.supportsMixedCaseQuotedIdentifiers()); } - /** - * @tests java.sql.DatabaseMetaData#supportsMultipleOpenResults() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "supportsMultipleOpenResults", - args = {} - ) public void test_supportsMultipleOpenResults() throws SQLException { - // NOT_FEASIBLE: SQLITE does not implement this functionality assertFalse(meta.supportsMultipleOpenResults()); } - /** - * @tests java.sql.DatabaseMetaData#supportsMultipleResultSets() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "supportsMultipleResultSets", - args = {} - ) public void test_supportsMultipleResultSets() throws SQLException { - // NOT_FEASIBLE: SQLITE does not implement this functionality assertFalse(meta.supportsMultipleResultSets()); } - /** - * @tests java.sql.DatabaseMetaData#supportsMultipleTransactions() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "supportsMultipleTransactions", - args = {} - ) public void test_supportsMultipleTransactions() throws SQLException { - // NOT_FEASIBLE: SQLITE does not implement this functionality assertFalse(meta.supportsMultipleTransactions()); } - /** - * @tests java.sql.DatabaseMetaData#supportsNamedParameters() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "supportsNamedParameters", - args = {} - ) public void test_supportsNamedParameters() throws SQLException { - // NOT_FEASIBLE: SQLITE does not implement this functionality assertFalse(meta.supportsNamedParameters()); } - /** - * @tests java.sql.DatabaseMetaData#supportsOpenCursorsAcrossCommit() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "supportsOpenCursorsAcrossCommit", - args = {} - ) public void test_supportsOpenCursorsAcrossCommit() throws SQLException { - // NOT_FEASIBLE: SQLITE does not implement this functionality assertFalse(meta.supportsOpenCursorsAcrossCommit()); } - /** - * @tests java.sql.DatabaseMetaData#supportsOpenCursorsAcrossRollback() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "supportsOpenCursorsAcrossRollback", - args = {} - ) public void test_supportsOpenCursorsAcrossRollback() throws SQLException { - // NOT_FEASIBLE: SQLITE does not implement this functionality assertFalse(meta.supportsOpenCursorsAcrossRollback()); } - /** - * @tests java.sql.DatabaseMetaData#supportsOpenStatementsAcrossCommit() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "supportsOpenStatementsAcrossCommit", - args = {} - ) public void test_supportsOpenStatementsAcrossCommit() throws SQLException { - // NOT_FEASIBLE: SQLITE does not implement this functionality assertFalse(meta.supportsOpenStatementsAcrossCommit()); } - /** - * @tests java.sql.DatabaseMetaData#supportsOpenStatementsAcrossRollback() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "supportsOpenStatementsAcrossRollback", - args = {} - ) public void test_supportsOpenStatementsAcrossRollback() throws SQLException { - // NOT_FEASIBLE: SQLITE does not implement this functionality assertFalse(meta.supportsOpenStatementsAcrossRollback()); } - /** - * @tests java.sql.DatabaseMetaData#supportsOuterJoins() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "supportsOuterJoins", - args = {} - ) public void test_supportsOuterJoins() throws SQLException { - // NOT_FEASIBLE: SQLITE does not implement this functionality assertFalse(meta.supportsOuterJoins()); } - /** - * @tests java.sql.DatabaseMetaData#supportsPositionedDelete() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "supportsPositionedDelete", - args = {} - ) public void test_supportsPositionedDelete() throws SQLException { - // NOT_FEASIBLE: SQLITE does not implement this functionality assertFalse(meta.supportsPositionedDelete()); } - /** - * @tests java.sql.DatabaseMetaData#supportsPositionedUpdate() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "supportsPositionedUpdate", - args = {} - ) public void test_supportsPositionedUpdate() throws SQLException { - // NOT_FEASIBLE: SQLITE does not implement this functionality assertFalse(meta.supportsPositionedUpdate()); } - /** - * @tests java.sql.DatabaseMetaData#supportsResultSetConcurrency(int, int) - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "supportsResultSetConcurrency", - args = {int.class, int.class} - ) public void test_supportsResultSetConcurrencyII() throws SQLException { - // NOT_FEASIBLE: SQLITE does not implement this functionality assertFalse(meta.supportsResultSetConcurrency(0,0)); } - /** - * @tests java.sql.DatabaseMetaData#supportsResultSetHoldability(int) - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "supportsResultSetHoldability", - args = {int.class} - ) public void test_supportsResultSetHoldabilityI() throws SQLException { - // NOT_FEASIBLE: SQLITE does not implement this functionality assertFalse(meta.supportsResultSetHoldability(0)); } - /** - * @tests java.sql.DatabaseMetaData#supportsResultSetType(int) - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported. Verification with invalid parameters missed.", - method = "supportsResultSetType", - args = {int.class} - ) @KnownFailure("not supported") public void test_supportsResultSetTypeI() throws SQLException { - // NOT_FEASIBLE not supported assertTrue("database supports TYPE_FORWARD_ONLY type", meta .supportsResultSetType(ResultSet.TYPE_FORWARD_ONLY)); assertFalse("database doesn't support TYPE_SCROLL_INSENSITIVE type", @@ -1604,170 +917,52 @@ public class DatabaseMetaDataNotSupportedTest extends TestCase { .supportsResultSetType(100)); } - /** - * @tests java.sql.DatabaseMetaData#supportsSavepoints() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "supportsSavepoints", - args = {} - ) public void test_supportsSavepoints() throws SQLException { - // NOT_FEASIBLE: SQLITE does not implement this functionality assertFalse(meta.supportsSavepoints()); } - /** - * @tests java.sql.DatabaseMetaData#supportsSchemasInDataManipulation() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "supportsSchemasInDataManipulation", - args = {} - ) public void test_supportsSchemasInDataManipulation() throws SQLException { - // NOT_FEASIBLE: SQLITE does not implement this functionality assertFalse(meta.supportsSchemasInDataManipulation()); } - /** - * @tests java.sql.DatabaseMetaData#supportsSchemasInIndexDefinitions() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "supportsSchemasInIndexDefinitions", - args = {} - ) public void test_supportsSchemasInIndexDefinitions() throws SQLException { - // NOT_FEASIBLE: SQLITE does not implement this functionality assertFalse(meta.supportsSchemasInIndexDefinitions()); } - /** - * @tests java.sql.DatabaseMetaData#supportsSchemasInPrivilegeDefinitions() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "supportsSchemasInPrivilegeDefinitions", - args = {} - ) - public void test_supportsSchemasInPrivilegeDefinitions() - throws SQLException { + public void test_supportsSchemasInPrivilegeDefinitions() throws SQLException { // NOT_FEASIBLE: SQLITE does not implement this functionality } - /** - * @tests java.sql.DatabaseMetaData#supportsSchemasInProcedureCalls() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "supportsSchemasInProcedureCalls", - args = {} - ) public void test_supportsSchemasInProcedureCalls() throws SQLException { - // NOT_FEASIBLE: SQLITE does not implement this functionality assertFalse(meta.supportsSchemasInProcedureCalls()); } - /** - * @tests java.sql.DatabaseMetaData#supportsSchemasInTableDefinitions() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "supportsSchemasInTableDefinitions", - args = {} - ) public void test_supportsSchemasInTableDefinitions() throws SQLException { - // NOT_FEASIBLE: SQLITE does not implement this functionality assertFalse(meta.supportsSchemasInTableDefinitions()); } - /** - * @tests java.sql.DatabaseMetaData#supportsStatementPooling() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "supportsStatementPooling", - args = {} - ) public void test_supportsStatementPooling() throws SQLException { - // NOT_FEASIBLE: SQLITE does not implement this functionality assertFalse(meta.supportsStatementPooling()); } - /** - * @tests java.sql.DatabaseMetaData#supportsStoredProcedures() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "supportsStoredProcedures", - args = {} - ) public void test_supportsStoredProcedures() throws SQLException { - // NOT_FEASIBLE: SQLITE does not implement this functionality assertFalse(meta.supportsStoredProcedures()); } - /** - * @tests java.sql.DatabaseMetaData#supportsSubqueriesInComparisons() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "supportsSubqueriesInComparisons", - args = {} - ) @KnownFailure("not supported") public void test_supportsSubqueriesInComparisons() throws SQLException { - // NOT_FEASIBLE: SQLITE does not implement this functionality assertFalse(meta.supportsSubqueriesInComparisons()); } - /** - * @tests java.sql.DatabaseMetaData#supportsSubqueriesInIns() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "supportsSubqueriesInIns", - args = {} - ) @KnownFailure("not supported") public void test_supportsSubqueriesInIns() throws SQLException { assertFalse(meta.supportsSubqueriesInIns()); } - /** - * @tests java.sql.DatabaseMetaData#supportsSubqueriesInQuantifieds() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "supportsSubqueriesInQuantifieds", - args = {} - ) public void test_supportsSubqueriesInQuantifieds() throws SQLException { - // NOT_FEASIBLE: SQLITE does not implement this functionality assertFalse(meta.supportsSubqueriesInQuantifieds()); } - /** - * @tests java.sql.DatabaseMetaData#supportsTransactions() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "supportsTransactions", - args = {} - ) @KnownFailure("not supported") public void test_supportsTransactions() throws SQLException { assertFalse(meta.supportsTransactions()); @@ -1781,32 +976,12 @@ public class DatabaseMetaDataNotSupportedTest extends TestCase { assertTrue(meta.supportsUnionAll()); } - /** - * @tests java.sql.DatabaseMetaData#usesLocalFilePerTable() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "usesLocalFilePerTable", - args = {} - ) public void test_usesLocalFilePerTable() throws SQLException { - // NOT_FEASIBLE: SQLITE does not implement this functionality assertFalse(meta.usesLocalFilePerTable()); } - /** - * @tests java.sql.DatabaseMetaData#usesLocalFiles() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "usesLocalFiles", - args = {} - ) @KnownFailure("not supported") public void test_usesLocalFiles() throws SQLException { - // NOT_FEASIBLE: SQLITE does not implement this functionality assertFalse(meta.usesLocalFiles()); } diff --git a/luni/src/test/java/tests/java/sql/DatabaseMetaDataTest.java b/luni/src/test/java/tests/java/sql/DatabaseMetaDataTest.java index 09abcd4..d334fc1 100755 --- a/luni/src/test/java/tests/java/sql/DatabaseMetaDataTest.java +++ b/luni/src/test/java/tests/java/sql/DatabaseMetaDataTest.java @@ -774,16 +774,6 @@ public class DatabaseMetaDataTest extends TestCase { } - /** - * @tests java.sql.DatabaseMetaData #getImportedKeys(java.lang.String, - * java.lang.String, java.lang.String) - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "Test fails: Keys are not supported", - method = "getImportedKeys", - args = {java.lang.String.class, java.lang.String.class, java.lang.String.class} - ) @KnownFailure("Keys are not supported: Ticket 91") public void test_getImportedKeysLjava_lang_StringLjava_lang_StringLjava_lang_String() throws SQLException { @@ -1435,18 +1425,7 @@ public class DatabaseMetaDataTest extends TestCase { } - /** - * @tests java.sql.DatabaseMetaData#getUserName() - * - * NOT_FEASIBLE not supported - */ - @TestTargetNew( - level = TestLevel.COMPLETE, - notes = "SQLException checking test fails", - method = "getUserName", - args = {} - ) - @KnownFailure("Ticket 98") + @KnownFailure("Ticket 98") public void s() throws SQLException { assertEquals("Wrong user name", Support_SQL.sqlUser, meta.getUserName()); diff --git a/luni/src/test/java/tests/javax/sql/ConnectionEventListenerTest.java b/luni/src/test/java/tests/javax/sql/ConnectionEventListenerTest.java deleted file mode 100644 index a89b026..0000000 --- a/luni/src/test/java/tests/javax/sql/ConnectionEventListenerTest.java +++ /dev/null @@ -1,42 +0,0 @@ -package tests.javax.sql; - -import dalvik.annotation.TestTargets; -import dalvik.annotation.TestLevel; -import dalvik.annotation.TestTargetNew; -import dalvik.annotation.TestTargetClass; - -import junit.framework.TestCase; - -import javax.sql.ConnectionEvent; -import javax.sql.ConnectionEventListener; - -@TestTargetClass(ConnectionEventListener.class) -public class ConnectionEventListenerTest extends TestCase { - - /** - * @tests {@link javax.sql.ConnectionEventListener#connectionClosed(javax.sql.ConnectionEvent)} - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "connectionClosed", - args = {javax.sql.ConnectionEvent.class} - ) - public void testConnectionClosed() { - fail("Not yet implemented"); // TODO - } - - /** - * @test {@link javax.sql.ConnectionEventListener#connectionErrorOccurred(ConnectionEvent)} - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "connectionErrorOccurred", - args = {javax.sql.ConnectionEvent.class} - ) - public void testConnectionErrorOccurred() { - fail("Not yet implemented"); // TODO - } - -} diff --git a/luni/src/test/java/tests/javax/sql/ConnectionPoolDataSourceTest.java b/luni/src/test/java/tests/javax/sql/ConnectionPoolDataSourceTest.java deleted file mode 100644 index 7dafc46..0000000 --- a/luni/src/test/java/tests/javax/sql/ConnectionPoolDataSourceTest.java +++ /dev/null @@ -1,96 +0,0 @@ -package tests.javax.sql; - -import dalvik.annotation.TestTargets; -import dalvik.annotation.TestLevel; -import dalvik.annotation.TestTargetNew; -import dalvik.annotation.TestTargetClass; - -import junit.framework.TestCase; - -import java.io.PrintWriter; - -import javax.sql.ConnectionPoolDataSource; - - -@TestTargetClass(ConnectionPoolDataSource.class) -public class ConnectionPoolDataSourceTest extends TestCase { - - /** - * @tests {@link javax.sql.ConnectionPoolDataSource#getLoginTimeout()} - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getLoginTimeout", - args = {} - ) - public void testGetLoginTimeout() { - fail("Not yet implemented"); // NOT_FEASIBLE - } - - /** - * @tests {@link javax.sql.ConnectionPoolDataSource#getLogWriter()} - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getLogWriter", - args = {} - ) - public void testGetLogWriter() { - fail("Not yet implemented"); // NOT_FEASIBLE - } - - /** - * @tests {@link javax.sql.ConnectionPoolDataSource#getPooledConnection()} - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getPooledConnection", - args = {} - ) - public void testGetPooledConnection() { - fail("Not yet implemented"); // NOT_FEASIBLE - } - - /** - * @tests {@link javax.sql.ConnectionPoolDataSource#getPooledConnection(String, String)} - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getPooledConnection", - args = {String.class, String.class} - ) - public void testGetPooledConnectionStringString() { - fail("Not yet implemented"); // NOT_FEASIBLE - } - - /** - * @tests {@link javax.sql.ConnectionPoolDataSource#setLoginTimeout(int)} - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setLoginTimeout", - args = {int.class} - ) - public void testSetLoginTimeout() { - fail("Not yet implemented"); // NOT_FEASIBLE - } - - /** - * @tests {@link javax.sql.ConnectionPoolDataSource#setLogWriter(java.io.PrintWriter)} - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setLogWriter", - args = {java.io.PrintWriter.class} - ) - public void testSetLogWriter() { - fail("Not yet implemented"); // NOT_FEASIBLE - } - -} diff --git a/luni/src/test/java/tests/javax/sql/DataSourceTest.java b/luni/src/test/java/tests/javax/sql/DataSourceTest.java deleted file mode 100644 index 30563c9..0000000 --- a/luni/src/test/java/tests/javax/sql/DataSourceTest.java +++ /dev/null @@ -1,96 +0,0 @@ -package tests.javax.sql; - -import dalvik.annotation.TestTargets; -import dalvik.annotation.TestLevel; -import dalvik.annotation.TestTargetNew; -import dalvik.annotation.TestTargetClass; - -import junit.framework.TestCase; - -import java.io.PrintWriter; - -import javax.sql.DataSource; - -@TestTargetClass(DataSource.class) -public class DataSourceTest extends TestCase { - - /** - * @tests {@link javax.sql.DataSource#getConnection()} - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getConnection", - args = {} - ) - public void testGetConnection() { - fail("Not yet implemented"); - } - - /** - * @tests {@link javax.sql.DataSource#getConnection(String, String)} - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getConnection", - args = {java.lang.String.class, java.lang.String.class} - ) - public void testGetConnectionStringString() { - fail("Not yet implemented"); - } - - /** - * @tests {@link javax.sql.DataSource#getLoginTimeout()} - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getLoginTimeout", - args = {} - ) - public void testGetLoginTimeout() { - fail("Not yet implemented"); - } - - /** - * @tests {@link javax.sql.DataSource#getLogWriter()} - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getLogWriter", - args = {} - ) - public void testGetLogWriter() { - fail("Not yet implemented"); - } - - /** - * @tests {@link javax.sql.DataSource#setLoginTimeout(int)} - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setLoginTimeout", - args = {int.class} - ) - public void testSetLoginTimeout() { - fail("Not yet implemented"); - } - - - /** - * @tests {@link javax.sql.DataSource#setLogWriter(java.io.PrintWriter)} - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setLogWriter", - args = {PrintWriter.class} - ) - public void testSetLogWriter() { - fail("Not yet implemented"); - } - -} diff --git a/luni/src/test/java/tests/javax/sql/PooledConnectionTest.java b/luni/src/test/java/tests/javax/sql/PooledConnectionTest.java deleted file mode 100644 index 2902e8b..0000000 --- a/luni/src/test/java/tests/javax/sql/PooledConnectionTest.java +++ /dev/null @@ -1,68 +0,0 @@ -package tests.javax.sql; - -import dalvik.annotation.TestLevel; -import dalvik.annotation.TestTargetClass; -import dalvik.annotation.TestTargetNew; - -import junit.framework.TestCase; - -import javax.sql.ConnectionEventListener; -import javax.sql.PooledConnection; - -@TestTargetClass(PooledConnection.class) -public class PooledConnectionTest extends TestCase { - - /** - * @tests {@link javax.sql.PooledConnection#addConnectionEventListener(javax.sql.ConnectionEventListener)} - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "addConnectionEventListener", - args = {javax.sql.ConnectionEventListener.class} - ) - public void testAddConnectionEventListener() { - fail("Not yet implemented"); - } - - /** - * @tests {@link javax.sql.PooledConnection#close()} - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "close", - args = {} - ) - public void testClose() { - fail("Not yet implemented"); - } - - /** - * @tests {@link javax.sql.PooledConnection#getConnection()} - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getConnection", - args = {} - ) - public void testGetConnection() { - fail("Not yet implemented"); - } - - - /** - * @tests {@link javax.sql.PooledConnection#removeConnectionEventListener(ConnectionEventListener)} - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "removeConnectionEventListener", - args = {javax.sql.ConnectionEventListener.class} - ) - public void testRemoveConnectionEventListener() { - fail("Not yet implemented"); - } - -} diff --git a/luni/src/test/java/tests/javax/sql/RowSetInternalTest.java b/luni/src/test/java/tests/javax/sql/RowSetInternalTest.java deleted file mode 100644 index ff9de34..0000000 --- a/luni/src/test/java/tests/javax/sql/RowSetInternalTest.java +++ /dev/null @@ -1,78 +0,0 @@ -package tests.javax.sql; - -import dalvik.annotation.TestTargets; -import dalvik.annotation.TestLevel; -import dalvik.annotation.TestTargetNew; -import dalvik.annotation.TestTargetClass; - -import junit.framework.TestCase; - -import javax.sql.RowSetInternal; -import javax.sql.RowSetMetaData; - -@TestTargetClass(RowSetInternal.class) -public class RowSetInternalTest extends TestCase { - - /** - * @tests {@link javax.sql.RowSetInternal#getConnection()} - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getConnection", - args = {} - ) - public void testGetConnection() { - fail("Not yet implemented"); - } - - /** - * @tests {@link javax.sql.RowSetInternal#getOriginal()} - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getOriginal", - args = {} - ) - public void testGetOriginal() { - fail("Not yet implemented"); - } - - /** - * @tests {@link javax.sql.RowSetInternal#getOriginalRow()} - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getOriginalRow", - args = {} - ) - public void testGetOriginalRow() { - fail("Not yet implemented"); - } - - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getParams", - args = {} - ) - public void testGetParams() { - fail("Not yet implemented"); - } - - /** - * @tests {@link javax.sql.RowSetInternal#setMetaData(javax.sql.RowSetMetaData)} - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setMetaData", - args = {javax.sql.RowSetMetaData.class} - ) - public void testSetMetaData() { - fail("Not yet implemented"); - } - -} diff --git a/luni/src/test/java/tests/javax/sql/RowSetListenerTest.java b/luni/src/test/java/tests/javax/sql/RowSetListenerTest.java deleted file mode 100644 index d238a42..0000000 --- a/luni/src/test/java/tests/javax/sql/RowSetListenerTest.java +++ /dev/null @@ -1,74 +0,0 @@ -/* - * Copyright (C) 2008 The Android Open Source Project - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package tests.javax.sql; - -import dalvik.annotation.TestTargets; -import dalvik.annotation.TestLevel; -import dalvik.annotation.TestTargetNew; -import dalvik.annotation.TestTargetClass; - -import junit.framework.TestCase; - -import javax.sql.RowSetEvent; -import javax.sql.RowSetListener; - -/** - * - */ -@TestTargetClass(RowSetListener.class) -public class RowSetListenerTest extends TestCase { - - /** - * Test method for {@link javax.sql.RowSetListener#cursorMoved(javax.sql.RowSetEvent)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "cursorMoved", - args = {javax.sql.RowSetEvent.class} - ) - public void testCursorMoved() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link javax.sql.RowSetListener#rowChanged(javax.sql.RowSetEvent)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "rowChanged", - args = {javax.sql.RowSetEvent.class} - ) - public void testRowChanged() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link javax.sql.RowSetListener#rowSetChanged(javax.sql.RowSetEvent)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "rowSetChanged", - args = {javax.sql.RowSetEvent.class} - ) - public void testRowSetChanged() { - fail("Not yet implemented"); - } - -} diff --git a/luni/src/test/java/tests/javax/sql/RowSetMetaDataTest.java b/luni/src/test/java/tests/javax/sql/RowSetMetaDataTest.java deleted file mode 100644 index 73a2f75..0000000 --- a/luni/src/test/java/tests/javax/sql/RowSetMetaDataTest.java +++ /dev/null @@ -1,241 +0,0 @@ -package tests.javax.sql; - -import dalvik.annotation.TestTargets; -import dalvik.annotation.TestLevel; -import dalvik.annotation.TestTargetNew; -import dalvik.annotation.TestTargetClass; - -import junit.framework.TestCase; - -import javax.sql.RowSetMetaData; - -/** - * @author AGR - * - */ -@TestTargetClass(RowSetMetaData.class) -public class RowSetMetaDataTest extends TestCase { - - /** - * @tests {@link javax.sql.RowSetMetaData#setAutoIncrement(int, boolean)} - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setAutoIncrement", - args = {int.class, boolean.class} - ) - public void testSetAutoIncrement() { - fail("Not yet implemented"); - } - - /** - * @tests {@link javax.sql.RowSetMetaData#setCaseSensitive(int, boolean)} - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setCaseSensitive", - args = {int.class, boolean.class} - ) - public void testSetCaseSensitive() { - fail("Not yet implemented"); - } - - - /** - * @tests {@link javax.sql.RowSetMetaData#setCatalogName(int, String)} - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setCatalogName", - args = {int.class, java.lang.String.class} - ) - public void testSetCatalogName() { - fail("Not yet implemented"); - } - - /** - * @tests {@link javax.sql.RowSetMetaData#setColumnCount(int)} - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setColumnCount", - args = {int.class} - ) - public void testSetColumnCount() { - fail("Not yet implemented"); - } - - /** - * @tests {@link javax.sql.RowSetMetaData#setColumnDisplaySize(int, int)} - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setColumnDisplaySize", - args = {int.class, int.class} - ) - public void testSetColumnDisplaySize() { - fail("Not yet implemented"); - } - - /** - * @tests {@link javax.sql.RowSetMetaData#setColumnLabel(int, String)} - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setColumnLabel", - args = {int.class, java.lang.String.class} - ) - public void testSetColumnLabel() { - fail("Not yet implemented"); - } - - /** - * @tests {@link javax.sql.RowSetMetaData#setColumnName(int, String)} - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setColumnName", - args = {int.class, java.lang.String.class} - ) - public void testSetColumnName() { - fail("Not yet implemented"); - } - - /** - * @tests {@link javax.sql.RowSetMetaData#setColumnType(int, int)} - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setColumnType", - args = {int.class, int.class} - ) - public void testSetColumnType() { - fail("Not yet implemented"); - } - - /** - * @tests {@link javax.sql.RowSetMetaData#setColumnTypeName(int, String)} - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setColumnTypeName", - args = {int.class, java.lang.String.class} - ) - public void testSetColumnTypeName() { - fail("Not yet implemented"); - } - - /** - * @tests {@link javax.sql.RowSetMetaData#setCurrency(int, boolean)} - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setCurrency", - args = {int.class, boolean.class} - ) - public void testSetCurrency() { - fail("Not yet implemented"); - } - - /** - * @tests {@link javax.sql.RowSetMetaData#setNullable(int, int)} - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setNullable", - args = {int.class, int.class} - ) - public void testSetNullable() { - fail("Not yet implemented"); - } - - /** - * @tests {@link javax.sql.RowSetMetaData#setPrecision(int, int)} - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setPrecision", - args = {int.class, int.class} - ) - public void testSetPrecision() { - fail("Not yet implemented"); - } - - /** - * @tests {@link javax.sql.RowSetMetaData#setScale(int, int)} - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setScale", - args = {int.class, int.class} - ) - public void testSetScale() { - fail("Not yet implemented"); - } - - /** - * @tests {@link javax.sql.RowSetMetaData#setSchemaName(int, String)} - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setSchemaName", - args = {int.class, java.lang.String.class} - ) - public void testSetSchemaName() { - fail("Not yet implemented"); - } - - /** - * @tests {@link javax.sql.RowSetMetaData#setSearchable(int, boolean)} - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setSearchable", - args = {int.class, boolean.class} - ) - public void testSetSearchable() { - fail("Not yet implemented"); - } - - /** - * @tests {@link javax.sql.RowSetMetaData#setSigned(int, boolean)} - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setSigned", - args = {int.class, boolean.class} - ) - public void testSetSigned() { - fail("Not yet implemented"); - } - - /** - * @tests {@link javax.sql.RowSetMetaData#setTableName(int, String)} - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setTableName", - args = {int.class, java.lang.String.class} - ) - public void testSetTableName() { - fail("Not yet implemented"); - } - -} diff --git a/luni/src/test/java/tests/javax/sql/RowSetReaderTest.java b/luni/src/test/java/tests/javax/sql/RowSetReaderTest.java deleted file mode 100644 index 0a24234..0000000 --- a/luni/src/test/java/tests/javax/sql/RowSetReaderTest.java +++ /dev/null @@ -1,29 +0,0 @@ -package tests.javax.sql; - -import dalvik.annotation.TestTargets; -import dalvik.annotation.TestLevel; -import dalvik.annotation.TestTargetNew; -import dalvik.annotation.TestTargetClass; - -import junit.framework.TestCase; - -import javax.sql.RowSetInternal; -import javax.sql.RowSetReader; - -@TestTargetClass(RowSetReader.class) -public class RowSetReaderTest extends TestCase { - - /** - * @tests {@link javax.sql.RowSetReader#readData(RowSetInternal)} - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "readData", - args = {javax.sql.RowSetInternal.class} - ) - public void testReadData() { - fail("Not yet implemented"); - } - -} diff --git a/luni/src/test/java/tests/javax/sql/RowSetTest.java b/luni/src/test/java/tests/javax/sql/RowSetTest.java deleted file mode 100644 index cea214e..0000000 --- a/luni/src/test/java/tests/javax/sql/RowSetTest.java +++ /dev/null @@ -1,624 +0,0 @@ -package tests.javax.sql; - -import dalvik.annotation.TestTargets; -import dalvik.annotation.TestLevel; -import dalvik.annotation.TestTargetNew; -import dalvik.annotation.TestTargetClass; - -import junit.framework.TestCase; - -import java.io.InputStream; -import java.io.Reader; -import java.math.BigDecimal; -import java.sql.Array; -import java.sql.Blob; -import java.sql.Clob; -import java.sql.Date; -import java.sql.Ref; -import java.sql.Time; -import java.sql.Timestamp; -import java.util.Calendar; -import java.util.Map; - -import javax.sql.RowSet; -import javax.sql.RowSetListener; - -/** - *No Implementation class of this interface is available: tests not feasible - */ -@TestTargetClass(RowSet.class) -public class RowSetTest extends TestCase { - - /** - * @tests {@link javax.sql.RowSet#addRowSetListener(javax.sql.RowSetListener)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "addRowSetListener", - args = {javax.sql.RowSetListener.class} - ) - public void testAddRowSetListener() { - fail("Not yet implemented"); - } - - /** - * @tests {@link javax.sql.RowSet#clearParameters()}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "clearParameters", - args = {} - ) - public void testClearParameters() { - fail("Not yet implemented"); - } - - /** - * @tests {@link javax.sql.RowSet#addRowSetListener(javax.sql.RowSetListener)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "execute", - args = {} - ) - public void testExecute() { - fail("Not yet implemented"); - } - - /** - * @tests {@link javax.sql.RowSet#getCommand()}. - */ - @TestTargets({ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setCommand", - args = {java.lang.String.class} - ), - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getCommand", - args = {} - ) - }) - public void testSetGetCommand() { - fail("Not yet implemented"); - } - - /** - * @tests {@link javax.sql.RowSet#getDataSourceName()}. - */ - @TestTargets({ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setDataSourceName", - args = {java.lang.String.class} - ), - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getDataSourceName", - args = {} - ) - }) - public void testSetGetDataSourceName() { - fail("Not yet implemented"); - } - - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getEscapeProcessing", - args = {} - ) - public void testSetGetEscapeProcessing() { - fail("Not yet implemented"); - } - - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getMaxFieldSize", - args = {} - ) - public void testSetGetMaxFieldSize() { - fail("Not yet implemented"); - } - - @TestTargets({ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getMaxRows", - args = {} - ), - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setMaxRows", - args = {int.class} - ) - }) - public void testSetGetMaxRows() { - fail("Not yet implemented"); - } - - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getPassword", - args = {} - ) - public void testSetGetPassword() { - fail("Not yet implemented"); - } - - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getQueryTimeout", - args = {} - ) - public void testSetGetQueryTimeout() { - fail("Not yet implemented"); - } - - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getTransactionIsolation", - args = {} - ) - public void testSetGetTransactionIsolation() { - fail("Not yet implemented"); - } - - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getTypeMap", - args = {} - ) - public void testSetGetTypeMap() { - fail("Not yet implemented"); - } - - @TestTargets({ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setUrl", - args = {java.lang.String.class} - ), - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getUrl", - args = {} - ) - }) - public void testSetGetUrl() { - fail("Not yet implemented"); - } - - @TestTargets({ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setUsername", - args = {java.lang.String.class} - ), - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getUsername", - args = {} - ) - }) - public void testSetGetUsername() { - fail("Not yet implemented"); - } - - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "isReadOnly", - args = {} - ) - public void testIsReadOnly() { - fail("Not yet implemented"); - } - - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "removeRowSetListener", - args = {javax.sql.RowSetListener.class} - ) - public void testRemoveRowSetListener() { - fail("Not yet implemented"); - } - - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setArray", - args = {int.class, java.sql.Array.class} - ) - public void testSetArray() { - fail("Not yet implemented"); - } - - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setAsciiStream", - args = {int.class, java.io.InputStream.class, int.class} - ) - public void testSetGetAsciiStream() { - fail("Not yet implemented"); - } - - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setBigDecimal", - args = {int.class, java.math.BigDecimal.class} - ) - public void testSetGetBigDecimal() { - fail("Not yet implemented"); - } - - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setBinaryStream", - args = {int.class, java.io.InputStream.class, int.class} - ) - public void testSetGetBinaryStream() { - fail("Not yet implemented"); - } - - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setBlob", - args = {int.class, java.sql.Blob.class} - ) - public void testSetGetBlob() { - fail("Not yet implemented"); - } - - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setBoolean", - args = {int.class, boolean.class} - ) - public void testSetGetBoolean() { - fail("Not yet implemented"); - } - - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setByte", - args = {int.class, byte.class} - ) - public void testSetGetByte() { - fail("Not yet implemented"); - } - - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setBytes", - args = {int.class, byte[].class} - ) - public void testSetGetBytes() { - fail("Not yet implemented"); - } - - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setCharacterStream", - args = {int.class, java.io.Reader.class, int.class} - ) - public void testSetGetCharacterStream() { - fail("Not yet implemented"); - } - - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setClob", - args = {int.class, java.sql.Clob.class} - ) - public void testSetGetClob() { - fail("Not yet implemented"); - } - - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setConcurrency", - args = {int.class} - ) - public void testSetGetConcurrency() { - fail("Not yet implemented"); - } - - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setDate", - args = {int.class, java.sql.Date.class} - ) - public void testSetGetDateIntDate() { - fail("Not yet implemented"); - } - - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setDate", - args = {int.class, java.sql.Date.class, java.util.Calendar.class} - ) - public void testSetDateIntDateCalendar() { - fail("Not yet implemented"); - } - - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setEscapeProcessing", - args = {boolean.class} - ) - public void testSetEscapeProcessing() { - - } - - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setDouble", - args = {int.class, double.class} - ) - public void testSetGetDouble() { - fail("Not yet implemented"); - } - - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setFloat", - args = {int.class, float.class} - ) - public void testSetGetFloat() { - fail("Not yet implemented"); - } - - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setInt", - args = {int.class, int.class} - ) - public void testSetGetInt() { - fail("Not yet implemented"); - } - - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setLong", - args = {int.class, long.class} - ) - public void testSetGetLong() { - fail("Not yet implemented"); - } - - @TestTargets({ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getMaxFieldSize", - args = {} - ), - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setMaxFieldSize", - args = {int.class} - ) - }) - public void testSetGetGetMaxFieldSize() { - fail("Not yet implemented"); - } - - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setNull", - args = {int.class, int.class} - ) - public void testSetGetNullIntInt() { - fail("Not yet implemented"); - } - - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setNull", - args = {int.class, int.class, java.lang.String.class} - ) - public void testSetGetNullIntIntString() { - fail("Not yet implemented"); - } - - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setObject", - args = {int.class, java.lang.Object.class} - ) - public void testSetGetObjectIntObject() { - fail("Not yet implemented"); - } - - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setObject", - args = {int.class, java.lang.Object.class, int.class} - ) - public void testSetGetObjectIntObjectInt() { - fail("Not yet implemented"); - } - - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setObject", - args = {int.class, java.lang.Object.class, int.class, int.class} - ) - public void testSetGetObjectIntObjectIntInt() { - fail("Not yet implemented"); - } - - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setPassword", - args = {java.lang.String.class} - ) - public void testSetPassword() { - fail("Not yet implemented"); - } - - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setQueryTimeout", - args = {int.class} - ) - public void testSetQueryTimeout() { - fail("Not yet implemented"); - } - - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setReadOnly", - args = {boolean.class} - ) - public void testSetReadOnly() { - fail("Not yet implemented"); - } - - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setRef", - args = {int.class, java.sql.Ref.class} - ) - public void testSetRef() { - fail("Not yet implemented"); - } - - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setShort", - args = {int.class, short.class} - ) - public void testSetShort() { - fail("Not yet implemented"); - } - - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setString", - args = {int.class, java.lang.String.class} - ) - public void testSetString() { - fail("Not yet implemented"); - } - - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setTime", - args = {int.class, java.sql.Time.class} - ) - public void testSetTimeIntTime() { - fail("Not yet implemented"); - } - - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setTime", - args = {int.class, java.sql.Time.class, java.util.Calendar.class} - ) - public void testSetTimeIntTimeCalendar() { - fail("Not yet implemented"); - } - - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setTimestamp", - args = {int.class, java.sql.Timestamp.class} - ) - public void testSetTimestampIntTimestamp() { - fail("Not yet implemented"); - } - - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setTimestamp", - args = {int.class, java.sql.Timestamp.class, java.util.Calendar.class} - ) - public void testSetTimestampIntTimestampCalendar() { - fail("Not yet implemented"); - } - - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setTransactionIsolation", - args = {int.class} - ) - public void testSetTransactionIsolation() { - fail("Not yet implemented"); - } - - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setType", - args = {int.class} - ) - public void testSetType() { - fail("Not yet implemented"); - } - - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setTypeMap", - args = {java.util.Map.class} - ) - public void testSetTypeMap() { - fail("Not yet implemented"); - } -} diff --git a/luni/src/test/java/tests/javax/sql/RowSetWriterTest.java b/luni/src/test/java/tests/javax/sql/RowSetWriterTest.java deleted file mode 100644 index 1b9f972..0000000 --- a/luni/src/test/java/tests/javax/sql/RowSetWriterTest.java +++ /dev/null @@ -1,29 +0,0 @@ -package tests.javax.sql; - -import dalvik.annotation.TestTargets; -import dalvik.annotation.TestLevel; -import dalvik.annotation.TestTargetNew; -import dalvik.annotation.TestTargetClass; - -import junit.framework.TestCase; - -import javax.sql.RowSetInternal; -import javax.sql.RowSetWriter; - -@TestTargetClass(RowSetWriter.class) -public class RowSetWriterTest extends TestCase { - - /** - * @tests {@link javax.sql.RowSetWriter#writeData(javax.sql.RowSetInternal)} - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "writeData", - args = {javax.sql.RowSetInternal.class} - ) - public void testWriteData() { - fail("Not yet implemented"); - } - -} diff --git a/luni/src/test/java/tests/sql/ArrayTest.java b/luni/src/test/java/tests/sql/ArrayTest.java deleted file mode 100644 index f3b49d6..0000000 --- a/luni/src/test/java/tests/sql/ArrayTest.java +++ /dev/null @@ -1,165 +0,0 @@ -/* - * Copyright (C) 2008 The Android Open Source Project - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package tests.sql; - -import dalvik.annotation.TestLevel; -import dalvik.annotation.TestTargetClass; -import dalvik.annotation.TestTargetNew; - -import junit.framework.TestCase; - -import java.sql.Array; -import java.util.Map; - -/** - * @author andrea@google.com (Your Name Here) - * - */ -@TestTargetClass(Array.class) -public class ArrayTest extends TestCase { - - /** - * Test method for {@link java.sql.Array#getArray()}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getArray", - args = {} - ) - public void testGetArray() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.Array#getArray(long, int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getArray", - args = {long.class, int.class} - ) - public void testGetArrayLongInt() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.Array#getArray(long, int, java.util.Map)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getArray", - args = {long.class, int.class, Map.class} - ) - public void testGetArrayLongIntMapOfStringClassOfQ() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.Array#getArray(java.util.Map)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getArray", - args = {Map.class} - ) - public void testGetArrayMapOfStringClassOfQ() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.Array#getBaseType()}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getBaseType", - args = {} - ) - public void testGetBaseType() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.Array#getBaseTypeName()}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getBaseTypeName", - args = {} - ) - public void testGetBaseTypeName() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.Array#getResultSet()}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getResultSet", - args = {} - ) - public void testGetResultSet() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.Array#getResultSet(long, int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getResultSet", - args = {long.class, int.class} - ) - public void testGetResultSetLongInt() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.Array#getResultSet(long, int, java.util.Map)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getResultSet", - args = {long.class, int.class, Map.class} - ) - public void testGetResultSetLongIntMapOfStringClassOfQ() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.Array#getResultSet(java.util.Map)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getResultSet", - args = {Map.class} - ) - public void testGetResultSetMapOfStringClassOfQ() { - fail("Not yet implemented"); - } - -} diff --git a/luni/src/test/java/tests/sql/BlobTest.java b/luni/src/test/java/tests/sql/BlobTest.java deleted file mode 100644 index 43fb2a6..0000000 --- a/luni/src/test/java/tests/sql/BlobTest.java +++ /dev/null @@ -1,151 +0,0 @@ -/* - * Copyright (C) 2008 The Android Open Source Project - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package tests.sql; - -import dalvik.annotation.TestLevel; -import dalvik.annotation.TestTargetClass; -import dalvik.annotation.TestTargetNew; - -import junit.framework.TestCase; - -import java.sql.Blob; - -/** - * @author andrea@google.com (Your Name Here) - * - */ -@TestTargetClass(Blob.class) -public class BlobTest extends TestCase { - - /** - * Test method for {@link java.sql.Blob#getBinaryStream()}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getBinaryStream", - args = {} - ) - public void testGetBinaryStream() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.Blob#getBytes(long, int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getBytes", - args = {long.class, int.class} - ) - public void testGetBytes() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.Blob#length()}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "length", - args = {} - ) - public void testLength() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.Blob#position(java.sql.Blob, long)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "position", - args = {Blob.class, long.class} - ) - public void testPositionBlobLong() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.Blob#position(byte[], long)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "position", - args = {byte[].class, long.class} - ) - public void testPositionByteArrayLong() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.Blob#setBinaryStream(long)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setBinaryStream", - args = {long.class} - ) - public void testSetBinaryStream() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.Blob#setBytes(long, byte[])}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setBytes", - args = {long.class, byte[].class} - ) - public void testSetBytesLongByteArray() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.Blob#setBytes(long, byte[], int, int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setBytes", - args = {long.class, byte[].class, int.class, int.class} - ) - public void testSetBytesLongByteArrayIntInt() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.Blob#truncate(long)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "truncate", - args = {long.class} - ) - public void testTruncate() { - fail("Not yet implemented"); - } - -} diff --git a/luni/src/test/java/tests/sql/CallableStatementTest.java b/luni/src/test/java/tests/sql/CallableStatementTest.java deleted file mode 100644 index db7aca1..0000000 --- a/luni/src/test/java/tests/sql/CallableStatementTest.java +++ /dev/null @@ -1,1070 +0,0 @@ -/* - * Copyright (C) 2008 The Android Open Source Project - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package tests.sql; - -import dalvik.annotation.TestLevel; -import dalvik.annotation.TestTargetClass; -import dalvik.annotation.TestTargetNew; - -import junit.framework.TestCase; - -import java.io.InputStream; -import java.io.Reader; -import java.math.BigDecimal; -import java.net.URL; -import java.sql.CallableStatement; -import java.sql.Date; -import java.sql.Time; -import java.sql.Timestamp; -import java.util.Calendar; -import java.util.Map; - -/** - * @author andrea@google.com (Your Name Here) - * - */ -@TestTargetClass(CallableStatement.class) -public class CallableStatementTest extends TestCase { - - /** - * Test method for {@link java.sql.CallableStatement#getArray(int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getArray", - args = {int.class} - ) - public void testGetArrayInt() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#getArray(java.lang.String)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getArray", - args = {String.class} - ) - public void testGetArrayString() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#getBigDecimal(int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getBigDecimal", - args = {int.class} - ) - public void testGetBigDecimalInt() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#getBigDecimal(int, int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getBigDecimal", - args = {int.class, int.class} - ) - public void testGetBigDecimalIntInt() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#getBigDecimal(java.lang.String)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getBigDecimal", - args = {String.class} - ) - public void testGetBigDecimalString() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#getBlob(int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getBlob", - args = {int.class} - ) - public void testGetBlobInt() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#getBlob(java.lang.String)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getBlob", - args = {String.class} - ) - public void testGetBlobString() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#getBoolean(int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getBoolean", - args = {int.class} - ) - public void testGetBooleanInt() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#getBoolean(java.lang.String)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getBoolean", - args = {String.class} - ) - public void testGetBooleanString() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#getByte(int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getByte", - args = {int.class} - ) - public void testGetByteInt() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#getByte(java.lang.String)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getByte", - args = {String.class} - ) - public void testGetByteString() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#getBytes(int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getBytes", - args = {int.class} - ) - public void testGetBytesInt() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#getBytes(java.lang.String)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getBytes", - args = {String.class} - ) - public void testGetBytesString() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#getClob(int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getClob", - args = {int.class} - ) - public void testGetClobInt() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#getClob(java.lang.String)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getClob", - args = {String.class} - ) - public void testGetClobString() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#getDate(int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getDate", - args = {int.class} - ) - public void testGetDateInt() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#getDate(int, java.util.Calendar)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getDate", - args = {int.class, Calendar.class} - ) - public void testGetDateIntCalendar() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#getDate(java.lang.String)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getDate", - args = {String.class} - ) - public void testGetDateString() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#getDate(java.lang.String, java.util.Calendar)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getDate", - args = {String.class, Calendar.class} - ) - public void testGetDateStringCalendar() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#getDouble(int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getDouble", - args = {int.class} - ) - public void testGetDoubleInt() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#getDouble(java.lang.String)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getDouble", - args = {String.class} - ) - public void testGetDoubleString() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#getFloat(int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getFloat", - args = {int.class} - ) - public void testGetFloatInt() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#getFloat(java.lang.String)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getFloat", - args = {String.class} - ) - public void testGetFloatString() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#getInt(int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getInt", - args = {int.class} - ) - public void testGetIntInt() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#getInt(java.lang.String)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getInt", - args = {String.class} - ) - public void testGetIntString() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#getLong(int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getLong", - args = {int.class} - ) - public void testGetLongInt() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#getLong(java.lang.String)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getLong", - args = {String.class} - ) - public void testGetLongString() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#getObject(int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getObject", - args = {int.class} - ) - public void testGetObjectInt() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#getObject(int, java.util.Map)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getObject", - args = {int.class, Map.class} - ) - public void testGetObjectIntMapOfStringClassOfQ() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#getObject(java.lang.String)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getObject", - args = {String.class} - ) - public void testGetObjectString() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#getObject(java.lang.String, java.util.Map)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getObject", - args = {String.class, Map.class} - ) - public void testGetObjectStringMapOfStringClassOfQ() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#getRef(int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getRef", - args = {int.class} - ) - public void testGetRefInt() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#getRef(java.lang.String)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getRef", - args = {String.class} - ) - public void testGetRefString() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#getShort(int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getShort", - args = {int.class} - ) - public void testGetShortInt() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#getShort(java.lang.String)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getShort", - args = {String.class} - ) - public void testGetShortString() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#getString(int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getString", - args = {int.class} - ) - public void testGetStringInt() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#getString(java.lang.String)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getString", - args = {String.class} - ) - public void testGetStringString() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#getTime(int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getTime", - args = {int.class} - ) - public void testGetTimeInt() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#getTime(int, java.util.Calendar)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getTime", - args = {int.class, Calendar.class} - ) - public void testGetTimeIntCalendar() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#getTime(java.lang.String)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getTime", - args = {String.class} - ) - public void testGetTimeString() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#getTime(java.lang.String, java.util.Calendar)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getTime", - args = {String.class, Calendar.class} - ) - public void testGetTimeStringCalendar() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#getTimestamp(int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getTimestamp", - args = {int.class} - ) - public void testGetTimestampInt() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#getTimestamp(int, java.util.Calendar)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getTimestamp", - args = {int.class, Calendar.class} - ) - public void testGetTimestampIntCalendar() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#getTimestamp(java.lang.String)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getTimestamp", - args = {String.class} - ) - public void testGetTimestampString() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#getTimestamp(java.lang.String, java.util.Calendar)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getTimestamp", - args = {String.class, Calendar.class} - ) - public void testGetTimestampStringCalendar() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#getURL(int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getURL", - args = {int.class} - ) - public void testGetURLInt() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#getURL(java.lang.String)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getURL", - args = {String.class} - ) - public void testGetURLString() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#registerOutParameter(int, int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "registerOutParameter", - args = {int.class, int.class} - ) - public void testRegisterOutParameterIntInt() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#registerOutParameter(int, int, int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "registerOutParameter", - args = {int.class, int.class, int.class} - ) - public void testRegisterOutParameterIntIntInt() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#registerOutParameter(int, int, java.lang.String)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "registerOutParameter", - args = {int.class, int.class, String.class} - ) - public void testRegisterOutParameterIntIntString() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#registerOutParameter(java.lang.String, int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "registerOutParameter", - args = {String.class, int.class} - ) - public void testRegisterOutParameterStringInt() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#registerOutParameter(java.lang.String, int, int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "registerOutParameter", - args = {String.class, int.class, int.class} - ) - public void testRegisterOutParameterStringIntInt() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#registerOutParameter(java.lang.String, int, java.lang.String)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "registerOutParameter", - args = {String.class, int.class, String.class} - ) - public void testRegisterOutParameterStringIntString() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#setAsciiStream(java.lang.String, java.io.InputStream, int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setAsciiStream", - args = {String.class, InputStream.class, int.class} - ) - public void testSetAsciiStreamStringInputStreamInt() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#setBigDecimal(java.lang.String, java.math.BigDecimal)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setBigDecimal", - args = {String.class, BigDecimal.class} - ) - public void testSetBigDecimalStringBigDecimal() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#setBinaryStream(java.lang.String, java.io.InputStream, int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setBinaryStream", - args = {String.class, InputStream.class, int.class} - ) - public void testSetBinaryStreamStringInputStreamInt() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#setBoolean(java.lang.String, boolean)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setBoolean", - args = {String.class, boolean.class} - ) - public void testSetBooleanStringBoolean() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#setByte(java.lang.String, byte)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setByte", - args = {String.class, byte.class} - ) - public void testSetByteStringByte() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#setBytes(java.lang.String, byte[])}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setBytes", - args = {String.class, byte[].class} - ) - public void testSetBytesStringByteArray() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#setCharacterStream(java.lang.String, java.io.Reader, int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setCharacterStream", - args = {String.class, Reader.class, int.class} - ) - public void testSetCharacterStreamStringReaderInt() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#setDate(java.lang.String, java.sql.Date)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setDate", - args = {String.class, Date.class} - ) - public void testSetDateStringDate() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#setDate(java.lang.String, java.sql.Date, java.util.Calendar)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setDate", - args = {String.class, Date.class, Calendar.class} - ) - public void testSetDateStringDateCalendar() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#setDouble(java.lang.String, double)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setDouble", - args = {String.class, double.class} - ) - public void testSetDoubleStringDouble() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#setFloat(java.lang.String, float)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setFloat", - args = {String.class, float.class} - ) - public void testSetFloatStringFloat() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#setInt(java.lang.String, int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setInt", - args = {String.class, int.class} - ) - public void testSetIntStringInt() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#setLong(java.lang.String, long)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setLong", - args = {String.class, long.class} - ) - public void testSetLongStringLong() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#setNull(java.lang.String, int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setNull", - args = {String.class, int.class} - ) - public void testSetNullStringInt() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#setNull(java.lang.String, int, java.lang.String)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setNull", - args = {String.class, int.class, String.class} - ) - public void testSetNullStringIntString() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#setObject(java.lang.String, java.lang.Object)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setObject", - args = {String.class, Object.class} - ) - public void testSetObjectStringObject() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#setObject(java.lang.String, java.lang.Object, int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setObject", - args = {String.class, Object.class, int.class} - ) - public void testSetObjectStringObjectInt() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#setObject(java.lang.String, java.lang.Object, int, int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setObject", - args = {String.class, Object.class, int.class, int.class} - ) - public void testSetObjectStringObjectIntInt() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#setShort(java.lang.String, short)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setShort", - args = {String.class, short.class} - ) - public void testSetShortStringShort() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#setString(java.lang.String, java.lang.String)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setString", - args = {String.class, String.class} - ) - public void testSetStringStringString() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#setTime(java.lang.String, java.sql.Time)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setTime", - args = {String.class, Time.class} - ) - public void testSetTimeStringTime() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#setTime(java.lang.String, java.sql.Time, java.util.Calendar)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setTime", - args = {String.class, Time.class, Calendar.class} - ) - public void testSetTimeStringTimeCalendar() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#setTimestamp(java.lang.String, java.sql.Timestamp)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setTimestamp", - args = {String.class, Timestamp.class} - ) - public void testSetTimestampStringTimestamp() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#setTimestamp(java.lang.String, java.sql.Timestamp, java.util.Calendar)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setTimestamp", - args = {String.class, Timestamp.class, Calendar.class} - ) - public void testSetTimestampStringTimestampCalendar() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#setURL(java.lang.String, java.net.URL)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setURL", - args = {String.class, URL.class} - ) - public void testSetURLStringURL() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.CallableStatement#wasNull()}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "wasNull", - args = {} - ) - public void testWasNull() { - fail("Not yet implemented"); - } - -} diff --git a/luni/src/test/java/tests/sql/ClobTest.java b/luni/src/test/java/tests/sql/ClobTest.java deleted file mode 100644 index c0f218f..0000000 --- a/luni/src/test/java/tests/sql/ClobTest.java +++ /dev/null @@ -1,177 +0,0 @@ -/* - * Copyright (C) 2008 The Android Open Source Project - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package tests.sql; - -import dalvik.annotation.TestLevel; -import dalvik.annotation.TestTargetClass; -import dalvik.annotation.TestTargetNew; - -import junit.framework.TestCase; - -import java.sql.Clob; - -/** - * @author andrea@google.com (Your Name Here) - * - */ -@TestTargetClass(Clob.class) -public class ClobTest extends TestCase { - - /** - * Test method for {@link java.sql.Clob#getAsciiStream()}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getAsciiStream", - args = {} - ) - public void testGetAsciiStream() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.Clob#getCharacterStream()}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getCharacterStream", - args = {} - ) - public void testGetCharacterStream() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.Clob#getSubString(long, int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getSubString", - args = {long.class, int.class} - ) - public void testGetSubString() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.Clob#length()}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "length", - args = {} - ) - public void testLength() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.Clob#position(java.sql.Clob, long)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "position", - args = {Clob.class, long.class} - ) - public void testPositionClobLong() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.Clob#position(java.lang.String, long)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "position", - args = {String.class, long.class} - ) - public void testPositionStringLong() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.Clob#setAsciiStream(long)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setAsciiStream", - args = {long.class} - ) - public void testSetAsciiStream() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.Clob#setCharacterStream(long)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setCharacterStream", - args = {long.class} - ) - public void testSetCharacterStream() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.Clob#setString(long, java.lang.String)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setString", - args = {long.class, String.class} - ) - public void testSetStringLongString() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.Clob#setString(long, java.lang.String, int, int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setString", - args = {long.class, String.class, int.class, int.class} - ) - public void testSetStringLongStringIntInt() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.Clob#truncate(long)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "truncate", - args = {long.class} - ) - public void testTruncate() { - fail("Not yet implemented"); - } - -} diff --git a/luni/src/test/java/tests/sql/ParameterMetaDataTest.java b/luni/src/test/java/tests/sql/ParameterMetaDataTest.java deleted file mode 100644 index f522450..0000000 --- a/luni/src/test/java/tests/sql/ParameterMetaDataTest.java +++ /dev/null @@ -1,150 +0,0 @@ -/* - * Copyright (C) 2008 The Android Open Source Project - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package tests.sql; - -import dalvik.annotation.TestLevel; -import dalvik.annotation.TestTargetClass; -import dalvik.annotation.TestTargetNew; - -import junit.framework.TestCase; - -import java.sql.ParameterMetaData; - -/** - * - */ -@TestTargetClass(ParameterMetaData.class) -public class ParameterMetaDataTest extends TestCase { - - /** - * Test method for {@link java.sql.ParameterMetaData#getParameterClassName(int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getParameterClassName", - args = {int.class} - ) - public void testGetParameterClassName() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ParameterMetaData#getParameterCount()}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getParameterCount", - args = {} - ) - public void testGetParameterCount() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ParameterMetaData#getParameterMode(int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getParameterMode", - args = {int.class} - ) - public void testGetParameterMode() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ParameterMetaData#getParameterType(int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getParameterType", - args = {int.class} - ) - public void testGetParameterType() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ParameterMetaData#getParameterTypeName(int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getParameterTypeName", - args = {int.class} - ) - public void testGetParameterTypeName() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ParameterMetaData#getPrecision(int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getPrecision", - args = {int.class} - ) - public void testGetPrecision() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ParameterMetaData#getScale(int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getScale", - args = {int.class} - ) - public void testGetScale() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ParameterMetaData#isNullable(int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "isNullable", - args = {int.class} - ) - public void testIsNullable() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ParameterMetaData#isSigned(int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "isSigned", - args = {int.class} - ) - public void testIsSigned() { - fail("Not yet implemented"); - } - -} diff --git a/luni/src/test/java/tests/sql/PreparedStatementTest.java b/luni/src/test/java/tests/sql/PreparedStatementTest.java index f69e374..cf1b6fc 100755 --- a/luni/src/test/java/tests/sql/PreparedStatementTest.java +++ b/luni/src/test/java/tests/sql/PreparedStatementTest.java @@ -496,16 +496,6 @@ public class PreparedStatementTest extends SQLTest { } } - /** - * @throws SQLException - * @test java.sql.PreparedStatement#getParameterMetaData() - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "getParameterMetaData", - args = {} - ) public void testGetParameterMetaData() throws SQLException { PreparedStatement ps = null; String query = "select * from zoo where id = ?"; diff --git a/luni/src/test/java/tests/sql/RefTest.java b/luni/src/test/java/tests/sql/RefTest.java deleted file mode 100644 index 6109623..0000000 --- a/luni/src/test/java/tests/sql/RefTest.java +++ /dev/null @@ -1,87 +0,0 @@ -/* - * Copyright (C) 2008 The Android Open Source Project - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package tests.sql; - -import dalvik.annotation.TestLevel; -import dalvik.annotation.TestTargetClass; -import dalvik.annotation.TestTargetNew; - -import junit.framework.TestCase; - -import java.sql.Ref; -import java.util.Map; - -/** - * @author andrea@google.com (Your Name Here) - * - */ -@TestTargetClass(Ref.class) -public class RefTest extends TestCase { - - /** - * Test method for {@link java.sql.Ref#getBaseTypeName()}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getBaseTypeName", - args = {} - ) - public void testGetBaseTypeName() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.Ref#getObject()}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getObject", - args = {} - ) - public void testGetObject() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.Ref#getObject(java.util.Map)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getObject", - args = {Map.class} - ) - public void testGetObjectMapOfStringClassOfQ() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.Ref#setObject(java.lang.Object)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setObject", - args = {Object.class} - ) - public void testSetObject() { - fail("Not yet implemented"); - } - -} diff --git a/luni/src/test/java/tests/sql/ResultSetMetaDataTest.java b/luni/src/test/java/tests/sql/ResultSetMetaDataTest.java index 429a75f..a891b93 100755 --- a/luni/src/test/java/tests/sql/ResultSetMetaDataTest.java +++ b/luni/src/test/java/tests/sql/ResultSetMetaDataTest.java @@ -743,15 +743,7 @@ public class ResultSetMetaDataTest extends SQLTest { } - /** - * @test {@link java.sql.ResultSetMetaData#isReadOnly(int column)} - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "Cannot know from blackbox test if readonly or writable. Exceptions fail, Feature only partially implemented.", - method = "isReadOnly", - args = {int.class} - ) + // Cannot know from blackbox test if readonly or writable. Exceptions fail, Feature only partially implemented. @KnownFailure("not supported") public void testIsReadOnly() { @@ -832,15 +824,7 @@ public class ResultSetMetaDataTest extends SQLTest { } } - /** - * @test {@link java.sql.ResultSetMetaData#isWritable(int column)} - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "Analaguous to is Readonly. Exceptions and tests on non numeric fields fail, failing statements commented out. Feature only partially implemented.", - method = "isWritable", - args = {int.class} - ) + // Analogous to is Readonly. Exceptions and tests on non numeric fields fail, failing statements commented out. Feature only partially implemented. @KnownFailure("not supported") public void testIsWritable() { diff --git a/luni/src/test/java/tests/sql/ResultSetNotSupportedTests.java b/luni/src/test/java/tests/sql/ResultSetNotSupportedTests.java deleted file mode 100644 index dd91f1a..0000000 --- a/luni/src/test/java/tests/sql/ResultSetNotSupportedTests.java +++ /dev/null @@ -1,1352 +0,0 @@ -/* - * Copyright (C) 2008 The Android Open Source Project - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package tests.sql; - -import dalvik.annotation.KnownFailure; -import dalvik.annotation.TestLevel; -import dalvik.annotation.TestTargetClass; -import dalvik.annotation.TestTargetNew; - -import java.sql.Ref; -import java.sql.ResultSet; - -@TestTargetClass(ResultSet.class) -public class ResultSetNotSupportedTests extends SQLTest { - - /** - * Test method for {@link java.sql.ResultSet#getArray(int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getArray", - args = {int.class} - ) - public void testGetArrayInt() { - - fail(); - } - - /** - * Test method for {@link java.sql.ResultSet#getArray(java.lang.String)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getArray", - args = {java.lang.String.class} - ) - @KnownFailure("Not Supported") - public void testGetArrayString() { - fail("Not yet implemented"); - } - - - /** - * Test method for {@link java.sql.ResultSet#getAsciiStream(int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getAsciiStream", - args = {int.class} - ) - @KnownFailure("Not Supported") - public void testGetAsciiStreamInt() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#getAsciiStream(java.lang.String)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getAsciiStream", - args = {java.lang.String.class} - ) - @KnownFailure("Not Supported") - public void testGetAsciiStreamString() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#getBigDecimal(int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getBigDecimal", - args = {int.class} - ) - @KnownFailure("Not Supported") - public void testGetBigDecimalInt() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#getBigDecimal(int, int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "getBigDecimal", - args = {int.class, int.class} - ) - @KnownFailure("Not Supported") - public void testGetBigDecimalIntInt() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#getBigDecimal(java.lang.String)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getBigDecimal", - args = {java.lang.String.class} - ) - @KnownFailure("Not Supported") - public void testGetBigDecimalString() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#getBigDecimal(java.lang.String, int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getBigDecimal", - args = {java.lang.String.class, int.class} - ) - @KnownFailure("Not Supported") - public void testGetBigDecimalStringInt() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#getBinaryStream(int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getBinaryStream", - args = {int.class} - ) - @KnownFailure("Not Supported") - public void testGetBinaryStreamInt() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#getBinaryStream(java.lang.String)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getBinaryStream", - args = {java.lang.String.class} - ) - @KnownFailure("Not Supported") - public void testGetBinaryStreamString() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#getBlob(int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getBlob", - args = {int.class} - ) - @KnownFailure("Not Supported") - public void testGetBlobInt() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#getBlob(java.lang.String)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getBlob", - args = {java.lang.String.class} - ) - @KnownFailure("Not Supported") - public void testGetBlobString() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#getBoolean(int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "getBoolean", - args = {int.class} - ) - @KnownFailure("Not Supported") - public void testGetBooleanInt() { - /* - try { - assertTrue(res.first()); - boolean b = res.getBoolean(1); - assertTrue(b); - } catch (SQLException e) { - fail("Unexpected exception: " + e.getMessage()); - } - - try { - boolean b = res.getBoolean(5); - fail("Should get exception"); - } catch (SQLException e) { - //ok - } - - - - // null value - try { - assertTrue(res.next()); - boolean b = res.getBoolean(1); - assertFalse(b); - } catch (SQLException e) { - fail("Unexpected exception: " + e.getMessage()); - } - */ - } - - /** - * Test method for {@link java.sql.ResultSet#getBoolean(java.lang.String)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getBoolean", - args = {java.lang.String.class} - ) - @KnownFailure("Not Supported") - public void testGetBooleanString() { - fail("Not yet implemented"); - } - - - - /** - * Test method for {@link java.sql.ResultSet#getByte(java.lang.String)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "getByte", - args = {java.lang.String.class} - ) - @KnownFailure("Not Supported") - public void testGetByteString() { - fail("Not yet implemented"); - } - - - /** - * Test method for {@link java.sql.ResultSet#getByte(int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "getByte", - args = {int.class} - ) - @KnownFailure("Not Supported") - public void testGetByteInt() { - /* - try { - assertTrue(res.first()); - byte b = res.getByte(14); - String testString = Byte.toString(b); - assertEquals("test string",testString); - } catch (SQLException e) { - fail("Unexpected exception: " + e.getMessage()); - } - - try { - byte b = res.getByte(5); - fail("Should get exception"); - } catch (SQLException e) { - //ok - } - - // null value - try { - assertTrue(res.next()); - byte b = res.getByte(14); - assertNull(b); - } catch (SQLException e) { - fail("Unexpected exception: " + e.getMessage()); - } - */ - } - - - /** - * Test method for {@link java.sql.ResultSet#getCharacterStream(int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getCharacterStream", - args = {int.class} - ) - @KnownFailure("Not Supported") - public void testGetCharacterStreamInt() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#getCharacterStream(java.lang.String)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getCharacterStream", - args = {java.lang.String.class} - ) - @KnownFailure("Not Supported") - public void testGetCharacterStreamString() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#getClob(int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getClob", - args = {int.class} - ) - @KnownFailure("Not Supported") - public void testGetClobInt() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#getClob(java.lang.String)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getClob", - args = {java.lang.String.class} - ) - @KnownFailure("Not Supported") - public void testGetClobString() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#getCursorName()}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported, setColumnName is not supported, therefore GetColumname can not be tested", - method = "getCursorName", - args = {} - ) - @KnownFailure("Not Supported") - public void testGetCursorName() { - /* - try { - assertNull(res.getCursorName()); - } catch (Exception e) { - fail("Unexpected exception: " + e.getMessage()); - } - - ResultSet rs2 = null; - Statement stmt; - String inputCName = "my \"\"\"\"quoted\"\"\"\" cursor\"\""; - try { - assertNull(res.getCursorName()); - stmt = conn.createStatement(ResultSet.TYPE_FORWARD_ONLY, - ResultSet.CONCUR_READ_ONLY); - stmt.setCursorName(inputCName); - rs2 = stmt.executeQuery("select * from type"); - rs2.next(); - String name = rs2.getCursorName(); - assertEquals(inputCName, name); - } catch (Exception e) { - fail("Unexpected exception: " + e.getMessage()); - } - - try { - rs2.close(); - rs2.getCursorName(); - fail("Should throw exception"); - } catch (Exception e) { - //ok - } - */ - } - - /** - * Test method for {@link java.sql.ResultSet#getFetchDirection()}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported.", - method = "getFetchDirection", - args = {} - ) - @KnownFailure("Not Supported") - public void testGetFetchDirection() { - /* - try { - assertEquals(ResultSet.TYPE_FORWARD_ONLY, res.getFetchDirection()); - } catch (SQLException e) { - fail("Unexpected exception: " + e.getMessage()); - } - */ - } - - - /** - * Test method for {@link java.sql.ResultSet#getFetchSize()}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getFetchSize", - args = {} - ) - @KnownFailure("Not Supported") - public void testGetFetchSize() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#getObject(int, java.util.Map)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getObject", - args = {int.class, java.util.Map.class} - ) - @KnownFailure("Not Supported") - public void testGetObjectIntMapOfStringClassOfQ() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#getObject(java.lang.String, java.util.Map)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getObject", - args = {java.lang.String.class, java.util.Map.class} - ) - @KnownFailure("Not Supported") - public void testGetObjectStringMapOfStringClassOfQ() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#getRef(int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getRef", - args = {int.class} - ) - @KnownFailure("Not Supported") - public void testGetRefInt() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#getRef(java.lang.String)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getRef", - args = {java.lang.String.class} - ) - @KnownFailure("Not Supported") - public void testGetRefString() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#getUnicodeStream(int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getUnicodeStream", - args = {int.class} - ) - @KnownFailure("Not Supported") - public void testGetUnicodeStreamInt() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#getUnicodeStream(java.lang.String)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getUnicodeStream", - args = {java.lang.String.class} - ) - @KnownFailure("Not Supported") - public void testGetUnicodeStreamString() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#getWarnings()}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getWarnings", - args = {} - ) - @KnownFailure("Not Supported") - public void testGetWarnings() { - /* - try { - res.close(); - res.getWarnings(); - fail("Exception expected"); - } catch (SQLException e) { - //ok - } - */ - } - - /** - * Test method for {@link java.sql.ResultSet#cancelRowUpdates()}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "SQLException checking missed", - method = "cancelRowUpdates", - args = {} - ) - @KnownFailure("Not Supported") - public void testCancelRowUpdates() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#deleteRow()}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "deleteRow", - args = {} - ) - @KnownFailure("Not Supported") - public void testDeleteRow() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#insertRow()}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "insertRow", - args = {} - ) - @KnownFailure("Not Supported") - public void testInsertRow() { - fail("Not yet implemented"); - } - - - /** - * Test method for {@link java.sql.ResultSet#moveToCurrentRow()}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "moveToCurrentRow", - args = {} - ) - @KnownFailure("Not Supported") - public void testMoveToCurrentRow() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#moveToInsertRow()}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "moveToInsertRow", - args = {} - ) - @KnownFailure("Not Supported") - public void testMoveToInsertRow() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#refreshRow()}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "refreshRow", - args = {} - ) - @KnownFailure("Not Supported") - public void testRefreshRow() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#rowDeleted()}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "rowDeleted", - args = {} - ) - @KnownFailure("Not Supported") - public void testRowDeleted() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#rowInserted()}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "rowInserted", - args = {} - ) - @KnownFailure("Not Supported") - public void testRowInserted() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#rowUpdated()}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "rowUpdated", - args = {} - ) - @KnownFailure("Not Supported") - public void testRowUpdated() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#setFetchDirection(int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setFetchDirection", - args = {int.class} - ) - @KnownFailure("Not Supported") - public void testSetFetchDirection() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#setFetchSize(int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "setFetchSize", - args = {int.class} - ) - @KnownFailure("Not Supported") - public void testSetFetchSize() { - fail("Not yet implemented"); - } - - - /** - * Test method for {@link java.sql.ResultSet#updateArray(int, java.sql.Array)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "updateArray", - args = {int.class, java.sql.Array.class} - ) - @KnownFailure("Not Supported") - public void testUpdateArrayIntArray() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#updateArray(java.lang.String, java.sql.Array)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "updateArray", - args = {java.lang.String.class, java.sql.Array.class} - ) - @KnownFailure("Not Supported") - public void testUpdateArrayStringArray() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#updateAsciiStream(int, java.io.InputStream, int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "updateAsciiStream", - args = {int.class, java.io.InputStream.class, int.class} - ) - @KnownFailure("Not Supported") - public void testUpdateAsciiStreamIntInputStreamInt() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#updateAsciiStream(java.lang.String, java.io.InputStream, int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "updateAsciiStream", - args = {String.class, java.io.InputStream.class, int.class} - ) - @KnownFailure("Not Supported") - public void testUpdateAsciiStreamStringInputStreamInt() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#updateBigDecimal(int, java.math.BigDecimal)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "updateBigDecimal", - args = {int.class, java.math.BigDecimal.class} - ) - @KnownFailure("Not Supported") - public void testUpdateBigDecimalIntBigDecimal() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#updateBigDecimal(java.lang.String, java.math.BigDecimal)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "updateBigDecimal", - args = {java.lang.String.class, java.math.BigDecimal.class} - ) - @KnownFailure("Not Supported") - public void testUpdateBigDecimalStringBigDecimal() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#updateBinaryStream(int, java.io.InputStream, int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "updateBinaryStream", - args = {int.class, java.io.InputStream.class, int.class} - ) - @KnownFailure("Not Supported") - public void testUpdateBinaryStreamIntInputStreamInt() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#updateBinaryStream(java.lang.String, java.io.InputStream, int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "updateBinaryStream", - args = {java.lang.String.class, java.io.InputStream.class, int.class} - ) - @KnownFailure("Not Supported") - public void testUpdateBinaryStreamStringInputStreamInt() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#updateBlob(int, java.sql.Blob)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "updateBlob", - args = {int.class, java.sql.Blob.class} - ) - @KnownFailure("Not Supported") - public void testUpdateBlobIntBlob() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#updateBlob(java.lang.String, java.sql.Blob)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "updateBlob", - args = {java.lang.String.class, java.sql.Blob.class} - ) - @KnownFailure("Not Supported") - public void testUpdateBlobStringBlob() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#updateBoolean(int, boolean)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "updateBoolean", - args = {int.class, boolean.class} - ) - @KnownFailure("Not Supported") - public void testUpdateBooleanIntBoolean() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#updateBoolean(java.lang.String, boolean)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "updateBoolean", - args = {java.lang.String.class, boolean.class} - ) - @KnownFailure("Not Supported") - public void testUpdateBooleanStringBoolean() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#updateByte(int, byte)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "updateByte", - args = {int.class, byte.class} - ) - @KnownFailure("Not Supported") - public void testUpdateByteIntByte() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#updateByte(java.lang.String, byte)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "updateByte", - args = {java.lang.String.class, byte.class} - ) - @KnownFailure("Not Supported") - public void testUpdateByteStringByte() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#updateBytes(int, byte[])}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "updateBytes", - args = {int.class, byte[].class} - ) - @KnownFailure("Not Supported") - public void testUpdateBytesIntByteArray() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#updateBytes(java.lang.String, byte[])}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "updateBytes", - args = {java.lang.String.class, byte[].class} - ) - @KnownFailure("Not Supported") - public void testUpdateBytesStringByteArray() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#updateCharacterStream(int, java.io.Reader, int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "updateCharacterStream", - args = {int.class, java.io.Reader.class, int.class} - ) - @KnownFailure("Not Supported") - public void testUpdateCharacterStreamIntReaderInt() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#updateCharacterStream(java.lang.String, java.io.Reader, int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "updateCharacterStream", - args = {java.lang.String.class, java.io.Reader.class, int.class} - ) - @KnownFailure("Not Supported") - public void testUpdateCharacterStreamStringReaderInt() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#updateClob(int, java.sql.Clob)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "updateClob", - args = {int.class, java.sql.Clob.class} - ) - @KnownFailure("Not Supported") - public void testUpdateClobIntClob() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#updateClob(java.lang.String, java.sql.Clob)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "updateClob", - args = {java.lang.String.class, java.sql.Clob.class} - ) - @KnownFailure("Not Supported") - public void testUpdateClobStringClob() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#updateDate(int, java.sql.Date)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "updateDate", - args = {int.class, java.sql.Date.class} - ) - @KnownFailure("Not Supported") - public void testUpdateDateIntDate() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#updateDate(java.lang.String, java.sql.Date)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "updateDate", - args = {java.lang.String.class, java.sql.Date.class} - ) - @KnownFailure("Not Supported") - public void testUpdateDateStringDate() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#updateDouble(int, double)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "updateDouble", - args = {int.class, double.class} - ) - @KnownFailure("Not Supported") - public void testUpdateDoubleIntDouble() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#updateDouble(java.lang.String, double)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "updateDouble", - args = {java.lang.String.class, double.class} - ) - @KnownFailure("Not Supported") - public void testUpdateDoubleStringDouble() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#updateFloat(int, float)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "updateFloat", - args = {int.class, float.class} - ) - @KnownFailure("Not Supported") - public void testUpdateFloatIntFloat() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#updateFloat(java.lang.String, float)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "updateFloat", - args = {java.lang.String.class, float.class} - ) - @KnownFailure("Not Supported") - public void testUpdateFloatStringFloat() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#updateInt(int, int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "updateInt", - args = {int.class, int.class} - ) - @KnownFailure("Not Supported") - public void testUpdateIntIntInt() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#updateInt(java.lang.String, int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "updateInt", - args = {String.class, int.class} - ) - @KnownFailure("Not Supported") - public void testUpdateIntStringInt() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#updateLong(int, long)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "updateLong", - args = {int.class, long.class} - ) - @KnownFailure("Not Supported") - public void testUpdateLongIntLong() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#updateLong(java.lang.String, long)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "updateLong", - args = {java.lang.String.class, long.class} - ) - @KnownFailure("Not Supported") - public void testUpdateLongStringLong() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#updateNull(int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "updateNull", - args = {int.class} - ) - @KnownFailure("Not Supported") - public void testUpdateNullInt() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#updateNull(java.lang.String)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "updateNull", - args = {java.lang.String.class} - ) - @KnownFailure("Not Supported") - public void testUpdateNullString() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#updateObject(int, java.lang.Object)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "updateObject", - args = {int.class, java.lang.Object.class} - ) - @KnownFailure("Not Supported") - public void testUpdateObjectIntObject() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#updateObject(int, java.lang.Object, int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "updateObject", - args = {int.class, java.lang.Object.class, int.class} - ) - @KnownFailure("Not Supported") - public void testUpdateObjectIntObjectInt() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#updateObject(String, Object) }. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "updateObject", - args = {String.class, Object.class} - ) - @KnownFailure("Not Supported") - public void testUpdateStringObject() { - - } - - /** - * Test method for {@link java.sql.ResultSet#updateObject(String, Object, int) }. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "updateObject", - args = {String.class, Object.class, int.class} - ) - @KnownFailure("Not Supported") - public void testUpdateStringObjectInt() { - - } - - /** - * Test method for {@link java.sql.ResultSet#updateRef(int, java.sql.Ref) }. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "updateRef", - args = {int.class, Ref.class} - ) - @KnownFailure("Not Supported") - public void testUpdateRefIntRef() { - - } - - /** - * Test method for {@link java.sql.ResultSet#updateRef(String, Ref) }. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "updateRef", - args = {String.class, Ref.class} - ) - @KnownFailure("Not Supported") - public void testUpdateRefStringRef() { - - } - - /** - * Test method for {@link java.sql.ResultSet#updateRow() }. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "updateRow", - args = {} - ) - @KnownFailure("Not Supported") - public void testUpdateRow() { - - } - - /** - * Test method for {@link java.sql.ResultSet#updateShort(int, short) }. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "updateShort", - args = {int.class, short.class} - ) - @KnownFailure("Not Supported") - public void testUpdateShortIntShort() { - - } - - /** - * Test method for {@link java.sql.ResultSet#updateShort(String, short) }. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "updateShort", - args = {String.class, short.class} - ) - @KnownFailure("Not Supported") - public void testUpdateShortStringShort() { - - } - - /** - * Test method for {@link java.sql.ResultSet#updateString(int, String) }. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "updateString", - args = {int.class, String.class} - ) - @KnownFailure("Not Supported") - public void testUpdateStringIntString() { - - } - - - /** - * Test method for {@link java.sql.ResultSet#updateTime(int, java.sql.Time)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "updateTime", - args = {int.class, java.sql.Time.class} - ) - @KnownFailure("Not Supported") - public void testUpdateTimeIntTime() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#updateTime(java.lang.String, java.sql.Time)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "updateTime", - args = {java.lang.String.class, java.sql.Time.class} - ) - @KnownFailure("Not Supported") - public void testUpdateTimeStringTime() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#updateTimestamp(int, java.sql.Timestamp)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "updateTimestamp", - args = {int.class, java.sql.Timestamp.class} - ) - @KnownFailure("Not Supported") - public void testUpdateTimestampIntTimestamp() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.ResultSet#updateTimestamp(java.lang.String, java.sql.Timestamp)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "updateTimestamp", - args = {java.lang.String.class, java.sql.Timestamp.class} - ) - @KnownFailure("Not Supported") - public void testUpdateTimestampStringTimestamp() { - fail("Not yet implemented"); - } - -} diff --git a/luni/src/test/java/tests/sql/ResultSetTest.java b/luni/src/test/java/tests/sql/ResultSetTest.java index c515453..9c91468 100644 --- a/luni/src/test/java/tests/sql/ResultSetTest.java +++ b/luni/src/test/java/tests/sql/ResultSetTest.java @@ -188,20 +188,6 @@ public class ResultSetTest extends SQLTest { } /** - * Test method for {@link java.sql.ResultSet#clearWarnings()}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "Not supported", - method = "clearWarnings", - args = {} - ) - @KnownFailure("Not supported") - public void testClearWarnings() { - fail("Not yet implemented"); - } - - /** * Test method for {@link java.sql.ResultSet#close()}. * * According to the JDBC spec close has to "Releases this ResultSet @@ -727,12 +713,6 @@ public class ResultSetTest extends SQLTest { /** * Test method for {@link java.sql.ResultSet#updateObject(java.lang.String, java.lang.Object)}. */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "not supported", - method = "updateObject", - args = {java.lang.String.class, java.lang.Object.class} - ) @KnownFailure("not supported") public void testUpdateObjectStringObject() { try { diff --git a/luni/src/test/java/tests/sql/SQLDataTest.java b/luni/src/test/java/tests/sql/SQLDataTest.java deleted file mode 100644 index 1aed820..0000000 --- a/luni/src/test/java/tests/sql/SQLDataTest.java +++ /dev/null @@ -1,72 +0,0 @@ -/* - * Copyright (C) 2008 The Android Open Source Project - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package tests.sql; - -import dalvik.annotation.TestLevel; -import dalvik.annotation.TestTargetClass; -import dalvik.annotation.TestTargetNew; - -import junit.framework.TestCase; - -import java.sql.SQLData; -import java.sql.SQLInput; -import java.sql.SQLOutput; - - -@TestTargetClass(SQLData.class) -public class SQLDataTest extends TestCase { - - /** - * Test method for {@link java.sql.SQLData#getSQLTypeName()}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getSQLTypeName", - args = {} - ) - public void testGetSQLTypeName() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.SQLData#readSQL(java.sql.SQLInput, java.lang.String)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "readSQL", - args = {SQLInput.class, String.class} - ) - public void testReadSQL() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.SQLData#writeSQL(java.sql.SQLOutput)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "writeSQL", - args = {SQLOutput.class} - ) - public void testWriteSQL() { - fail("Not yet implemented"); - } - -} diff --git a/luni/src/test/java/tests/sql/SQLInputTest.java b/luni/src/test/java/tests/sql/SQLInputTest.java deleted file mode 100644 index 818818b..0000000 --- a/luni/src/test/java/tests/sql/SQLInputTest.java +++ /dev/null @@ -1,328 +0,0 @@ -/* - * Copyright (C) 2008 The Android Open Source Project - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package tests.sql; - -import dalvik.annotation.TestLevel; -import dalvik.annotation.TestTargetClass; -import dalvik.annotation.TestTargetNew; - -import junit.framework.TestCase; - -import java.sql.SQLInput; - -@TestTargetClass(SQLInput.class) -public class SQLInputTest extends TestCase { - - /** - * Test method for {@link java.sql.SQLInput#readString()}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "readString", - args = {} - ) - public void testReadString() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.SQLInput#readBoolean()}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "readBoolean", - args = {} - ) - public void testReadBoolean() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.SQLInput#readByte()}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "readByte", - args = {} - )public void testReadByte() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.SQLInput#readShort()}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "readShort", - args = {} - ) - public void testReadShort() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.SQLInput#readInt()}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "readInt", - args = {} - ) - public void testReadInt() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.SQLInput#readLong()}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "readLong", - args = {} - ) - public void testReadLong() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.SQLInput#readFloat()}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "readFloat", - args = {} - ) - public void testReadFloat() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.SQLInput#readDouble()}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "readDouble", - args = {} - ) - public void testReadDouble() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.SQLInput#readBigDecimal()}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "readBigDecimal", - args = {} - ) - public void testReadBigDecimal() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.SQLInput#readBytes()}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "readBytes", - args = {} - ) - public void testReadBytes() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.SQLInput#readDate()}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "readDate", - args = {} - ) - public void testReadDate() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.SQLInput#readTime()}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "readTime", - args = {} - ) - public void testReadTime() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.SQLInput#readTimestamp()}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "readTimestamp", - args = {} - ) - public void testReadTimestamp() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.SQLInput#readCharacterStream()}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "readCharacterStream", - args = {} - ) - public void testReadCharacterStream() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.SQLInput#readAsciiStream()}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "readAsciiStream", - args = {} - ) - public void testReadAsciiStream() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.SQLInput#readBinaryStream()}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "readBinaryStream", - args = {} - ) - public void testReadBinaryStream() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.SQLInput#readObject()}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "readObject", - args = {} - ) - public void testReadObject() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.SQLInput#readRef()}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "readRef", - args = {} - ) - public void testReadRef() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.SQLInput#readBlob()}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "readBlob", - args = {} - ) - public void testReadBlob() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.SQLInput#readClob()}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "readClob", - args = {} - ) - public void testReadClob() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.SQLInput#readArray()}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "readArray", - args = {} - ) - public void testReadArray() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.SQLInput#wasNull()}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "wasNull", - args = {} - ) - public void testWasNull() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.SQLInput#readURL()}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "readURL", - args = {} - ) - public void testReadURL() { - fail("Not yet implemented"); - } - -} diff --git a/luni/src/test/java/tests/sql/SQLOutputTest.java b/luni/src/test/java/tests/sql/SQLOutputTest.java deleted file mode 100644 index 13ef4b1..0000000 --- a/luni/src/test/java/tests/sql/SQLOutputTest.java +++ /dev/null @@ -1,347 +0,0 @@ -/* - * Copyright (C) 2008 The Android Open Source Project - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package tests.sql; - -import dalvik.annotation.TestLevel; -import dalvik.annotation.TestTargetClass; -import dalvik.annotation.TestTargetNew; - -import junit.framework.TestCase; - -import java.io.InputStream; -import java.io.Reader; -import java.math.BigDecimal; -import java.net.URL; -import java.sql.Array; -import java.sql.Blob; -import java.sql.Clob; -import java.sql.Date; -import java.sql.Ref; -import java.sql.SQLData; -import java.sql.SQLOutput; -import java.sql.Struct; -import java.sql.Time; -import java.sql.Timestamp; - -@TestTargetClass(SQLOutput.class) -public class SQLOutputTest extends TestCase { - - /** - * Test method for {@link java.sql.SQLOutput#writeString(java.lang.String)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "writeString", - args = {String.class} - ) - public void testWriteString() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.SQLOutput#writeBoolean(boolean)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "writeBoolean", - args = {boolean.class} - ) - public void testWriteBoolean() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.SQLOutput#writeByte(byte)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "writeByte", - args = {byte.class} - ) - public void testWriteByte() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.SQLOutput#writeShort(short)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "writeShort", - args = {short.class} - ) - public void testWriteShort() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.SQLOutput#writeInt(int)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "writeInt", - args = {int.class} - ) - public void testWriteInt() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.SQLOutput#writeLong(long)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "writeLong", - args = {long.class} - ) - public void testWriteLong() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.SQLOutput#writeFloat(float)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "writeFloat", - args = {float.class} - ) - public void testWriteFloat() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.SQLOutput#writeDouble(double)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "writeDouble", - args = {double.class} - ) - public void testWriteDouble() { - fail("Not yet implemented"); - } - - /** - * Test method for - * {@link java.sql.SQLOutput#writeBigDecimal(java.math.BigDecimal)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "writeBigDecimal", - args = {BigDecimal.class} - ) - public void testWriteBigDecimal() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.SQLOutput#writeBytes(byte[])}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "writeBytes", - args = {byte[].class} - ) - public void testWriteBytes() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.SQLOutput#writeDate(java.sql.Date)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "writeDate", - args = {Date.class} - ) - public void testWriteDate() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.SQLOutput#writeTime(java.sql.Time)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "writeTime", - args = {Time.class} - ) - public void testWriteTime() { - fail("Not yet implemented"); - } - - /** - * Test method for - * {@link java.sql.SQLOutput#writeTimestamp(java.sql.Timestamp)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "writeTimestamp", - args = {Timestamp.class} - ) - public void testWriteTimestamp() { - fail("Not yet implemented"); - } - - /** - * Test method for - * {@link java.sql.SQLOutput#writeCharacterStream(java.io.Reader)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "writeCharacterStream", - args = {Reader.class} - ) - public void testWriteCharacterStream() { - fail("Not yet implemented"); - } - - /** - * Test method for - * {@link java.sql.SQLOutput#writeAsciiStream(java.io.InputStream)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "writeAsciiStream", - args = {InputStream.class} - ) - public void testWriteAsciiStream() { - fail("Not yet implemented"); - } - - /** - * Test method for - * {@link java.sql.SQLOutput#writeBinaryStream(java.io.InputStream)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "writeBinaryStream", - args = {InputStream.class} - ) - public void testWriteBinaryStream() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.SQLOutput#writeObject(java.sql.SQLData)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "writeObject", - args = {SQLData.class} - ) - public void testWriteObject() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.SQLOutput#writeRef(java.sql.Ref)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "writeRef", - args = {Ref.class} - ) - public void testWriteRef() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.SQLOutput#writeBlob(java.sql.Blob)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "writeBlob", - args = {Blob.class} - ) - public void testWriteBlob() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.SQLOutput#writeClob(java.sql.Clob)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "writeClob", - args = {Clob.class} - ) - public void testWriteClob() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.SQLOutput#writeStruct(java.sql.Struct)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "writeStruct", - args = {Struct.class} - ) - public void testWriteStruct() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.SQLOutput#writeArray(java.sql.Array)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "writeArray", - args = {Array.class} - ) - public void testWriteArray() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.SQLOutput#writeURL(java.net.URL)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "writeURL", - args = {URL.class} - ) - public void testWriteURL() { - fail("Not yet implemented"); - } - -} diff --git a/luni/src/test/java/tests/sql/SavepointTest.java b/luni/src/test/java/tests/sql/SavepointTest.java deleted file mode 100644 index dedf032..0000000 --- a/luni/src/test/java/tests/sql/SavepointTest.java +++ /dev/null @@ -1,59 +0,0 @@ -/* - * Copyright (C) 2008 The Android Open Source Project - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package tests.sql; - -import dalvik.annotation.TestLevel; -import dalvik.annotation.TestTargetClass; -import dalvik.annotation.TestTargetNew; - -import junit.framework.TestCase; - -import java.sql.Savepoint; - -/** - * - */ -@TestTargetClass(Savepoint.class) -public class SavepointTest extends TestCase { - - /** - * Test method for {@link java.sql.Savepoint#getSavepointId()}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getSavepointId", - args = {} - ) - public void testGetSavepointId() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.Savepoint#getSavepointName()}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getSavepointName", - args = {} - ) - public void testGetSavepointName() { - fail("Not yet implemented"); - } - -} diff --git a/luni/src/test/java/tests/sql/StatementTest.java b/luni/src/test/java/tests/sql/StatementTest.java index d41a875..11ce82c 100755 --- a/luni/src/test/java/tests/sql/StatementTest.java +++ b/luni/src/test/java/tests/sql/StatementTest.java @@ -1731,38 +1731,6 @@ public class StatementTest extends SQLTest { } /** - * @test {@link java.sql.Statement#getMoreResults(int)} - * - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "Callable Statements are not supported", - method = "getMoreResults", - args = {int.class} - ) - public void testGetMoreResultsInt() { - /* - } catch (BatchUpdateException e) { - fail("Unexpected Exception "+e.getMessage()); - } catch (SQLException e) { - assertEquals("not supported",e.getMessage()); - } finally { - try { - st.close(); - } catch (SQLException ee) { - } - } - - try { - st.getMoreResults(Integer.MAX_VALUE); - fail("Exception expected"); - } catch (SQLException e) { - //ok - } - */ - } - - /** * @test {@link java.sql.Statement#cancel()} * */ diff --git a/luni/src/test/java/tests/sql/StructTest.java b/luni/src/test/java/tests/sql/StructTest.java deleted file mode 100644 index e4c0fd4..0000000 --- a/luni/src/test/java/tests/sql/StructTest.java +++ /dev/null @@ -1,72 +0,0 @@ -/* - * Copyright (C) 2008 The Android Open Source Project - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package tests.sql; - -import dalvik.annotation.TestLevel; -import dalvik.annotation.TestTargetClass; -import dalvik.annotation.TestTargetNew; - -import junit.framework.TestCase; - -import java.sql.Struct; -import java.util.Map; - -@TestTargetClass(Struct.class) -public class StructTest extends TestCase { - - /** - * Test method for {@link java.sql.Struct#getSQLTypeName()}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getSQLTypeName", - args = {} - - ) - public void testGetSQLTypeName() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.Struct#getAttributes()}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - - method = "getAttributes", - args = {} - ) - public void testGetAttributes() { - fail("Not yet implemented"); - } - - /** - * Test method for {@link java.sql.Struct#getAttributes(java.util.Map)}. - */ - @TestTargetNew( - level = TestLevel.NOT_FEASIBLE, - notes = "", - method = "getAttributes", - args = {Map.class} - ) - public void testGetAttributesMapOfStringClassOfQ() { - fail("Not yet implemented"); - } - -} |