コード例 #1
0
ファイル: Sql2oTest.java プロジェクト: 22221cjp/sql2o
 @Parameterized.Parameters(name = "{index} - {4}")
 public static Collection<Object[]> getData() {
   return Arrays.asList(
       new Object[][] {
         {null, "jdbc:h2:mem:test;DB_CLOSE_DELAY=-1", "sa", "", "H2 test"},
         {new jdbcDriver(), "jdbc:hsqldb:mem:testmemdb", "SA", "", "HyperSQL DB test"}
       });
 }
コード例 #2
0
 public ObjectPropertyAssertion<T> ignoreFields(String... field) {
   Set<String> ignoredFields = new HashSet<String>(this.ignoredFields);
   ignoredFields.addAll(Arrays.asList(field));
   return new ObjectPropertyAssertion<T>(
       type,
       generator,
       refinement,
       creator,
       skipSynthetic,
       skipToString,
       optionalToStringRegex,
       ignoredFields);
 }
コード例 #3
0
 @SuppressWarnings({"unchecked", "deprecation"})
 protected AbstractTypeDescriptionTest() {
   standardTypes =
       Arrays.asList(
           Object.class,
           Object[].class,
           SampleClass.class,
           SampleClass[].class,
           SampleInterface.class,
           SampleInterface[].class,
           SampleAnnotation.class,
           SampleAnnotation[].class,
           void.class,
           byte.class,
           byte[].class,
           short.class,
           short[].class,
           char.class,
           char[].class,
           int.class,
           int[].class,
           long.class,
           long[].class,
           float.class,
           float[].class,
           double.class,
           double[].class,
           new EnclosingType().localMethod,
           Array.newInstance(new EnclosingType().localConstructor, 1).getClass(),
           new EnclosingType().anonymousMethod,
           Array.newInstance(new EnclosingType().anonymousMethod, 1).getClass(),
           new EnclosingType().localConstructor,
           Array.newInstance(new EnclosingType().localConstructor, 1).getClass(),
           new EnclosingType().anonymousConstructor,
           Array.newInstance(new EnclosingType().anonymousConstructor, 1).getClass(),
           EnclosingType.LOCAL_INITIALIZER,
           Array.newInstance(EnclosingType.LOCAL_INITIALIZER.getClass(), 1).getClass(),
           EnclosingType.ANONYMOUS_INITIALIZER,
           Array.newInstance(EnclosingType.ANONYMOUS_INITIALIZER, 1).getClass(),
           EnclosingType.LOCAL_METHOD,
           Array.newInstance(EnclosingType.LOCAL_METHOD.getClass(), 1).getClass(),
           EnclosingType.ANONYMOUS_METHOD,
           Array.newInstance(EnclosingType.ANONYMOUS_METHOD, 1).getClass(),
           EnclosingType.INNER,
           Array.newInstance(EnclosingType.INNER, 1).getClass(),
           EnclosingType.NESTED,
           Array.newInstance(EnclosingType.NESTED, 1).getClass(),
           EnclosingType.PRIVATE_INNER,
           Array.newInstance(EnclosingType.PRIVATE_INNER, 1).getClass(),
           EnclosingType.PRIVATE_NESTED,
           Array.newInstance(EnclosingType.PRIVATE_NESTED, 1).getClass(),
           EnclosingType.PROTECTED_INNER,
           Array.newInstance(EnclosingType.PROTECTED_INNER, 1).getClass(),
           EnclosingType.PROTECTED_NESTED,
           Array.newInstance(EnclosingType.PROTECTED_NESTED, 1).getClass(),
           EnclosingType.PACKAGE_INNER,
           Array.newInstance(EnclosingType.PACKAGE_INNER, 1).getClass(),
           EnclosingType.PACKAGE_NESTED,
           Array.newInstance(EnclosingType.PACKAGE_NESTED, 1).getClass(),
           EnclosingType.FINAL_NESTED,
           Array.newInstance(EnclosingType.FINAL_NESTED, 1).getClass(),
           EnclosingType.FINAL_INNER,
           Array.newInstance(EnclosingType.FINAL_INNER, 1).getClass(),
           EnclosingType.DEPRECATED,
           Array.newInstance(EnclosingType.DEPRECATED, 1).getClass());
 }