You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@servicecomb.apache.org by GitBox <gi...@apache.org> on 2019/12/27 03:33:34 UTC

[GitHub] [servicecomb-java-chassis] sunjinghan7331 opened a new issue #1498: ServiceComb框架下如何进行api接口测试

sunjinghan7331 opened a new issue #1498: ServiceComb框架下如何进行api接口测试
URL: https://github.com/apache/servicecomb-java-chassis/issues/1498
 
 
   ServiceComb框架下如何进行api接口测试

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [servicecomb-java-chassis] sunjinghan7331 commented on issue #1498: ServiceComb框架下如何进行api接口测试

Posted by GitBox <gi...@apache.org>.
sunjinghan7331 commented on issue #1498: ServiceComb框架下如何进行api接口测试
URL: https://github.com/apache/servicecomb-java-chassis/issues/1498#issuecomment-569388946
 
 
   好的,谢谢

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [servicecomb-java-chassis] liubao68 commented on issue #1498: ServiceComb框架下如何进行api接口测试

Posted by GitBox <gi...@apache.org>.
liubao68 commented on issue #1498: ServiceComb框架下如何进行api接口测试
URL: https://github.com/apache/servicecomb-java-chassis/issues/1498#issuecomment-569371984
 
 
   你可以使用类似@SpringBootTest等把Bean的执行环境初始化起来,然后调用接口进行测试。 不过java-chassis项目的大部分集成测试不是采用这种方式测试的,都是依赖于启动consumer/provider来测试。开发自己的执行引擎或者使用docker,对于微服务的集成测试能够带来非常大的便利。涉及到网络通信的测试,建议采用集成测试的方式(当然集成测试也是在执行mvn test的过程中运行的,用JUnit API检测运行结果, java-chassis的DEMO都是这样被执行的)

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [servicecomb-java-chassis] liubao68 edited a comment on issue #1498: ServiceComb框架下如何进行api接口测试

Posted by GitBox <gi...@apache.org>.
liubao68 edited a comment on issue #1498: ServiceComb框架下如何进行api接口测试
URL: https://github.com/apache/servicecomb-java-chassis/issues/1498#issuecomment-569371984
 
 
   你可以使用类似@SpringBootTest等把Bean的执行环境初始化起来,然后调用接口进行测试。 不过java-chassis项目的大部分集成测试不是采用这种方式测试的,都是依赖于启动consumer/provider来测试。开发自己的执行引擎或者使用docker,对于微服务的集成测试能够带来非常大的便利。涉及到网络通信的测试,建议采用集成测试的方式(当然集成测试也是在执行mvn test的过程中运行的,用JUnit API检测运行结果, java-chassis的DEMO都是这样被执行的). 
   
   我有两个文章描述了基本思路[1](https://zhuanlan.zhihu.com/p/64329193) & [2](https://zhuanlan.zhihu.com/p/64599829)

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [servicecomb-java-chassis] sunjinghan7331 commented on issue #1498: ServiceComb框架下如何进行api接口测试

Posted by GitBox <gi...@apache.org>.
sunjinghan7331 commented on issue #1498: ServiceComb框架下如何进行api接口测试
URL: https://github.com/apache/servicecomb-java-chassis/issues/1498#issuecomment-569227356
 
 
   谢谢,可能我没有表述清楚,我想问的是ServiceComb支持使用什么工具类进行api接口测试代码的编写,像Junit一样的测试代码

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [servicecomb-java-chassis] sunjinghan7331 closed issue #1498: ServiceComb框架下如何进行api接口测试

Posted by GitBox <gi...@apache.org>.
sunjinghan7331 closed issue #1498: ServiceComb框架下如何进行api接口测试
URL: https://github.com/apache/servicecomb-java-chassis/issues/1498
 
 
   

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [servicecomb-java-chassis] liubao68 commented on issue #1498: ServiceComb框架下如何进行api接口测试

Posted by GitBox <gi...@apache.org>.
liubao68 commented on issue #1498: ServiceComb框架下如何进行api接口测试
URL: https://github.com/apache/servicecomb-java-chassis/issues/1498#issuecomment-569226424
 
 
   This is a generic question. 
   
   java-chassis integration tests can be a reference for you
   
   * demo : using docker to run all providers/consumers
   * integration-tests: there is a customized engine to start/stop providers/consumers to run all tests. 

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services