components/src/test/java/eu/internetofus/common/components/models/SocialPracticeTest.java
/**
   * Check that not merge model with bad norms.
   *
   * @param vertx       event bus to use.
   * @param testContext test context to use.
   *
   * @see SocialPractice#merge(SocialPractice, WeNetValidateContext)
   */
Check that not merge model with bad norms.
@param vertx       event bus to use.
@param testContext test context to use.


Check that not merge model with bad norms . @param vertx event bus to use . @param testContext test context to use .
@Test
  public void shouldNotMergeWithABadNorms(final Vertx vertx, final VertxTestContext testContext) {
    final var target = this.createModelExample(1);
    final var source = new SocialPractice();
    source.norms = new ArrayList<>();
    source.norms.add(new ProtocolNormTest().createModelExample(1));
    source.norms.add(new ProtocolNormTest().createModelExample(2));
    source.norms.add(new ProtocolNormTest().createModelExample(3));
    source.norms.get(1).whenever = source.norms.get(1).thenceforth;
    assertCannotMerge(target, source, "norms[1].thenceforth", new WeNetValidateContext("codePrefix", vertx),
        testContext);
  }
@ Test public void shouldNotMergeWithABadNorms ( final Vertx vertx , final VertxTestContext testContext ) { final var target = this . createModelExample ( 1 ) ; final var source = new SocialPractice ( ) ; source . norms = new ArrayList < > ( ) ; source . norms . add ( new ProtocolNormTest ( ) . createModelExample ( 1 ) ) ; source . norms . add ( new ProtocolNormTest ( ) . createModelExample ( 2 ) ) ; source . norms . add ( new ProtocolNormTest ( ) . createModelExample ( 3 ) ) ; source . norms . get ( 1 ) . whenever = source . norms . get ( 1 ) . thenceforth ; assertCannotMerge ( target , source , "norms[1].thenceforth" , new WeNetValidateContext ( "codePrefix" , vertx ) , testContext ) ; }
Check that not merge model with bad norms.
Check that not merge model with bad norms .