components/src/test/java/eu/internetofus/common/components/models/WeNetUserProfileTest.java
/**
   * Check that not accept profiles with bad planned activities.
   *
   * @param vertx       event bus to use.
   * @param testContext context to test.
   *
   * @see WeNetUserProfile#merge(WeNetUserProfile, WeNetValidateContext)
   */
Check that not accept profiles with bad planned activities.
@param vertx       event bus to use.
@param testContext context to test.


Check that not accept profiles with bad planned activities . @param vertx event bus to use . @param testContext context to test .
@Test
  public void shouldNotMergeWithABadPlannedActivities(final Vertx vertx, final VertxTestContext testContext) {
    final var source = new WeNetUserProfile();
    source.plannedActivities = new ArrayList<>();
    source.plannedActivities.add(new PlannedActivity());
    source.plannedActivities.add(new PlannedActivity());
    source.plannedActivities.add(new PlannedActivity());
    source.plannedActivities.get(1).attendees = new ArrayList<>();
    source.plannedActivities.get(1).attendees.add("undefined");
    assertCannotMerge(new WeNetUserProfile(), source, "plannedActivities[1].attendees[0]",
        new WeNetValidateContext("codePrefix", vertx), testContext);
  }
@ Test public void shouldNotMergeWithABadPlannedActivities ( final Vertx vertx , final VertxTestContext testContext ) { final var source = new WeNetUserProfile ( ) ; source . plannedActivities = new ArrayList < > ( ) ; source . plannedActivities . add ( new PlannedActivity ( ) ) ; source . plannedActivities . add ( new PlannedActivity ( ) ) ; source . plannedActivities . add ( new PlannedActivity ( ) ) ; source . plannedActivities . get ( 1 ) . attendees = new ArrayList < > ( ) ; source . plannedActivities . get ( 1 ) . attendees . add ( "undefined" ) ; assertCannotMerge ( new WeNetUserProfile ( ) , source , "plannedActivities[1].attendees[0]" , new WeNetValidateContext ( "codePrefix" , vertx ) , testContext ) ; }
Check that not accept profiles with bad planned activities.
Check that not accept profiles with bad planned activities .