Package org.springframework.xd.dirt.test

Examples of org.springframework.xd.dirt.test.SingletonModuleRegistry.findDefinition()


  @Test
  public void testWhenMatching() {
    SingletonModuleRegistry mr = new SingletonModuleRegistry(processor, "foo");

    assertThat(mr.findDefinition("foo", processor), module("foo", processor));
    assertThat(mr.findDefinitions("foo"), contains(module("foo", processor)));
    assertThat(mr.findDefinitions(processor), contains(module("foo", processor)));
    assertThat(mr.findDefinitions(), contains(module("foo", processor)));

  }
View Full Code Here


  @Test
  public void testWhenNotMatching() {
    SingletonModuleRegistry mr = new SingletonModuleRegistry(processor, "foo");

    assertThat(mr.findDefinition("bar", processor), not(module("foo", processor)));
    assertThat(mr.findDefinitions("foo"), not(contains(module("foo", source))));
    assertThat(mr.findDefinitions(sink), not(contains(module("foo", processor))));
    assertThat(mr.findDefinitions(), not(contains(module("bar", processor))));

  }
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.