protocols/src/test/java/eu/internetofus/common/protocols/EatTogetherV2ProtocolITC.java
/**
   * Check that an user can not decline a task if it accepted to be volunteer.
   *
   * @param vertx       event bus to use.
   * @param testContext context to do the test.
   */
Check that an user can not decline a task if it accepted to be volunteer.
@param vertx       event bus to use.
@param testContext context to do the test.
Check that an user can not decline a task if it accepted to be volunteer . @param vertx event bus to use . @param testContext context to do the test .
@Test
  @Order(9)
  public void shouldNotDeclineAfterVolunteerForTask(final Vertx vertx, final VertxTestContext testContext) {
    this.assertLastSuccessfulTestWas(8, testContext);
    final var taskTransaction = new TaskTransaction();
    taskTransaction.taskId = this.task.id;
    taskTransaction.label = "refuseTask";
    final var volunteerId = this.users.get(2).id;
    taskTransaction.actioneerId = volunteerId;
    taskTransaction.attributes = new JsonObject().put("volunteerId", volunteerId);
    this.assertDoTransactionError(taskTransaction, vertx, testContext);
  }
@ Test @ Order ( 9 ) public void shouldNotDeclineAfterVolunteerForTask ( final Vertx vertx , final VertxTestContext testContext ) { this . assertLastSuccessfulTestWas ( 8 , testContext ) ; final var taskTransaction = new TaskTransaction ( ) ; taskTransaction . taskId = this . task . id ; taskTransaction . label = "refuseTask" ; final var volunteerId = this . users . get ( 2 ) . id ; taskTransaction . actioneerId = volunteerId ; taskTransaction . attributes = new JsonObject ( ) . put ( "volunteerId" , volunteerId ) ; this . assertDoTransactionError ( taskTransaction , vertx , testContext ) ; }
Check that an user can not decline a task if it accepted to be volunteer.
Check that an user can not decline a task if it accepted to be volunteer .