小编Ass*_*ato的帖子

使用eclipse模板创建测试用例

我经常发现自己为getter\setters,c'tors和Object方法(hashCode,equals和toString)创建了相同的单元测试方法.在Eclipse IDE的帮助下,我想要实现的是这个过程的自动化.考虑这个例子:

public Class Person {
  private String id;
  private String name;

  public Person(String id, String name){
    this.id = id;
    this.name = name;
  }

  public String getId() { return id; }
  public void setId(String id) {
    this.id = id;
  }

  public String getName() { return name; }
  public void setName(String name) {
    this.name = name;
  }

  @override
  public int hashCode(){ ... }
  public boolean equals(Person other){ ... }
  public String toString(){ ... }

  /* this class may implement other logic …
Run Code Online (Sandbox Code Playgroud)

java eclipse junit

5
推荐指数
1
解决办法
4303
查看次数

春季集成:“没有可用的输出通道或replyChannel标头”

我正在使用以下SI流程:

<integration:gateway id="notificationGateway"
             default-request-channel="start" 
             default-reply-channel="end"
             service-interface="com.supplier.NotificationGateway"/>
<integration:channel id="start"/>
<integration:service-activator id="securedFileTransfer" 
                   input-channel="start" 
                   ref="Submitter" 
                   method="submit" 
                   output-channel="end"/>
<integration:publish-subscribe-channel id="end"/>
Run Code Online (Sandbox Code Playgroud)

出现以下错误:

no output-channel or replyChannel header available?borg.springframework.integration.support.channel.ChannelResolutionException: no output-channel or replyChannel header available
Run Code Online (Sandbox Code Playgroud)

有任何想法吗?

spring-integration

4
推荐指数
1
解决办法
7186
查看次数

标签 统计

eclipse ×1

java ×1

junit ×1

spring-integration ×1