Пример #1
0
  @ExtDirectMethod
  public String method13(
      boolean flag,
      HttpServletResponse response,
      char aCharacter,
      final HttpServletRequest request,
      StatusEnum status,
      HttpSession session,
      int aInt,
      long aLong,
      Locale locale,
      double aDouble,
      float aFloat,
      Principal principal,
      short aShort,
      byte aByte) {

    assertThat(response).isNotNull();
    assertThat(request).isNotNull();
    assertThat(session).isNotNull();
    assertThat(locale).isEqualTo(Locale.ENGLISH);

    assertThat(flag).isTrue();
    assertThat(aCharacter).isEqualTo('c');
    assertThat(status).isEqualTo(StatusEnum.ACTIVE);
    assertThat(aInt).isEqualTo(14);
    assertThat(aLong).isEqualTo(21);
    assertThat(aDouble).isEqualTo(3.14);
    assertThat(aFloat).isEqualTo(10.01f, Offset.offset(0.01f));
    assertThat(aShort).isEqualTo((short) 1);
    assertThat(aByte).isEqualTo((byte) 2);
    return String.format(
        "method13() called-%b-%c-%s-%d-%d-%.2f-%.2f-%d-%d",
        flag, aCharacter, status, aInt, aLong, aDouble, aFloat, aShort, aByte);
  }
  @ExtDirectMethod(value = ExtDirectMethodType.SIMPLE_NAMED, group = "named")
  public String method10(
      boolean flag,
      HttpServletResponse response,
      char aCharacter,
      final HttpServletRequest request,
      short aShort,
      byte aByte,
      Workflow workflow,
      HttpSession session,
      int aInt,
      long aLong,
      Locale locale,
      double aDouble,
      float aFloat,
      Principal principal) {

    assertThat(response).isNotNull();
    assertThat(request).isNotNull();
    assertThat(session).isNotNull();
    assertThat(locale).isEqualTo(Locale.ENGLISH);

    assertThat(flag).isTrue();
    assertThat(aCharacter).isEqualTo('c');
    assertThat(workflow).isEqualTo(Workflow.PENDING);
    assertThat(aInt).isEqualTo(14);
    assertThat(aLong).isEqualTo(21);
    assertThat(aDouble).isEqualTo(3.14);
    assertThat(aFloat).isEqualTo(10.01f, Offset.offset(0.01f));
    assertThat(aShort).isEqualTo((short) 1);
    assertThat(aByte).isEqualTo((byte) 2);
    return String.format(
        "method10() called-%b-%c-%s-%d-%d-%.2f-%.2f-%d-%d",
        flag, aCharacter, workflow, aInt, aLong, aDouble, aFloat, aShort, aByte);
  }
Пример #3
0
 @ExtDirectMethod
 public String method10(
     boolean flag,
     char aCharacter,
     StatusEnum status,
     int aInt,
     long aLong,
     double aDouble,
     float aFloat,
     short aShort,
     byte aByte) {
   assertThat(flag).isTrue();
   assertThat(aCharacter).isEqualTo('c');
   assertThat(status).isEqualTo(StatusEnum.ACTIVE);
   assertThat(aInt).isEqualTo(14);
   assertThat(aLong).isEqualTo(21);
   assertThat(aDouble).isEqualTo(3.14);
   assertThat(aFloat).isEqualTo(10.01f, Offset.offset(0.01f));
   assertThat(aShort).isEqualTo((short) 1);
   assertThat(aByte).isEqualTo((byte) 2);
   return String.format(
       "method10() called-%b-%c-%s-%d-%d-%.2f-%.2f-%d-%d",
       flag, aCharacter, status, aInt, aLong, aDouble, aFloat, aShort, aByte);
 }
 @ExtDirectMethod(value = ExtDirectMethodType.SIMPLE_NAMED, group = "named")
 public String method7(
     boolean flag,
     char aCharacter,
     Workflow workflow,
     int aInt,
     long aLong,
     double aDouble,
     float aFloat,
     short aShort,
     byte aByte) {
   assertThat(flag).isTrue();
   assertThat(aCharacter).isEqualTo('c');
   assertThat(workflow).isEqualTo(Workflow.PENDING);
   assertThat(aInt).isEqualTo(14);
   assertThat(aLong).isEqualTo(21);
   assertThat(aDouble).isEqualTo(3.14);
   assertThat(aFloat).isEqualTo(10.01f, Offset.offset(0.01f));
   assertThat(aShort).isEqualTo((short) 1);
   assertThat(aByte).isEqualTo((byte) 2);
   return String.format(
       "method7() called-%b-%c-%s-%d-%d-%.2f-%.2f-%d-%d",
       flag, aCharacter, workflow, aInt, aLong, aDouble, aFloat, aShort, aByte);
 }
Пример #5
0
 /**
  * Only delegate to {@link Offset#offset(Float)} so that Assertions offers a full feature entry
  * point to all Fest Assert features (but you can use {@link Offset} if you prefer).
  *
  * <p>Typical usage :
  *
  * <pre>
  * assertThat(8.2f).isEqualTo(8.0f, offset(0.2f));
  * </pre>
  */
 public static Offset<Float> offset(Float value) {
   return Offset.offset(value);
 }
Пример #6
0
 /**
  * Only delegate to {@link Offset#offset(Double)} so that Assertions offers a full feature entry
  * point to all Fest Assert features (but you can use {@link Offset} if you prefer).
  *
  * <p>Typical usage :
  *
  * <pre>
  * assertThat(8.1).isEqualTo(8.0, offset(0.1));
  * </pre>
  */
 public static Offset<Double> offset(Double value) {
   return Offset.offset(value);
 }