首页| JavaScript| HTML/CSS| Matlab| PHP| Python| Java| C/C++/VC++| C#| ASP| 其他|
购买积分 购买会员 激活码充值

您现在的位置是:虫虫源码 > Java > 使你的测试人可读

使你的测试人可读

  • 资源大小:505.38 kB
  • 上传时间:2021-06-30
  • 下载次数:0次
  • 浏览次数:1次
  • 资源积分:1积分
  • 标      签: 测试

资 源 简 介

Project has been moved to [testory.org](http://testory.org) Testory makes your tests human-readable by using given-when-then idiom advised by Behavior Driven Development. With Testory you can decorate your code adding given, when and then keywords, where then works like junit"s assertTrue. ```java given(list = new ArrayList()); when(list.add("element")); then(!list.isEmpty()); ``` You can assert value returned in when ... ```java given(list = new ArrayList()); given(list.add("element")); when(list.get(0)); thenReturned("element"); ``` or assert that exception was thrown. ```java given(list = new ArrayList()); when(list).get(0); thenThrown(IndexOutOfBoundsException.class)

相 关 资 源

您 可 能 感 兴 趣 的

同 类 别 推 荐

VIP VIP
0.197094s